Flow

Connect an integration from credentials

POST
/integrations/connections

Imports credentials the caller supplied directly

BearerAuth
headerAuthorizationBearer <JWT>

Admin token, API token issued via /api-tokens, or an OIDC JWT access token issued by the configured OIDC provider.

application/json
  1. body
integration*string

The integration to connect, e.g. private-api-generic.

connectionConfig?

Provider connection-config values, keyed by field name. Required by some providers for API-key auth.

credentials*

Mode-specific credentials, bound directly to Nango's shape, e.g. { "type": "API_KEY", "apiKey": "..." }.

Response Body

The imported integration connection.

application/json
  1. response

A third-party authorization for one integration.

name*string

Resource name, integrations/connections/{connection_id}.

integration*string

The connected integration. Join on this to the integration list for its label and icon.

status*string

active, or needs_reauth when the grant stopped working.

Value in"active""needs_reauth"
scopes*array<string>

The OAuth scopes currently granted on this connection.

createTime*string
Formatdate-time
Example Request
curl -X POST 'https://example.com/api/hub/integrations/connections' \  -H 'Content-Type: application/json' \  -d '{  "integration": "private-api-generic",  "credentials": {}}'
Example Response
{  "name": "integrations/connections/user-123",  "integration": "google-mail",  "status": "active",  "scopes": [    "https://www.googleapis.com/auth/gmail.readonly"  ],  "createTime": "2019-08-24T14:15:22Z"}