API ReferenceSessions (prev Tool Router)
Create a link session for a toolkit in a tool router sessionv3.1
Initiates an authentication link session for a specific toolkit within a tool router session. Returns a link token and redirect URL that users can use to complete the OAuth flow.
Authorization
ApiKeyAuth x-api-key<token>
Project API key authentication
In: header
Path Parameters
session_idstringRequired
The unique identifier of the tool router session
Format:
toolRouterSessionIdRequest Body
application/json
toolkitstringRequired
The unique slug identifier of the toolkit to connect
aliasstring
A human-readable alias for this connected account. Must be unique per entity and toolkit within the project.
callback_urlstring
URL where users will be redirected after completing auth
Format:
uriexperimentalobjectExperimental
Experimental features - not stable, may be modified or removed in future versions.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/v3.1/tool_router/session/trs_LX9uJKBinWWr/link" \ -H "Content-Type: application/json" \ -d '{ "toolkit": "github" }'{ "link_token": "lt_abc123xyz", "redirect_url": "https://app.composio.dev/link/lt_abc123xyz", "connected_account_id": "ca_abc123xyz", "experimental": { "account_type": "PRIVATE", "acl_config_for_shared": { "allow_all_users": true, "allowed_user_ids": [ "string" ], "not_allowed_user_ids": [ "string" ] } }}