@devries-cameron20 / composio Mirror · read-only / commits / 846214ac7
Fork 0

Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.

Mirrored from https://github.com/Camo67/composio.git

Synced Nov 22, 09:30 UTC

docs: add session lifecycle and immutability info to users-and-sessions page

Explains that sessions are immutable (config fixed at creation), persist indefinitely, and that connected accounts follow the user ID across sessions. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Sushmithamallesh committed Feb 17, 2026 at 14:37 UTC 846214ac7013cc740b1336f7e15d77dc12b47300
1 file changed +16
docs/content/docs/users-and-sessions.mdx
+16
@@ -97,6 +97,22 @@ const toolkits = await session.toolkits();
97 </Tab>
98 </Tabs>
99
100 +## How sessions behave
101 +
102 +A session ties together a user, a set of available toolkits, auth configuration for those toolkits, and connected accounts. Call `create()` whenever you want to do a task. Each session is designed for a particular agentic task, and if you want to change the context of the task, create a new session.
103 +
104 +You don't need to cache session IDs, manage session lifetimes, or worry about expiration. Sessions persist on the server and don't expire. Just call `create()` with what you need.
105 +
106 +### Sessions are immutable
107 +
108 +A session's configuration is fixed at creation. You cannot change the toolkits, auth configs, or connected accounts on an existing session.
109 +
110 +This means the boundary for a new session isn't a new chat or a new request. It's when the contract changes. If a user starts with "search my personal Gmail" and then says "actually use my work email," that's a different session because the auth changed.
111 +
112 +### Connected accounts persist across sessions
113 +
114 +Connections are tied to the user ID, not the session. A user who connected Gmail in one session can access it in every future session without re-authenticating.
115 +
116 <Cards>
117 <Card icon={<BookOpen />} title="Configuring Sessions" href="/docs/configuring-sessions" description="Enable toolkits, set auth configs, and select connected accounts" />
118 <Card icon={<BookOpen />} title="Workbench" href="/docs/workbench" description="Write and run code in a persistent sandbox" />