MCPcopy Create free account
hub / github.com/Mnexa-AI/e2a / mapFilters

Function mapFilters

mcp/src/tools/webhooks.ts:35–44  ·  view source on GitHub ↗
(
    f?: { agent_ids?: string[]; conversation_ids?: string[]; labels?: string[] },
  )

Source from the content-addressed store, hash-verified

33 // WebhookFiltersView. Returns undefined for an absent filter so we
34 // don't send an empty object.
35 const mapFilters = (
36 f?: { agent_ids?: string[]; conversation_ids?: string[]; labels?: string[] },
37 ): { agentIds?: string[]; conversationIds?: string[]; labels?: string[] } | undefined => {
38 if (!f) return undefined;
39 return {
40 ...(f.agent_ids !== undefined ? { agentIds: f.agent_ids } : {}),
41 ...(f.conversation_ids !== undefined ? { conversationIds: f.conversation_ids } : {}),
42 ...(f.labels !== undefined ? { labels: f.labels } : {}),
43 };
44 };
45
46 server.registerTool(
47 "list_webhooks",

Callers 1

registerWebhookToolsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected