MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / bindingUnresolvedResult

Function bindingUnresolvedResult

packages/hosts/mcp/src/tool-server.ts:1089–1112  ·  view source on GitHub ↗
(input: {
  readonly role: string;
  readonly integration: string;
  readonly message: string;
  readonly candidates: readonly string[];
})

Source from the content-addressed store, hash-verified

1087 * carries the same three facts for the same reason.
1088 */
1089const bindingUnresolvedResult = (input: {
1090 readonly role: string;
1091 readonly integration: string;
1092 readonly message: string;
1093 readonly candidates: readonly string[];
1094}): McpToolResult => ({
1095 content: [
1096 {
1097 type: "text",
1098 text:
1099 input.candidates.length > 0
1100 ? `${input.message} Choose one of ${input.candidates.join(", ")}.`
1101 : input.message,
1102 },
1103 ],
1104 structuredContent: {
1105 status: "error",
1106 error: "binding_unresolved",
1107 role: input.role,
1108 integration: input.integration,
1109 candidates: input.candidates,
1110 },
1111 isError: true,
1112});
1113
1114/** Format the stored source for the text result channel. */
1115const artifactSourceText = (code: string): string => `Source:\n\`\`\`tsx\n${code}\n\`\`\``;

Callers 1

executeCodeFromAppFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected