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

next
ts 17 lines 697 Bytes
Raw
1 import type { AgentClaimResponse } from 'src/services/agents';
2
3 /** The success line `composio agent claim` prints on stderr. */
4 export const claimInviteSentMessage = (email: string) =>
5 `Sent Composio org claim invite to ${email}.`;
6
7 /**
8 * The stdout payload of `composio agent claim`: the invite the agents API created, with the
9 * requested `email` and an `invited` status when the response leaves them out.
10 */
11 export const formatAgentClaimJson = (result: AgentClaimResponse, requestedEmail: string) =>
12 JSON.stringify({
13 status: result.status ?? 'invited',
14 email: result.email ?? requestedEmail,
15 org_id: result.org_id ?? null,
16 invite_code: result.invite_code ?? null,
17 });