Get the list of all spreadsheets associated with Google account using Sheets API v4

The v4 API doesn't offer a way to list spreadsheets. You'll need to use the Drive API. The Migrate from a previous API page has some details on how to do use the Drive API to do it.


To get list of all files of specific type, you can use drive API v3. Below is an example to get all sheets from drive of authenticated user.

drive.files.list({
    q: "mimeType='application/vnd.google-apps.spreadsheet'",
    fields: 'nextPageToken, files(id, name)'
}, (err, response) => {
    //Your code
})

You can pass file type in MIME type as 'q' parameter. You can get list of drive MIME types here.

source: https://developers.google.com/sheets/api/guides/migration#list_spreadsheets_for_the_authenticated_user