Documentation Index
Fetch the complete documentation index at: https://mintlify.com/ComposioHQ/composio/llms.txt
Use this file to discover all available pages before exploring further.
composio.connected_accounts is the interface for managing user connections to third-party services. Use it to initiate OAuth flows, import existing tokens, and query or delete connections. A connected account ties an external user ID to credentials for a specific toolkit (e.g. GitHub, Gmail, Slack) and is required before tools can be executed on that user’s behalf.
connected_accounts.link()
Create a Composio Connect Link for a user to authorize a connection via OAuth. Returns a ConnectionRequest that contains a redirect_url to send the user to.
Your application’s external user identifier. Composio uses this to associate the connection with the correct user for tool execution.
The ID of the auth config (
ac_xxx) that defines which OAuth application and scopes to use. Retrieve this from composio.auth_configs.list() or the Composio dashboard.URL to redirect the user to after they complete the OAuth flow in the external service. Overrides the default callback URL configured on the auth config.
Optional human-readable label for this connection (e.g.
"work-github"). Must be unique per user_id and toolkit within the project.When
False (default), raises ComposioMultipleConnectedAccountsError if the user already has an ACTIVE connection on this auth config. Set to True to allow multiple connections.Experimental options for creating SHARED connections with per-user ACL configuration. Shape may change in future releases.
connected_accounts.initiate()
The external user ID to create the connected account for.
The auth config ID (
ac_xxx) specifying which OAuth app to use.Callback URL for OAuth redirect flows.
Allow multiple active connections for the same user and auth config. Default
False.A typed connection state dict (produced by
auth_scheme.oauth2(...), auth_scheme.api_key(...), etc.) for importing existing credentials without a redirect flow.Optional human-readable alias for the connection.
connected_accounts.get()
Retrieve a single connected account by its ID.
The connected account ID (
ca_xxx).connected_accounts.list()
List connected accounts with optional filters.
Filter to connections belonging to specific user IDs.
Filter to connections for specific toolkits (e.g.
["github", "gmail"]).Filter to connections using specific auth configs.
Filter by status. Values:
"ACTIVE", "INACTIVE", "FAILED", "EXPIRED", "REVOKED".Maximum number of results to return per page.
Pagination cursor. Pass
next_cursor from the previous response to get the next page.connected_accounts.delete()
Delete a connected account permanently.
The connected account ID (
ca_xxx) to delete.connected_accounts.update()
Update a connected account’s alias or credentials.
The connected account ID (
ca_xxx).New human-readable alias. Pass an empty string
"" to clear the current alias.Credential update payload with
authScheme and val fields.connected_accounts.wait_for_connection()
Poll until a connected account becomes ACTIVE or a timeout is reached.
The connected account ID (
ca_xxx) to wait on.Maximum seconds to wait. Defaults to
60.0. Raises ComposioSDKTimeoutError on expiry.ConnectionRequest
link() and initiate() both return a ConnectionRequest object.
The connected account ID (
ca_xxx). Use this with wait_for_connection().Current connection status (e.g.
"INITIATED", "ACTIVE", "FAILED").The OAuth authorization URL to redirect the user to.
None for non-redirect flows (API key, bearer token, etc.).connection_request.wait_for_connection(timeout=60)
Wait on the ConnectionRequest object directly instead of passing the ID:
auth_scheme helpers
The auth_scheme singleton (from composio.core.models.connected_accounts) produces typed ConnectionState dicts for importing credentials directly without a redirect flow. Use these with initiate(config=...).
oauth1, oauth2, composio_link, api_key, basic, bearer_token, google_service_account, no_auth, calcom_auth, billcom_auth, basic_with_jwt.