Skip to main content

Google Sheets

Export domains and lead lists directly to Google Sheets. Requires connecting your Google account via OAuth first.

API Playground

tip

Try this endpoint live in the API Playground.

Prerequisites

  1. Navigate to Integrations → Google Sheets in the dashboard
  2. Click Connect Google Account
  3. Authorize CronDB to create and edit spreadsheets in your Google Drive
info

The Google Sheets integration uses OAuth 2.0. Your tokens are encrypted at rest and CronDB only requests the spreadsheets scope — we never read existing files.

Endpoints

MethodEndpointAuthDescription
POST/v1/sheets/exportRequiredExport domains to a new spreadsheet
POST/v1/sheets/export-list/{list_id}RequiredExport a lead list to Google Sheets
GET/v1/sheets/templatesRequiredList available export templates

Export Domains

Export a set of domains with their enrichment data to a new Google Sheet.

POST /v1/sheets/export
curl -X POST \
-H "Authorization: Bearer cdb_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"domains": ["startup1.com", "startup2.io", "enterprise.co"],
"template": "full"
}' \
"https://api.crondb.com/v1/sheets/export"

Request Body

FieldTypeRequiredDescription
domainsstring[]YesList of domains to export (max 500)
templatestringNoExport template: "full", "compact", or "contacts" (default: "full")

Response

{
"spreadsheet_id": "1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgVE2upms",
"spreadsheet_url": "https://docs.google.com/spreadsheets/d/1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgVE2upms",
"rows_exported": 3,
"template": "full"
}
FieldTypeDescription
spreadsheet_idstringGoogle Sheets document ID
spreadsheet_urlstringDirect link to the created spreadsheet
rows_exportedintegerNumber of domains successfully exported
templatestringThe template used for formatting

Export Lead List

Export an entire lead list to Google Sheets with all enriched data.

POST /v1/sheets/export-list/{list_id}
curl -X POST \
-H "Authorization: Bearer cdb_your_api_key_here" \
"https://api.crondb.com/v1/sheets/export-list/42"

Path Parameters

ParameterTypeDescription
list_idintegerThe ID of the lead list to export

Response

{
"spreadsheet_id": "1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgVE2upms",
"spreadsheet_url": "https://docs.google.com/spreadsheets/d/1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgVE2upms",
"rows_exported": 156,
"list_name": "Q1 Outreach Targets"
}

Export Templates

List the available formatting templates for exports.

GET /v1/sheets/templates
curl -H "Authorization: Bearer cdb_your_api_key_here" \
"https://api.crondb.com/v1/sheets/templates"

Response

{
"templates": [
{
"id": "full",
"name": "Full Export",
"description": "All available fields including enrichment data, scores, and metadata",
"columns": 22
},
{
"id": "compact",
"name": "Compact",
"description": "Essential fields: domain, industry, country, confidence, email",
"columns": 8
},
{
"id": "contacts",
"name": "Contacts Only",
"description": "Domain, email, phone, and organization details",
"columns": 6
}
]
}

Error Responses

StatusDetailReason
400Google Sheets not connectedOAuth not completed — connect via the Integrations page
400Maximum 500 domains per exportToo many domains in a single request
401Not authenticatedMissing or invalid Bearer token
404Lead list not foundThe specified list doesn't exist or belongs to another user
429Rate limit exceededToo many requests — try again shortly
500Google API error: ...Google Sheets API returned an error

Next Steps