API REFERENCE
Authorize Connector
On this page
/api/connectorsGenerate an OAuth authorization URL for connecting a third-party service. Redirect to the returned URL to complete the OAuth flow.
Authentication
x-api-key in header
bearerAuth bearer
Request
curl --request POST \
--url 'https://api.recoupable.dev/api/connectors' \
--header 'x-api-key: YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"connector": "string"
}'Request body required
Authorization request details
application/json
connectorstringrequiredThe connector slug to authorize (e.g., 'googlesheets', 'tiktok', 'youtube', 'twitter', 'linkedin')
callback_urlstringOptional custom callback URL after OAuth completion
format: uri
account_idstringOptional account ID to connect a service for a different account (e.g., an artist or organization). Use this when connecting an artist's TikTok or other service. The authenticated account must have access. Omit to connect for your own account.
format: uuid
Responses
200Authorization URL generated successfully+
application/json
successbooleanrequireddataobjectrequiredProperties for data
connectorstringrequiredThe connector slug being authorized
redirectUrlstringrequiredURL to redirect to for OAuth authorization
format: uri
400Bad request - invalid connector or parameters+
application/json
errorintegerrequiredformat: int32
messagestringrequired401Unauthorized - invalid or missing API key+
application/json
errorintegerrequiredformat: int32
messagestringrequired403Forbidden - no access to the specified account+
application/json
errorintegerrequiredformat: int32
messagestringrequiredFull specification
Download the OpenAPI file for complete schemas, constraints, and examples.
Download social.jsonView operation source
{
"security": [
{
"apiKeyAuth": []
},
{
"bearerAuth": []
}
],
"description": "Generate an OAuth authorization URL for connecting a third-party service. Redirect to the returned URL to complete the OAuth flow.",
"requestBody": {
"description": "Authorization request details",
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/AuthorizeConnectorRequest"
}
}
}
},
"responses": {
"200": {
"description": "Authorization URL generated successfully",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/AuthorizeConnectorResponse"
}
}
}
},
"400": {
"description": "Bad request - invalid connector or parameters",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Error"
}
}
}
},
"401": {
"description": "Unauthorized - invalid or missing API key",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Error"
}
}
}
},
"403": {
"description": "Forbidden - no access to the specified account",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Error"
}
}
}
}
}
}