@zavudev/sdk-mcp 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +201 -0
- package/README.md +313 -0
- package/code-tool-types.d.mts +16 -0
- package/code-tool-types.d.mts.map +1 -0
- package/code-tool-types.d.ts +16 -0
- package/code-tool-types.d.ts.map +1 -0
- package/code-tool-types.js +4 -0
- package/code-tool-types.js.map +1 -0
- package/code-tool-types.mjs +3 -0
- package/code-tool-types.mjs.map +1 -0
- package/code-tool.d.mts +54 -0
- package/code-tool.d.mts.map +1 -0
- package/code-tool.d.ts +54 -0
- package/code-tool.d.ts.map +1 -0
- package/code-tool.js +49 -0
- package/code-tool.js.map +1 -0
- package/code-tool.mjs +46 -0
- package/code-tool.mjs.map +1 -0
- package/compat.d.mts +58 -0
- package/compat.d.mts.map +1 -0
- package/compat.d.ts +58 -0
- package/compat.d.ts.map +1 -0
- package/compat.js +387 -0
- package/compat.js.map +1 -0
- package/compat.mjs +378 -0
- package/compat.mjs.map +1 -0
- package/docs-search-tool.d.mts +50 -0
- package/docs-search-tool.d.mts.map +1 -0
- package/docs-search-tool.d.ts +50 -0
- package/docs-search-tool.d.ts.map +1 -0
- package/docs-search-tool.js +51 -0
- package/docs-search-tool.js.map +1 -0
- package/docs-search-tool.mjs +47 -0
- package/docs-search-tool.mjs.map +1 -0
- package/dynamic-tools.d.mts +12 -0
- package/dynamic-tools.d.mts.map +1 -0
- package/dynamic-tools.d.ts +12 -0
- package/dynamic-tools.d.ts.map +1 -0
- package/dynamic-tools.js +135 -0
- package/dynamic-tools.js.map +1 -0
- package/dynamic-tools.mjs +132 -0
- package/dynamic-tools.mjs.map +1 -0
- package/filtering.d.mts +3 -0
- package/filtering.d.mts.map +1 -0
- package/filtering.d.ts +3 -0
- package/filtering.d.ts.map +1 -0
- package/filtering.js +24 -0
- package/filtering.js.map +1 -0
- package/filtering.mjs +16 -0
- package/filtering.mjs.map +1 -0
- package/headers.d.mts +4 -0
- package/headers.d.mts.map +1 -0
- package/headers.d.ts +4 -0
- package/headers.d.ts.map +1 -0
- package/headers.js +22 -0
- package/headers.js.map +1 -0
- package/headers.mjs +18 -0
- package/headers.mjs.map +1 -0
- package/http.d.mts +9 -0
- package/http.d.mts.map +1 -0
- package/http.d.ts +9 -0
- package/http.d.ts.map +1 -0
- package/http.js +108 -0
- package/http.js.map +1 -0
- package/http.mjs +100 -0
- package/http.mjs.map +1 -0
- package/index.d.mts +3 -0
- package/index.d.mts.map +1 -0
- package/index.d.ts +3 -0
- package/index.d.ts.map +1 -0
- package/index.js +91 -0
- package/index.js.map +1 -0
- package/index.mjs +89 -0
- package/index.mjs.map +1 -0
- package/options.d.mts +20 -0
- package/options.d.mts.map +1 -0
- package/options.d.ts +20 -0
- package/options.d.ts.map +1 -0
- package/options.js +427 -0
- package/options.js.map +1 -0
- package/options.mjs +420 -0
- package/options.mjs.map +1 -0
- package/package.json +201 -0
- package/server.d.mts +35 -0
- package/server.d.mts.map +1 -0
- package/server.d.ts +35 -0
- package/server.d.ts.map +1 -0
- package/server.js +174 -0
- package/server.js.map +1 -0
- package/server.mjs +160 -0
- package/server.mjs.map +1 -0
- package/src/code-tool-types.ts +18 -0
- package/src/code-tool.ts +59 -0
- package/src/compat.ts +483 -0
- package/src/docs-search-tool.ts +59 -0
- package/src/dynamic-tools.ts +153 -0
- package/src/filtering.ts +18 -0
- package/src/headers.ts +25 -0
- package/src/http.ts +127 -0
- package/src/index.ts +108 -0
- package/src/options.ts +473 -0
- package/src/server.ts +207 -0
- package/src/stdio.ts +13 -0
- package/src/tools/broadcasts/cancel-broadcasts.ts +52 -0
- package/src/tools/broadcasts/contacts/add-broadcasts-contacts.ts +73 -0
- package/src/tools/broadcasts/contacts/list-broadcasts-contacts.ts +71 -0
- package/src/tools/broadcasts/contacts/remove-broadcasts-contacts.ts +43 -0
- package/src/tools/broadcasts/create-broadcasts.ts +134 -0
- package/src/tools/broadcasts/delete-broadcasts.ts +40 -0
- package/src/tools/broadcasts/list-broadcasts.ts +68 -0
- package/src/tools/broadcasts/progress-broadcasts.ts +54 -0
- package/src/tools/broadcasts/retrieve-broadcasts.ts +54 -0
- package/src/tools/broadcasts/send-broadcasts.ts +57 -0
- package/src/tools/broadcasts/update-broadcasts.ts +106 -0
- package/src/tools/contacts/list-contacts.ts +61 -0
- package/src/tools/contacts/retrieve-by-phone-contacts.ts +56 -0
- package/src/tools/contacts/retrieve-contacts.ts +54 -0
- package/src/tools/contacts/update-contacts.ts +61 -0
- package/src/tools/index.ts +143 -0
- package/src/tools/introspect/validate-phone-introspect.ts +52 -0
- package/src/tools/messages/list-messages.ts +78 -0
- package/src/tools/messages/react-messages.ts +59 -0
- package/src/tools/messages/retrieve-messages.ts +54 -0
- package/src/tools/messages/send-messages.ts +233 -0
- package/src/tools/phone-numbers/list-phone-numbers.ts +68 -0
- package/src/tools/phone-numbers/purchase-phone-numbers.ts +57 -0
- package/src/tools/phone-numbers/release-phone-numbers.ts +40 -0
- package/src/tools/phone-numbers/retrieve-phone-numbers.ts +56 -0
- package/src/tools/phone-numbers/search-available-phone-numbers.ts +72 -0
- package/src/tools/phone-numbers/update-phone-numbers.ts +62 -0
- package/src/tools/senders/create-senders.ts +86 -0
- package/src/tools/senders/delete-senders.ts +40 -0
- package/src/tools/senders/list-senders.ts +58 -0
- package/src/tools/senders/regenerate-webhook-secret-senders.ts +54 -0
- package/src/tools/senders/retrieve-senders.ts +54 -0
- package/src/tools/senders/update-senders.ts +90 -0
- package/src/tools/templates/create-templates.ts +74 -0
- package/src/tools/templates/delete-templates.ts +40 -0
- package/src/tools/templates/list-templates.ts +58 -0
- package/src/tools/templates/retrieve-templates.ts +54 -0
- package/src/tools/templates/submit-templates.ts +66 -0
- package/src/tools/types.ts +115 -0
- package/src/tools.ts +1 -0
- package/src/tsconfig.json +11 -0
- package/stdio.d.mts +3 -0
- package/stdio.d.mts.map +1 -0
- package/stdio.d.ts +3 -0
- package/stdio.d.ts.map +1 -0
- package/stdio.js +14 -0
- package/stdio.js.map +1 -0
- package/stdio.mjs +10 -0
- package/stdio.mjs.map +1 -0
- package/tools/broadcasts/cancel-broadcasts.d.mts +51 -0
- package/tools/broadcasts/cancel-broadcasts.d.mts.map +1 -0
- package/tools/broadcasts/cancel-broadcasts.d.ts +51 -0
- package/tools/broadcasts/cancel-broadcasts.d.ts.map +1 -0
- package/tools/broadcasts/cancel-broadcasts.js +52 -0
- package/tools/broadcasts/cancel-broadcasts.js.map +1 -0
- package/tools/broadcasts/cancel-broadcasts.mjs +45 -0
- package/tools/broadcasts/cancel-broadcasts.mjs.map +1 -0
- package/tools/broadcasts/contacts/add-broadcasts-contacts.d.mts +51 -0
- package/tools/broadcasts/contacts/add-broadcasts-contacts.d.mts.map +1 -0
- package/tools/broadcasts/contacts/add-broadcasts-contacts.d.ts +51 -0
- package/tools/broadcasts/contacts/add-broadcasts-contacts.d.ts.map +1 -0
- package/tools/broadcasts/contacts/add-broadcasts-contacts.js +71 -0
- package/tools/broadcasts/contacts/add-broadcasts-contacts.js.map +1 -0
- package/tools/broadcasts/contacts/add-broadcasts-contacts.mjs +64 -0
- package/tools/broadcasts/contacts/add-broadcasts-contacts.mjs.map +1 -0
- package/tools/broadcasts/contacts/list-broadcasts-contacts.d.mts +51 -0
- package/tools/broadcasts/contacts/list-broadcasts-contacts.d.mts.map +1 -0
- package/tools/broadcasts/contacts/list-broadcasts-contacts.d.ts +51 -0
- package/tools/broadcasts/contacts/list-broadcasts-contacts.d.ts.map +1 -0
- package/tools/broadcasts/contacts/list-broadcasts-contacts.js +71 -0
- package/tools/broadcasts/contacts/list-broadcasts-contacts.js.map +1 -0
- package/tools/broadcasts/contacts/list-broadcasts-contacts.mjs +64 -0
- package/tools/broadcasts/contacts/list-broadcasts-contacts.mjs.map +1 -0
- package/tools/broadcasts/contacts/remove-broadcasts-contacts.d.mts +51 -0
- package/tools/broadcasts/contacts/remove-broadcasts-contacts.d.mts.map +1 -0
- package/tools/broadcasts/contacts/remove-broadcasts-contacts.d.ts +51 -0
- package/tools/broadcasts/contacts/remove-broadcasts-contacts.d.ts.map +1 -0
- package/tools/broadcasts/contacts/remove-broadcasts-contacts.js +40 -0
- package/tools/broadcasts/contacts/remove-broadcasts-contacts.js.map +1 -0
- package/tools/broadcasts/contacts/remove-broadcasts-contacts.mjs +36 -0
- package/tools/broadcasts/contacts/remove-broadcasts-contacts.mjs.map +1 -0
- package/tools/broadcasts/create-broadcasts.d.mts +51 -0
- package/tools/broadcasts/create-broadcasts.d.mts.map +1 -0
- package/tools/broadcasts/create-broadcasts.d.ts +51 -0
- package/tools/broadcasts/create-broadcasts.d.ts.map +1 -0
- package/tools/broadcasts/create-broadcasts.js +134 -0
- package/tools/broadcasts/create-broadcasts.js.map +1 -0
- package/tools/broadcasts/create-broadcasts.mjs +127 -0
- package/tools/broadcasts/create-broadcasts.mjs.map +1 -0
- package/tools/broadcasts/delete-broadcasts.d.mts +51 -0
- package/tools/broadcasts/delete-broadcasts.d.mts.map +1 -0
- package/tools/broadcasts/delete-broadcasts.d.ts +51 -0
- package/tools/broadcasts/delete-broadcasts.d.ts.map +1 -0
- package/tools/broadcasts/delete-broadcasts.js +37 -0
- package/tools/broadcasts/delete-broadcasts.js.map +1 -0
- package/tools/broadcasts/delete-broadcasts.mjs +33 -0
- package/tools/broadcasts/delete-broadcasts.mjs.map +1 -0
- package/tools/broadcasts/list-broadcasts.d.mts +51 -0
- package/tools/broadcasts/list-broadcasts.d.mts.map +1 -0
- package/tools/broadcasts/list-broadcasts.d.ts +51 -0
- package/tools/broadcasts/list-broadcasts.d.ts.map +1 -0
- package/tools/broadcasts/list-broadcasts.js +68 -0
- package/tools/broadcasts/list-broadcasts.js.map +1 -0
- package/tools/broadcasts/list-broadcasts.mjs +61 -0
- package/tools/broadcasts/list-broadcasts.mjs.map +1 -0
- package/tools/broadcasts/progress-broadcasts.d.mts +51 -0
- package/tools/broadcasts/progress-broadcasts.d.mts.map +1 -0
- package/tools/broadcasts/progress-broadcasts.d.ts +51 -0
- package/tools/broadcasts/progress-broadcasts.d.ts.map +1 -0
- package/tools/broadcasts/progress-broadcasts.js +54 -0
- package/tools/broadcasts/progress-broadcasts.js.map +1 -0
- package/tools/broadcasts/progress-broadcasts.mjs +47 -0
- package/tools/broadcasts/progress-broadcasts.mjs.map +1 -0
- package/tools/broadcasts/retrieve-broadcasts.d.mts +51 -0
- package/tools/broadcasts/retrieve-broadcasts.d.mts.map +1 -0
- package/tools/broadcasts/retrieve-broadcasts.d.ts +51 -0
- package/tools/broadcasts/retrieve-broadcasts.d.ts.map +1 -0
- package/tools/broadcasts/retrieve-broadcasts.js +54 -0
- package/tools/broadcasts/retrieve-broadcasts.js.map +1 -0
- package/tools/broadcasts/retrieve-broadcasts.mjs +47 -0
- package/tools/broadcasts/retrieve-broadcasts.mjs.map +1 -0
- package/tools/broadcasts/send-broadcasts.d.mts +51 -0
- package/tools/broadcasts/send-broadcasts.d.mts.map +1 -0
- package/tools/broadcasts/send-broadcasts.d.ts +51 -0
- package/tools/broadcasts/send-broadcasts.d.ts.map +1 -0
- package/tools/broadcasts/send-broadcasts.js +57 -0
- package/tools/broadcasts/send-broadcasts.js.map +1 -0
- package/tools/broadcasts/send-broadcasts.mjs +50 -0
- package/tools/broadcasts/send-broadcasts.mjs.map +1 -0
- package/tools/broadcasts/update-broadcasts.d.mts +51 -0
- package/tools/broadcasts/update-broadcasts.d.mts.map +1 -0
- package/tools/broadcasts/update-broadcasts.d.ts +51 -0
- package/tools/broadcasts/update-broadcasts.d.ts.map +1 -0
- package/tools/broadcasts/update-broadcasts.js +104 -0
- package/tools/broadcasts/update-broadcasts.js.map +1 -0
- package/tools/broadcasts/update-broadcasts.mjs +97 -0
- package/tools/broadcasts/update-broadcasts.mjs.map +1 -0
- package/tools/contacts/list-contacts.d.mts +51 -0
- package/tools/contacts/list-contacts.d.mts.map +1 -0
- package/tools/contacts/list-contacts.d.ts +51 -0
- package/tools/contacts/list-contacts.d.ts.map +1 -0
- package/tools/contacts/list-contacts.js +61 -0
- package/tools/contacts/list-contacts.js.map +1 -0
- package/tools/contacts/list-contacts.mjs +54 -0
- package/tools/contacts/list-contacts.mjs.map +1 -0
- package/tools/contacts/retrieve-by-phone-contacts.d.mts +51 -0
- package/tools/contacts/retrieve-by-phone-contacts.d.mts.map +1 -0
- package/tools/contacts/retrieve-by-phone-contacts.d.ts +51 -0
- package/tools/contacts/retrieve-by-phone-contacts.d.ts.map +1 -0
- package/tools/contacts/retrieve-by-phone-contacts.js +54 -0
- package/tools/contacts/retrieve-by-phone-contacts.js.map +1 -0
- package/tools/contacts/retrieve-by-phone-contacts.mjs +47 -0
- package/tools/contacts/retrieve-by-phone-contacts.mjs.map +1 -0
- package/tools/contacts/retrieve-contacts.d.mts +51 -0
- package/tools/contacts/retrieve-contacts.d.mts.map +1 -0
- package/tools/contacts/retrieve-contacts.d.ts +51 -0
- package/tools/contacts/retrieve-contacts.d.ts.map +1 -0
- package/tools/contacts/retrieve-contacts.js +54 -0
- package/tools/contacts/retrieve-contacts.js.map +1 -0
- package/tools/contacts/retrieve-contacts.mjs +47 -0
- package/tools/contacts/retrieve-contacts.mjs.map +1 -0
- package/tools/contacts/update-contacts.d.mts +51 -0
- package/tools/contacts/update-contacts.d.mts.map +1 -0
- package/tools/contacts/update-contacts.d.ts +51 -0
- package/tools/contacts/update-contacts.d.ts.map +1 -0
- package/tools/contacts/update-contacts.js +61 -0
- package/tools/contacts/update-contacts.js.map +1 -0
- package/tools/contacts/update-contacts.mjs +54 -0
- package/tools/contacts/update-contacts.mjs.map +1 -0
- package/tools/index.d.mts +10 -0
- package/tools/index.d.mts.map +1 -0
- package/tools/index.d.ts +10 -0
- package/tools/index.d.ts.map +1 -0
- package/tools/index.js +127 -0
- package/tools/index.js.map +1 -0
- package/tools/index.mjs +120 -0
- package/tools/index.mjs.map +1 -0
- package/tools/introspect/validate-phone-introspect.d.mts +51 -0
- package/tools/introspect/validate-phone-introspect.d.mts.map +1 -0
- package/tools/introspect/validate-phone-introspect.d.ts +51 -0
- package/tools/introspect/validate-phone-introspect.d.ts.map +1 -0
- package/tools/introspect/validate-phone-introspect.js +52 -0
- package/tools/introspect/validate-phone-introspect.js.map +1 -0
- package/tools/introspect/validate-phone-introspect.mjs +45 -0
- package/tools/introspect/validate-phone-introspect.mjs.map +1 -0
- package/tools/messages/list-messages.d.mts +51 -0
- package/tools/messages/list-messages.d.mts.map +1 -0
- package/tools/messages/list-messages.d.ts +51 -0
- package/tools/messages/list-messages.d.ts.map +1 -0
- package/tools/messages/list-messages.js +78 -0
- package/tools/messages/list-messages.js.map +1 -0
- package/tools/messages/list-messages.mjs +71 -0
- package/tools/messages/list-messages.mjs.map +1 -0
- package/tools/messages/react-messages.d.mts +51 -0
- package/tools/messages/react-messages.d.mts.map +1 -0
- package/tools/messages/react-messages.d.ts +51 -0
- package/tools/messages/react-messages.d.ts.map +1 -0
- package/tools/messages/react-messages.js +59 -0
- package/tools/messages/react-messages.js.map +1 -0
- package/tools/messages/react-messages.mjs +52 -0
- package/tools/messages/react-messages.mjs.map +1 -0
- package/tools/messages/retrieve-messages.d.mts +51 -0
- package/tools/messages/retrieve-messages.d.mts.map +1 -0
- package/tools/messages/retrieve-messages.d.ts +51 -0
- package/tools/messages/retrieve-messages.d.ts.map +1 -0
- package/tools/messages/retrieve-messages.js +54 -0
- package/tools/messages/retrieve-messages.js.map +1 -0
- package/tools/messages/retrieve-messages.mjs +47 -0
- package/tools/messages/retrieve-messages.mjs.map +1 -0
- package/tools/messages/send-messages.d.mts +51 -0
- package/tools/messages/send-messages.d.mts.map +1 -0
- package/tools/messages/send-messages.d.ts +51 -0
- package/tools/messages/send-messages.d.ts.map +1 -0
- package/tools/messages/send-messages.js +233 -0
- package/tools/messages/send-messages.js.map +1 -0
- package/tools/messages/send-messages.mjs +226 -0
- package/tools/messages/send-messages.mjs.map +1 -0
- package/tools/phone-numbers/list-phone-numbers.d.mts +51 -0
- package/tools/phone-numbers/list-phone-numbers.d.mts.map +1 -0
- package/tools/phone-numbers/list-phone-numbers.d.ts +51 -0
- package/tools/phone-numbers/list-phone-numbers.d.ts.map +1 -0
- package/tools/phone-numbers/list-phone-numbers.js +68 -0
- package/tools/phone-numbers/list-phone-numbers.js.map +1 -0
- package/tools/phone-numbers/list-phone-numbers.mjs +61 -0
- package/tools/phone-numbers/list-phone-numbers.mjs.map +1 -0
- package/tools/phone-numbers/purchase-phone-numbers.d.mts +51 -0
- package/tools/phone-numbers/purchase-phone-numbers.d.mts.map +1 -0
- package/tools/phone-numbers/purchase-phone-numbers.d.ts +51 -0
- package/tools/phone-numbers/purchase-phone-numbers.d.ts.map +1 -0
- package/tools/phone-numbers/purchase-phone-numbers.js +57 -0
- package/tools/phone-numbers/purchase-phone-numbers.js.map +1 -0
- package/tools/phone-numbers/purchase-phone-numbers.mjs +50 -0
- package/tools/phone-numbers/purchase-phone-numbers.mjs.map +1 -0
- package/tools/phone-numbers/release-phone-numbers.d.mts +51 -0
- package/tools/phone-numbers/release-phone-numbers.d.mts.map +1 -0
- package/tools/phone-numbers/release-phone-numbers.d.ts +51 -0
- package/tools/phone-numbers/release-phone-numbers.d.ts.map +1 -0
- package/tools/phone-numbers/release-phone-numbers.js +37 -0
- package/tools/phone-numbers/release-phone-numbers.js.map +1 -0
- package/tools/phone-numbers/release-phone-numbers.mjs +33 -0
- package/tools/phone-numbers/release-phone-numbers.mjs.map +1 -0
- package/tools/phone-numbers/retrieve-phone-numbers.d.mts +51 -0
- package/tools/phone-numbers/retrieve-phone-numbers.d.mts.map +1 -0
- package/tools/phone-numbers/retrieve-phone-numbers.d.ts +51 -0
- package/tools/phone-numbers/retrieve-phone-numbers.d.ts.map +1 -0
- package/tools/phone-numbers/retrieve-phone-numbers.js +54 -0
- package/tools/phone-numbers/retrieve-phone-numbers.js.map +1 -0
- package/tools/phone-numbers/retrieve-phone-numbers.mjs +47 -0
- package/tools/phone-numbers/retrieve-phone-numbers.mjs.map +1 -0
- package/tools/phone-numbers/search-available-phone-numbers.d.mts +51 -0
- package/tools/phone-numbers/search-available-phone-numbers.d.mts.map +1 -0
- package/tools/phone-numbers/search-available-phone-numbers.d.ts +51 -0
- package/tools/phone-numbers/search-available-phone-numbers.d.ts.map +1 -0
- package/tools/phone-numbers/search-available-phone-numbers.js +72 -0
- package/tools/phone-numbers/search-available-phone-numbers.js.map +1 -0
- package/tools/phone-numbers/search-available-phone-numbers.mjs +65 -0
- package/tools/phone-numbers/search-available-phone-numbers.mjs.map +1 -0
- package/tools/phone-numbers/update-phone-numbers.d.mts +51 -0
- package/tools/phone-numbers/update-phone-numbers.d.mts.map +1 -0
- package/tools/phone-numbers/update-phone-numbers.d.ts +51 -0
- package/tools/phone-numbers/update-phone-numbers.d.ts.map +1 -0
- package/tools/phone-numbers/update-phone-numbers.js +60 -0
- package/tools/phone-numbers/update-phone-numbers.js.map +1 -0
- package/tools/phone-numbers/update-phone-numbers.mjs +53 -0
- package/tools/phone-numbers/update-phone-numbers.mjs.map +1 -0
- package/tools/senders/create-senders.d.mts +51 -0
- package/tools/senders/create-senders.d.mts.map +1 -0
- package/tools/senders/create-senders.d.ts +51 -0
- package/tools/senders/create-senders.d.ts.map +1 -0
- package/tools/senders/create-senders.js +85 -0
- package/tools/senders/create-senders.js.map +1 -0
- package/tools/senders/create-senders.mjs +78 -0
- package/tools/senders/create-senders.mjs.map +1 -0
- package/tools/senders/delete-senders.d.mts +51 -0
- package/tools/senders/delete-senders.d.mts.map +1 -0
- package/tools/senders/delete-senders.d.ts +51 -0
- package/tools/senders/delete-senders.d.ts.map +1 -0
- package/tools/senders/delete-senders.js +37 -0
- package/tools/senders/delete-senders.js.map +1 -0
- package/tools/senders/delete-senders.mjs +33 -0
- package/tools/senders/delete-senders.mjs.map +1 -0
- package/tools/senders/list-senders.d.mts +51 -0
- package/tools/senders/list-senders.d.mts.map +1 -0
- package/tools/senders/list-senders.d.ts +51 -0
- package/tools/senders/list-senders.d.ts.map +1 -0
- package/tools/senders/list-senders.js +58 -0
- package/tools/senders/list-senders.js.map +1 -0
- package/tools/senders/list-senders.mjs +51 -0
- package/tools/senders/list-senders.mjs.map +1 -0
- package/tools/senders/regenerate-webhook-secret-senders.d.mts +51 -0
- package/tools/senders/regenerate-webhook-secret-senders.d.mts.map +1 -0
- package/tools/senders/regenerate-webhook-secret-senders.d.ts +51 -0
- package/tools/senders/regenerate-webhook-secret-senders.d.ts.map +1 -0
- package/tools/senders/regenerate-webhook-secret-senders.js +52 -0
- package/tools/senders/regenerate-webhook-secret-senders.js.map +1 -0
- package/tools/senders/regenerate-webhook-secret-senders.mjs +45 -0
- package/tools/senders/regenerate-webhook-secret-senders.mjs.map +1 -0
- package/tools/senders/retrieve-senders.d.mts +51 -0
- package/tools/senders/retrieve-senders.d.mts.map +1 -0
- package/tools/senders/retrieve-senders.d.ts +51 -0
- package/tools/senders/retrieve-senders.d.ts.map +1 -0
- package/tools/senders/retrieve-senders.js +54 -0
- package/tools/senders/retrieve-senders.js.map +1 -0
- package/tools/senders/retrieve-senders.mjs +47 -0
- package/tools/senders/retrieve-senders.mjs.map +1 -0
- package/tools/senders/update-senders.d.mts +51 -0
- package/tools/senders/update-senders.d.mts.map +1 -0
- package/tools/senders/update-senders.d.ts +51 -0
- package/tools/senders/update-senders.d.ts.map +1 -0
- package/tools/senders/update-senders.js +89 -0
- package/tools/senders/update-senders.js.map +1 -0
- package/tools/senders/update-senders.mjs +82 -0
- package/tools/senders/update-senders.mjs.map +1 -0
- package/tools/templates/create-templates.d.mts +51 -0
- package/tools/templates/create-templates.d.mts.map +1 -0
- package/tools/templates/create-templates.d.ts +51 -0
- package/tools/templates/create-templates.d.ts.map +1 -0
- package/tools/templates/create-templates.js +74 -0
- package/tools/templates/create-templates.js.map +1 -0
- package/tools/templates/create-templates.mjs +67 -0
- package/tools/templates/create-templates.mjs.map +1 -0
- package/tools/templates/delete-templates.d.mts +51 -0
- package/tools/templates/delete-templates.d.mts.map +1 -0
- package/tools/templates/delete-templates.d.ts +51 -0
- package/tools/templates/delete-templates.d.ts.map +1 -0
- package/tools/templates/delete-templates.js +37 -0
- package/tools/templates/delete-templates.js.map +1 -0
- package/tools/templates/delete-templates.mjs +33 -0
- package/tools/templates/delete-templates.mjs.map +1 -0
- package/tools/templates/list-templates.d.mts +51 -0
- package/tools/templates/list-templates.d.mts.map +1 -0
- package/tools/templates/list-templates.d.ts +51 -0
- package/tools/templates/list-templates.d.ts.map +1 -0
- package/tools/templates/list-templates.js +58 -0
- package/tools/templates/list-templates.js.map +1 -0
- package/tools/templates/list-templates.mjs +51 -0
- package/tools/templates/list-templates.mjs.map +1 -0
- package/tools/templates/retrieve-templates.d.mts +51 -0
- package/tools/templates/retrieve-templates.d.mts.map +1 -0
- package/tools/templates/retrieve-templates.d.ts +51 -0
- package/tools/templates/retrieve-templates.d.ts.map +1 -0
- package/tools/templates/retrieve-templates.js +54 -0
- package/tools/templates/retrieve-templates.js.map +1 -0
- package/tools/templates/retrieve-templates.mjs +47 -0
- package/tools/templates/retrieve-templates.mjs.map +1 -0
- package/tools/templates/submit-templates.d.mts +51 -0
- package/tools/templates/submit-templates.d.mts.map +1 -0
- package/tools/templates/submit-templates.d.ts +51 -0
- package/tools/templates/submit-templates.d.ts.map +1 -0
- package/tools/templates/submit-templates.js +66 -0
- package/tools/templates/submit-templates.js.map +1 -0
- package/tools/templates/submit-templates.mjs +59 -0
- package/tools/templates/submit-templates.mjs.map +1 -0
- package/tools/types.d.mts +52 -0
- package/tools/types.d.mts.map +1 -0
- package/tools/types.d.ts +52 -0
- package/tools/types.d.ts.map +1 -0
- package/tools/types.js +58 -0
- package/tools/types.js.map +1 -0
- package/tools/types.mjs +53 -0
- package/tools/types.mjs.map +1 -0
- package/tools.d.mts +2 -0
- package/tools.d.mts.map +1 -0
- package/tools.d.ts +2 -0
- package/tools.d.ts.map +1 -0
- package/tools.js +18 -0
- package/tools.js.map +1 -0
- package/tools.mjs +2 -0
- package/tools.mjs.map +1 -0
package/code-tool.d.ts
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { Metadata, ToolCallResult } from "./tools/types.js";
|
|
2
|
+
/**
|
|
3
|
+
* A tool that runs code against a copy of the SDK.
|
|
4
|
+
*
|
|
5
|
+
* Instead of exposing every endpoint as its own tool, which uses up too many tokens for LLMs to use at once,
|
|
6
|
+
* we expose a single tool that can be used to search for endpoints by name, resource, operation, or tag, and then
|
|
7
|
+
* a generic endpoint that can be used to invoke any endpoint with the provided arguments.
|
|
8
|
+
*
|
|
9
|
+
* @param endpoints - The endpoints to include in the list.
|
|
10
|
+
*/
|
|
11
|
+
export declare function codeTool(): Promise<{
|
|
12
|
+
metadata: Metadata;
|
|
13
|
+
tool: {
|
|
14
|
+
inputSchema: {
|
|
15
|
+
[x: string]: unknown;
|
|
16
|
+
type: "object";
|
|
17
|
+
properties?: {
|
|
18
|
+
[x: string]: object;
|
|
19
|
+
} | undefined;
|
|
20
|
+
required?: string[] | undefined;
|
|
21
|
+
};
|
|
22
|
+
name: string;
|
|
23
|
+
description?: string | undefined;
|
|
24
|
+
outputSchema?: {
|
|
25
|
+
[x: string]: unknown;
|
|
26
|
+
type: "object";
|
|
27
|
+
properties?: {
|
|
28
|
+
[x: string]: object;
|
|
29
|
+
} | undefined;
|
|
30
|
+
required?: string[] | undefined;
|
|
31
|
+
} | undefined;
|
|
32
|
+
annotations?: {
|
|
33
|
+
title?: string | undefined;
|
|
34
|
+
readOnlyHint?: boolean | undefined;
|
|
35
|
+
destructiveHint?: boolean | undefined;
|
|
36
|
+
idempotentHint?: boolean | undefined;
|
|
37
|
+
openWorldHint?: boolean | undefined;
|
|
38
|
+
} | undefined;
|
|
39
|
+
execution?: {
|
|
40
|
+
taskSupport?: "optional" | "required" | "forbidden" | undefined;
|
|
41
|
+
} | undefined;
|
|
42
|
+
_meta?: {
|
|
43
|
+
[x: string]: unknown;
|
|
44
|
+
} | undefined;
|
|
45
|
+
icons?: {
|
|
46
|
+
src: string;
|
|
47
|
+
mimeType?: string | undefined;
|
|
48
|
+
sizes?: string[] | undefined;
|
|
49
|
+
}[] | undefined;
|
|
50
|
+
title?: string | undefined;
|
|
51
|
+
};
|
|
52
|
+
handler: (_: unknown, args: any) => Promise<ToolCallResult>;
|
|
53
|
+
}>;
|
|
54
|
+
//# sourceMappingURL=code-tool.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool.d.ts","sourceRoot":"","sources":["src/code-tool.ts"],"names":[],"mappings":"OAEO,EAAE,QAAQ,EAAE,cAAc,EAAuB;AAIxD;;;;;;;;GAQG;AACH,wBAAsB,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAQF,OAAO,QAAQ,GAAG,KAAG,OAAO,CAAC,cAAc,CAAC;GAmCvE"}
|
package/code-tool.js
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.codeTool = codeTool;
|
|
5
|
+
const types_1 = require("./tools/types.js");
|
|
6
|
+
const server_1 = require("./server.js");
|
|
7
|
+
/**
|
|
8
|
+
* A tool that runs code against a copy of the SDK.
|
|
9
|
+
*
|
|
10
|
+
* Instead of exposing every endpoint as its own tool, which uses up too many tokens for LLMs to use at once,
|
|
11
|
+
* we expose a single tool that can be used to search for endpoints by name, resource, operation, or tag, and then
|
|
12
|
+
* a generic endpoint that can be used to invoke any endpoint with the provided arguments.
|
|
13
|
+
*
|
|
14
|
+
* @param endpoints - The endpoints to include in the list.
|
|
15
|
+
*/
|
|
16
|
+
async function codeTool() {
|
|
17
|
+
const metadata = { resource: 'all', operation: 'write', tags: [] };
|
|
18
|
+
const tool = {
|
|
19
|
+
name: 'execute',
|
|
20
|
+
description: 'Runs JavaScript code to interact with the API.\n\nYou are a skilled programmer writing code to interface with the service.\nDefine an async function named "run" that takes a single parameter of an initialized SDK client and it will be run.\nWrite code within this template:\n\n```\nasync function run(client) {\n // Fill this out\n}\n```\n\nYou will be returned anything that your function returns, plus the results of any console.log statements.\nIf any code triggers an error, the tool will return an error response, so you do not need to add error handling unless you want to output something more helpful than the raw error.\nIt is not necessary to add comments to code, unless by adding those comments you believe that you can generate better code.\nThis code will run in a container, and you will not be able to use fetch or otherwise interact with the network calls other than through the client you are given.\nAny variables you define won\'t live between successive uses of this call, so make sure to return or log any data you might need later.',
|
|
21
|
+
inputSchema: { type: 'object', properties: { code: { type: 'string' } } },
|
|
22
|
+
};
|
|
23
|
+
const handler = async (_, args) => {
|
|
24
|
+
const code = args.code;
|
|
25
|
+
// this is not required, but passing a Stainless API key for the matching project_name
|
|
26
|
+
// will allow you to run code-mode queries against non-published versions of your SDK.
|
|
27
|
+
const stainlessAPIKey = (0, server_1.readEnv)('STAINLESS_API_KEY');
|
|
28
|
+
const codeModeEndpoint = (0, server_1.readEnv)('CODE_MODE_ENDPOINT_URL') ?? 'https://api.stainless.com/api/ai/code-tool';
|
|
29
|
+
const res = await fetch(codeModeEndpoint, {
|
|
30
|
+
method: 'POST',
|
|
31
|
+
headers: {
|
|
32
|
+
...(stainlessAPIKey && { Authorization: stainlessAPIKey }),
|
|
33
|
+
'Content-Type': 'application/json',
|
|
34
|
+
client_envs: JSON.stringify({ ZAVUDEV_API_KEY: (0, server_1.readEnv)('ZAVUDEV_API_KEY') }),
|
|
35
|
+
},
|
|
36
|
+
body: JSON.stringify({
|
|
37
|
+
project_name: 'zavudev',
|
|
38
|
+
client_opts: {},
|
|
39
|
+
code,
|
|
40
|
+
}),
|
|
41
|
+
});
|
|
42
|
+
if (!res.ok) {
|
|
43
|
+
throw new Error(`${res.status}: ${res.statusText} error when trying to contact Code Tool server. Details: ${await res.text()}`);
|
|
44
|
+
}
|
|
45
|
+
return (0, types_1.asTextContentResult)((await res.json()));
|
|
46
|
+
};
|
|
47
|
+
return { metadata, tool, handler };
|
|
48
|
+
}
|
|
49
|
+
//# sourceM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vB,WAAW,EAAE,EAAE;gBACf,IAAI;aACL,CAAC;SACH,CAAC,CAAC;QAEH,IAAI,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC;YACZ,MAAM,IAAI,KAAK,CACb,GAAG,GAAG,CAAC,MAAM,KACX,GAAG,CAAC,UACN,4DAA4D,MAAM,GAAG,CAAC,IAAI,EAAE,EAAE,CAC/E,CAAC;QACJ,CAAC;QAED,OAAO,IAAA,2BAAmB,EAAC,CAAC,MAAM,GAAG,CAAC,IAAI,EAAE,CAAkB,CAAC,CAAC;IAClE,CAAC,CAAC;IAEF,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;AACrC,CAAC"}
|
package/code-tool.mjs
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { asTextContentResult } from "./tools/types.mjs";
|
|
3
|
+
import { readEnv } from "./server.mjs";
|
|
4
|
+
/**
|
|
5
|
+
* A tool that runs code against a copy of the SDK.
|
|
6
|
+
*
|
|
7
|
+
* Instead of exposing every endpoint as its own tool, which uses up too many tokens for LLMs to use at once,
|
|
8
|
+
* we expose a single tool that can be used to search for endpoints by name, resource, operation, or tag, and then
|
|
9
|
+
* a generic endpoint that can be used to invoke any endpoint with the provided arguments.
|
|
10
|
+
*
|
|
11
|
+
* @param endpoints - The endpoints to include in the list.
|
|
12
|
+
*/
|
|
13
|
+
export async function codeTool() {
|
|
14
|
+
const metadata = { resource: 'all', operation: 'write', tags: [] };
|
|
15
|
+
const tool = {
|
|
16
|
+
name: 'execute',
|
|
17
|
+
description: 'Runs JavaScript code to interact with the API.\n\nYou are a skilled programmer writing code to interface with the service.\nDefine an async function named "run" that takes a single parameter of an initialized SDK client and it will be run.\nWrite code within this template:\n\n```\nasync function run(client) {\n // Fill this out\n}\n```\n\nYou will be returned anything that your function returns, plus the results of any console.log statements.\nIf any code triggers an error, the tool will return an error response, so you do not need to add error handling unless you want to output something more helpful than the raw error.\nIt is not necessary to add comments to code, unless by adding those comments you believe that you can generate better code.\nThis code will run in a container, and you will not be able to use fetch or otherwise interact with the network calls other than through the client you are given.\nAny variables you define won\'t live between successive uses of this call, so make sure to return or log any data you might need later.',
|
|
18
|
+
inputSchema: { type: 'object', properties: { code: { type: 'string' } } },
|
|
19
|
+
};
|
|
20
|
+
const handler = async (_, args) => {
|
|
21
|
+
const code = args.code;
|
|
22
|
+
// this is not required, but passing a Stainless API key for the matching project_name
|
|
23
|
+
// will allow you to run code-mode queries against non-published versions of your SDK.
|
|
24
|
+
const stainlessAPIKey = readEnv('STAINLESS_API_KEY');
|
|
25
|
+
const codeModeEndpoint = readEnv('CODE_MODE_ENDPOINT_URL') ?? 'https://api.stainless.com/api/ai/code-tool';
|
|
26
|
+
const res = await fetch(codeModeEndpoint, {
|
|
27
|
+
method: 'POST',
|
|
28
|
+
headers: {
|
|
29
|
+
...(stainlessAPIKey && { Authorization: stainlessAPIKey }),
|
|
30
|
+
'Content-Type': 'application/json',
|
|
31
|
+
client_envs: JSON.stringify({ ZAVUDEV_API_KEY: readEnv('ZAVUDEV_API_KEY') }),
|
|
32
|
+
},
|
|
33
|
+
body: JSON.stringify({
|
|
34
|
+
project_name: 'zavudev',
|
|
35
|
+
client_opts: {},
|
|
36
|
+
code,
|
|
37
|
+
}),
|
|
38
|
+
});
|
|
39
|
+
if (!res.ok) {
|
|
40
|
+
throw new Error(`${res.status}: ${res.statusText} error when trying to contact Code Tool server. Details: ${await res.text()}`);
|
|
41
|
+
}
|
|
42
|
+
return asTextContentResult((await res.json()));
|
|
43
|
+
};
|
|
44
|
+
return { metadata, tool, handler };
|
|
45
|
+
}
|
|
46
|
+
//# sourceMappingURL=code-tool.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool.mjs","sourceRoot":"","sources":["src/code-tool.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAA4B,mBAAmB,E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C,UACN,4DAA4D,MAAM,GAAG,CAAC,IAAI,EAAE,EAAE,CAC/E,CAAC;QACJ,CAAC;QAED,OAAO,mBAAmB,CAAC,CAAC,MAAM,GAAG,CAAC,IAAI,EAAE,CAAkB,CAAC,CAAC;IAClE,CAAC,CAAC;IAEF,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;AACrC,CAAC"}
|
package/compat.d.mts
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { Tool } from '@modelcontextprotocol/sdk/types.js';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
import { Endpoint } from "./tools.mjs";
|
|
4
|
+
export interface ClientCapabilities {
|
|
5
|
+
topLevelUnions: boolean;
|
|
6
|
+
validJson: boolean;
|
|
7
|
+
refs: boolean;
|
|
8
|
+
unions: boolean;
|
|
9
|
+
formats: boolean;
|
|
10
|
+
toolNameLength: number | undefined;
|
|
11
|
+
}
|
|
12
|
+
export declare const defaultClientCapabilities: ClientCapabilities;
|
|
13
|
+
export declare const ClientType: z.ZodEnum<["openai-agents", "claude", "claude-code", "cursor", "infer"]>;
|
|
14
|
+
export type ClientType = z.infer<typeof ClientType>;
|
|
15
|
+
export declare const knownClients: Record<Exclude<ClientType, 'infer'>, ClientCapabilities>;
|
|
16
|
+
/**
|
|
17
|
+
* Attempts to parse strings into JSON objects
|
|
18
|
+
*/
|
|
19
|
+
export declare function parseEmbeddedJSON(args: Record<string, unknown>, schema: Record<string, unknown>): Record<string, unknown>;
|
|
20
|
+
export type JSONSchema = {
|
|
21
|
+
type?: string;
|
|
22
|
+
properties?: Record<string, JSONSchema>;
|
|
23
|
+
required?: string[];
|
|
24
|
+
anyOf?: JSONSchema[];
|
|
25
|
+
$ref?: string;
|
|
26
|
+
$defs?: Record<string, JSONSchema>;
|
|
27
|
+
[key: string]: any;
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* Truncates tool names to the specified length while ensuring uniqueness.
|
|
31
|
+
* If truncation would cause duplicate names, appends a number to make them unique.
|
|
32
|
+
*/
|
|
33
|
+
export declare function truncateToolNames(names: string[], maxLength: number): Map<string, string>;
|
|
34
|
+
/**
|
|
35
|
+
* Removes top-level unions from a tool by splitting it into multiple tools,
|
|
36
|
+
* one for each variant in the union.
|
|
37
|
+
*/
|
|
38
|
+
export declare function removeTopLevelUnions(tool: Tool): Tool[];
|
|
39
|
+
declare function findUsedDefs(schema: JSONSchema, defs: Record<string, JSONSchema>, visited?: Set<string>): Record<string, JSONSchema>;
|
|
40
|
+
export { findUsedDefs };
|
|
41
|
+
/**
|
|
42
|
+
* Inlines all $refs in a schema, eliminating $defs.
|
|
43
|
+
* If a circular reference is detected, the circular property is removed.
|
|
44
|
+
*/
|
|
45
|
+
export declare function inlineRefs(schema: JSONSchema): JSONSchema;
|
|
46
|
+
/**
|
|
47
|
+
* Removes anyOf fields from a schema, using only the first variant.
|
|
48
|
+
*/
|
|
49
|
+
export declare function removeAnyOf(schema: JSONSchema): JSONSchema;
|
|
50
|
+
/**
|
|
51
|
+
* Removes format fields from a schema and appends them to the description.
|
|
52
|
+
*/
|
|
53
|
+
export declare function removeFormats(schema: JSONSchema, formatsCapability: boolean): JSONSchema;
|
|
54
|
+
/**
|
|
55
|
+
* Applies all compatibility transformations to the endpoints based on the provided capabilities.
|
|
56
|
+
*/
|
|
57
|
+
export declare function applyCompatibilityTransformations(endpoints: Endpoint[], capabilities: ClientCapabilities): Endpoint[];
|
|
58
|
+
//# sourceMappingURL=compat.d.mts.map
|
package/compat.d.mts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"compat.d.mts","sourceRoot":"","sources":["src/compat.ts"],"names":[],"mappings":"OAAO,EAAE,IAAI,EAAE,MAAM,oCAAoC;OAClD,EAAE,CAAC,EAAE,MAAM,KAAK;OAChB,EAAE,QAAQ,EAAE;AAEnB,MAAM,WAAW,kBAAkB;IACjC,cAAc,EAAE,OAAO,CAAC;IACxB,SAAS,EAAE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AAE,MAAM,CAAC,MAAM,EAAE,UAAU,CAAC,EAChC,OAAO,GAAE,GAAG,CAAC,MAAM,CAAa,GAC/B,MAAM,CAAC,MAAM,EAAE,UAAU,CAAC,CA6B5B;AAGD,OAAO,EAAE,YAAY,EAAE,CAAC;AAExB;;;GAGG;AACH,wBAAgB,UAAU,CAAC,MAAM,EAAE,UAAU,GAAG,UAAU,CAazD;AAoED;;GAEG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,UAAU,GAAG,UAAU,CA0C1D;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,MAAM,EAAE,UAAU,EAAE,iBAAiB,EAAE,OAAO,GAAG,UAAU,CAkCxF;AAED;;GAEG;AACH,wBAAgB,iCAAiC,CAC/C,SAAS,EAAE,QAAQ,EAAE,EACrB,YAAY,EAAE,kBAAkB,GAC/B,QAAQ,EAAE,CAiEZ"}
|
package/compat.d.ts
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { Tool } from '@modelcontextprotocol/sdk/types.js';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
import { Endpoint } from "./tools.js";
|
|
4
|
+
export interface ClientCapabilities {
|
|
5
|
+
topLevelUnions: boolean;
|
|
6
|
+
validJson: boolean;
|
|
7
|
+
refs: boolean;
|
|
8
|
+
unions: boolean;
|
|
9
|
+
formats: boolean;
|
|
10
|
+
toolNameLength: number | undefined;
|
|
11
|
+
}
|
|
12
|
+
export declare const defaultClientCapabilities: ClientCapabilities;
|
|
13
|
+
export declare const ClientType: z.ZodEnum<["openai-agents", "claude", "claude-code", "cursor", "infer"]>;
|
|
14
|
+
export type ClientType = z.infer<typeof ClientType>;
|
|
15
|
+
export declare const knownClients: Record<Exclude<ClientType, 'infer'>, ClientCapabilities>;
|
|
16
|
+
/**
|
|
17
|
+
* Attempts to parse strings into JSON objects
|
|
18
|
+
*/
|
|
19
|
+
export declare function parseEmbeddedJSON(args: Record<string, unknown>, schema: Record<string, unknown>): Record<string, unknown>;
|
|
20
|
+
export type JSONSchema = {
|
|
21
|
+
type?: string;
|
|
22
|
+
properties?: Record<string, JSONSchema>;
|
|
23
|
+
required?: string[];
|
|
24
|
+
anyOf?: JSONSchema[];
|
|
25
|
+
$ref?: string;
|
|
26
|
+
$defs?: Record<string, JSONSchema>;
|
|
27
|
+
[key: string]: any;
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* Truncates tool names to the specified length while ensuring uniqueness.
|
|
31
|
+
* If truncation would cause duplicate names, appends a number to make them unique.
|
|
32
|
+
*/
|
|
33
|
+
export declare function truncateToolNames(names: string[], maxLength: number): Map<string, string>;
|
|
34
|
+
/**
|
|
35
|
+
* Removes top-level unions from a tool by splitting it into multiple tools,
|
|
36
|
+
* one for each variant in the union.
|
|
37
|
+
*/
|
|
38
|
+
export declare function removeTopLevelUnions(tool: Tool): Tool[];
|
|
39
|
+
declare function findUsedDefs(schema: JSONSchema, defs: Record<string, JSONSchema>, visited?: Set<string>): Record<string, JSONSchema>;
|
|
40
|
+
export { findUsedDefs };
|
|
41
|
+
/**
|
|
42
|
+
* Inlines all $refs in a schema, eliminating $defs.
|
|
43
|
+
* If a circular reference is detected, the circular property is removed.
|
|
44
|
+
*/
|
|
45
|
+
export declare function inlineRefs(schema: JSONSchema): JSONSchema;
|
|
46
|
+
/**
|
|
47
|
+
* Removes anyOf fields from a schema, using only the first variant.
|
|
48
|
+
*/
|
|
49
|
+
export declare function removeAnyOf(schema: JSONSchema): JSONSchema;
|
|
50
|
+
/**
|
|
51
|
+
* Removes format fields from a schema and appends them to the description.
|
|
52
|
+
*/
|
|
53
|
+
export declare function removeFormats(schema: JSONSchema, formatsCapability: boolean): JSONSchema;
|
|
54
|
+
/**
|
|
55
|
+
* Applies all compatibility transformations to the endpoints based on the provided capabilities.
|
|
56
|
+
*/
|
|
57
|
+
export declare function applyCompatibilityTransformations(endpoints: Endpoint[], capabilities: ClientCapabilities): Endpoint[];
|
|
58
|
+
//# sourceMappingURL=compat.d.ts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