Integrations API
REST API endpoints for the Unified Integrations API. Access CRM, storage, communication, and productivity data from multiple providers through a single interface.
Base URL
https://api.stack0.dev/v1
Connectors
/integrations/connectorsList all available connectors.
QUERY PARAMETERS
| Parameter | Type | Description |
|---|---|---|
| category | string | Filter by category: crm, storage, communication, productivity |
{"data": [{"slug": "hubspot","name": "HubSpot","category": "crm","description": "CRM and marketing platform","features": ["contacts", "companies", "deals", "notes"],"authType": "oauth2"}]}
/integrations/connectors/{slug}Get a specific connector by slug.
Connections
/integrations/connectionsList all connections for your project.
QUERY PARAMETERS
| Parameter | Type | Description |
|---|---|---|
| connectorId | string | Filter by connector slug |
| status | string | Filter by status: connected, error, expired |
{"data": [{"id": "conn_abc123","connectorSlug": "hubspot","status": "connected","externalAccountId": "12345","externalAccountName": "john@example.com","endUserId": "user_xyz","createdAt": "2024-01-15T10:30:00Z","lastUsedAt": "2024-01-20T14:22:00Z"}]}
/integrations/connectionsCreate a new connection (initiates OAuth flow).
REQUEST BODY
| Field | Type | Required | Description |
|---|---|---|---|
| connectorSlug | string | required | The connector to connect (e.g., hubspot, google-drive) |
| endUserId | string | required | Your user's ID in your system |
| redirectUrl | string | optional | URL to redirect after OAuth completes |
{"connectionId": "conn_abc123","authorizationUrl": "https://app.hubspot.com/oauth/authorize?..."}
/integrations/connections/{id}Get a specific connection.
/integrations/connections/{id}Delete/revoke a connection.
/integrations/connections/{id}/testTest if a connection's credentials are still valid.
// Success{ "success": true }// Failure{ "success": false, "error": "Token expired" }
CRM - Contacts
/integrations/crm/contactsList contacts from the connected CRM.
QUERY PARAMETERS
| Parameter | Type | Required | Description |
|---|---|---|---|
| connectionId | string | required | The connection ID to use |
| cursor | string | optional | Pagination cursor |
| limit | number | optional | Max results (default: 50) |
{"data": [{"id": "contact_123","firstName": "John","lastName": "Doe","email": "john@example.com","phone": "+1234567890","title": "CEO","companyId": "company_456","createdAt": "2024-01-15T10:30:00Z","updatedAt": "2024-01-20T14:22:00Z","rawData": { ... }}],"nextCursor": "eyJwYWdlIjoy..."}
/integrations/crm/contactsCreate a new contact.
REQUEST BODY
| Field | Type | Description |
|---|---|---|
| firstName | string | Contact's first name |
| lastName | string | Contact's last name |
| string | Email address | |
| phone | string | Phone number |
/integrations/crm/contacts/{id}Get a specific contact.
/integrations/crm/contacts/{id}Update a contact.
/integrations/crm/contacts/{id}Delete a contact.
CRM - Companies
/integrations/crm/companiesList companies from the connected CRM.
/integrations/crm/companiesCreate a new company.
REQUEST BODY
| Field | Type | Required | Description |
|---|---|---|---|
| name | string | required | Company name |
| domain | string | optional | Company domain |
| industry | string | optional | Industry |
CRM - Deals
/integrations/crm/dealsList deals from the connected CRM.
/integrations/crm/dealsCreate a new deal.
REQUEST BODY
| Field | Type | Required | Description |
|---|---|---|---|
| name | string | required | Deal name |
| amount | number | optional | Deal amount |
| stage | string | optional | Deal stage |
Storage - Files
/integrations/storage/filesList files from the connected storage.
QUERY PARAMETERS
| Parameter | Type | Required | Description |
|---|---|---|---|
| connectionId | string | required | The connection ID to use |
| folderId | string | optional | Parent folder ID (root if omitted) |
/integrations/storage/filesUpload a file.
REQUEST BODY
| Field | Type | Required | Description |
|---|---|---|---|
| connectionId | string | required | The connection ID to use |
| name | string | required | File name |
| mimeType | string | required | MIME type |
| data | string | required | Base64-encoded file content |
| folderId | string | optional | Parent folder ID |
/integrations/storage/files/{id}/downloadDownload a file.
{"data": "base64-encoded-content...","mimeType": "application/pdf","filename": "document.pdf"}
/integrations/storage/files/{id}Delete a file.
Storage - Folders
/integrations/storage/foldersList folders.
/integrations/storage/foldersCreate a folder.
REQUEST BODY
| Field | Type | Required | Description |
|---|---|---|---|
| connectionId | string | required | The connection ID to use |
| name | string | required | Folder name |
| parentId | string | optional | Parent folder ID |
Communication
/integrations/communication/channelsList channels.
/integrations/communication/messagesList messages in a channel.
QUERY PARAMETERS
| Parameter | Type | Required | Description |
|---|---|---|---|
| connectionId | string | required | The connection ID to use |
| channelId | string | required | Channel ID |
/integrations/communication/messagesSend a message.
REQUEST BODY
| Field | Type | Required | Description |
|---|---|---|---|
| connectionId | string | required | The connection ID to use |
| channelId | string | required | Channel to send to |
| content | string | required | Message content |
/integrations/communication/usersList users in the workspace.
Productivity
/integrations/productivity/documentsList documents/pages.
/integrations/productivity/documentsCreate a document.
REQUEST BODY
| Field | Type | Required | Description |
|---|---|---|---|
| connectionId | string | required | The connection ID to use |
| title | string | required | Document title |
| content | string | optional | Document content |
/integrations/productivity/tablesList tables/databases.
/integrations/productivity/tables/{tableId}/rowsList rows in a table.
/integrations/productivity/tables/{tableId}/rowsCreate a row.
REQUEST BODY
| Field | Type | Required | Description |
|---|---|---|---|
| connectionId | string | required | The connection ID to use |
| fields | object | required | Field values for the row |
Passthrough
/integrations/passthroughMake a raw API call to the underlying provider.
REQUEST BODY
| Field | Type | Required | Description |
|---|---|---|---|
| connectionId | string | required | The connection ID to use |
| method | string | required | HTTP method (GET, POST, PUT, PATCH, DELETE) |
| path | string | required | API path (relative to provider's base URL) |
| query | object | optional | Query parameters |
| body | object | optional | Request body |
| headers | object | optional | Additional headers |
curl -X POST "https://api.stack0.dev/v1/integrations/passthrough" \-H "Authorization: Bearer sk_live_your_api_key" \-H "Content-Type: application/json" \-d '{"connectionId": "conn_abc123","method": "GET","path": "/crm/v3/objects/contacts","query": { "limit": "10" }}'