SDK ReferenceTypeScript SDK
SessionConfigs
Usage
Access this class through the composio.sessionConfigs property:
const composio = new Composio({ apiKey: 'your-api-key' });
const result = await composio.sessionConfigs.list();Methods
get()
Retrieve one saved Session config with its description and access policy. A missing or cross-project id surfaces as the backend's 404.
Requires Session configs to be enabled for the project.
async get(id: string, requestOptions?: ComposioRequestOptions): Promise<SessionConfig>Parameters
| Name | Type | Description |
|---|---|---|
id | string | The sc_… id of the Session config |
requestOptions? | ComposioRequestOptions |
Returns
Promise<SessionConfig> — The config and its policy
Example
const sessionConfig = await composio.sessionConfigs.get('sc_abc123');
console.log(sessionConfig.config.toolkits);list()
List the project's saved Session configs with cursor pagination.
Omitting archived returns active configs; archived: true returns only
archived ones. The backend defaults limit to 20 and caps it at 100.
Requires Session configs to be enabled for the project.
async list(params?: SessionConfigListParams, requestOptions?: ComposioRequestOptions): Promise<SessionConfigListResponse>Parameters
| Name | Type | Description |
|---|---|---|
params? | SessionConfigListParams | search, archived, limit and cursor |
requestOptions? | ComposioRequestOptions |
Returns
Promise<SessionConfigListResponse> — Config summaries and the next cursor
Example
let cursor: string | undefined;
do {
const page = await composio.sessionConfigs.list({ cursor });
for (const item of page.items) console.log(item.id, item.name);
cursor = page.nextCursor ?? undefined;
} while (cursor);