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 12 lines 532 Bytes
Raw
1 import {
2 AGENT_SUMMARY_NOTE_TITLE,
3 agentSummaryLines,
4 type SafeAgentSummary,
5 } from 'src/services/agents';
6
7 /** The note body `composio agent whoami` prints on stderr. */
8 export const formatAgentWhoamiNote = (summary: SafeAgentSummary) =>
9 [...agentSummaryLines(summary), `Claimed By: ${summary.claimed_by ?? 'not claimed'}`].join('\n');
10
11 /** The stdout payload of `composio agent whoami`: the identity summary, without any key. */
12 export const formatAgentWhoamiJson = (summary: SafeAgentSummary) => JSON.stringify(summary);