POST
/
integrations
/
connect
curl --request POST \
  --url https://api.carbon.ai/integrations/connect \
  --header 'Content-Type: application/json' \
  --header 'authorization: <api-key>' \
  --data '{
  "authentication": {
    "source": "GOOGLE_DRIVE",
    "access_token": "<string>",
    "refresh_token": "<string>"
  },
  "sync_options": {
    "tags": "<any>",
    "chunk_size": 123,
    "chunk_overlap": 123,
    "skip_embedding_generation": true,
    "embedding_model": "OPENAI",
    "generate_sparse_vectors": true,
    "prepend_filename_to_chunks": true,
    "max_items_per_chunk": 1,
    "sync_files_on_connection": true,
    "set_page_as_boundary": true,
    "request_id": "<string>",
    "enable_file_picker": true
  }
}'
{
  "data_source": {
    "id": 123,
    "data_source_external_id": "<string>",
    "data_source_type": "GOOGLE_DRIVE",
    "token": {},
    "sync_status": "QUEUED_FOR_SYNCING",
    "source_items_synced_at": "2023-11-07T05:31:56Z",
    "organization_user_id": 123,
    "organization_id": 123,
    "organization_supplied_user_id": "<string>",
    "revoked_access": true,
    "last_synced_at": "2023-11-07T05:31:56Z",
    "last_sync_action": "ADD",
    "enable_auto_sync": true,
    "created_at": "2023-11-07T05:31:56Z",
    "updated_at": "2023-11-07T05:31:56Z",
    "files_synced_at": "2023-11-07T05:31:56Z"
  },
  "sync_url": "<string>"
}

Authorizations

authorization
string
headerrequired

token <token>, corresponds to temporary access tokens.

Body

application/json
authentication
object
required
sync_options
object

Response

200 - application/json
data_source
object
required
sync_url
string | null
required