MCPcopy Index your code
hub / github.com/simstudioai/sim / agentCardOutput

Function agentCardOutput

apps/sim/lib/a2a/client.ts:373–394  ·  view source on GitHub ↗
(card: AgentCard, fallbackUrl: string)

Source from the content-addressed store, hash-verified

371}
372
373export function agentCardOutput(card: AgentCard, fallbackUrl: string): A2AAgentCardOutput {
374 const iface = card.supportedInterfaces.at(0)
375 return {
376 name: card.name,
377 description: card.description,
378 url: iface?.url ?? fallbackUrl,
379 version: card.version,
380 protocolVersion: iface?.protocolVersion ?? '',
381 capabilities: {
382 streaming: card.capabilities?.streaming ?? false,
383 pushNotifications: card.capabilities?.pushNotifications ?? false,
384 extendedAgentCard: card.capabilities?.extendedAgentCard ?? false,
385 },
386 skills: card.skills.map((skill) => ({
387 id: skill.id,
388 name: skill.name,
389 description: skill.description,
390 })),
391 defaultInputModes: card.defaultInputModes,
392 defaultOutputModes: card.defaultOutputModes,
393 }
394}

Callers 2

client.test.tsFile · 0.90
route.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected