Actions11
Spreadsheet → Create
AI-generatedOverview
This node allows users to create a new Google Spreadsheet using a Google Sheets API authenticated via a Service Account. It supports authentication either through saved n8n credentials or manual entry of service account details. The node is useful for automating the creation of spreadsheets in workflows, such as generating reports, logs, or data collection templates dynamically.
Use Case Examples
- Automatically create a new spreadsheet titled 'Monthly Sales Report' when a sales workflow is triggered.
- Generate a new spreadsheet for each new project to track tasks and progress.
Properties
| Name | Meaning |
|---|---|
| Authentication | Choose the authentication method to access the Google Sheets API, either using saved credentials or manual entry. |
| Service Account Email | The email address of the Google service account used for authentication (required if manual authentication is selected). |
| Private Key | The private key from the service account JSON used for authentication (required if manual authentication is selected). |
| Impersonate Email (Optional) | Email of a user to impersonate, requiring domain-wide delegation (optional, manual authentication only). |
| Title | The title of the new spreadsheet to be created. |
Output
JSON
json- The JSON response from the Google Sheets API containing details of the created spreadsheet, including its ID and properties.
Dependencies
- Google Sheets API via googleapis library
- Google service account credentials or saved n8n credentials for authentication
Troubleshooting
- Ensure that the service account email and private key are correctly provided when using manual authentication.
- If using impersonation, verify that domain-wide delegation is properly configured for the service account.
- Common error: 'No credentials provided' occurs if no credentials are selected or entered; resolve by selecting saved credentials or entering manual credentials.
- API errors from Google Sheets (e.g., permission denied) usually indicate insufficient permissions or incorrect spreadsheet properties.
Links
- Google Sheets API Service Account Authorization - Official documentation on how to authorize Google Sheets API requests using service accounts.
- Google Sheets API Create Spreadsheet - API reference for creating a new spreadsheet using the Google Sheets API.