@metronome/mcp 0.3.0 → 2.0.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/README.md +1062 -76
- package/code-tool-paths.cjs +6 -0
- package/code-tool-paths.cjs.map +1 -0
- package/code-tool-paths.d.cts +2 -0
- package/code-tool-paths.d.cts.map +1 -0
- package/code-tool-types.d.mts +14 -0
- package/code-tool-types.d.mts.map +1 -0
- package/code-tool-types.d.ts +14 -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-worker.d.mts +5 -0
- package/code-tool-worker.d.mts.map +1 -0
- package/code-tool-worker.d.ts +5 -0
- package/code-tool-worker.d.ts.map +1 -0
- package/code-tool-worker.js +45 -0
- package/code-tool-worker.js.map +1 -0
- package/code-tool-worker.mjs +40 -0
- package/code-tool-worker.mjs.map +1 -0
- package/code-tool.d.mts +12 -0
- package/code-tool.d.mts.map +1 -0
- package/code-tool.d.ts +12 -0
- package/code-tool.d.ts.map +1 -0
- package/code-tool.js +158 -0
- package/code-tool.js.map +1 -0
- package/code-tool.mjs +122 -0
- package/code-tool.mjs.map +1 -0
- package/compat.d.mts +4 -2
- package/compat.d.mts.map +1 -1
- package/compat.d.ts +4 -2
- package/compat.d.ts.map +1 -1
- package/compat.js +3 -1
- package/compat.js.map +1 -1
- package/compat.mjs +2 -0
- package/compat.mjs.map +1 -1
- package/docs-search-tool.d.mts +44 -0
- package/docs-search-tool.d.mts.map +1 -0
- package/docs-search-tool.d.ts +44 -0
- package/docs-search-tool.d.ts.map +1 -0
- package/docs-search-tool.js +43 -0
- package/docs-search-tool.js.map +1 -0
- package/docs-search-tool.mjs +39 -0
- package/docs-search-tool.mjs.map +1 -0
- package/dynamic-tools.js +3 -3
- package/dynamic-tools.js.map +1 -1
- package/dynamic-tools.mjs +3 -3
- package/dynamic-tools.mjs.map +1 -1
- package/headers.d.mts +1 -1
- package/headers.d.mts.map +1 -1
- package/headers.d.ts +1 -1
- package/headers.d.ts.map +1 -1
- package/headers.js +1 -1
- package/headers.js.map +1 -1
- package/headers.mjs +1 -1
- package/headers.mjs.map +1 -1
- package/http.d.mts +6 -3
- package/http.d.mts.map +1 -1
- package/http.d.ts +6 -3
- package/http.d.ts.map +1 -1
- package/http.js +25 -10
- package/http.js.map +1 -1
- package/http.mjs +25 -10
- package/http.mjs.map +1 -1
- package/index.js +6 -6
- package/index.js.map +1 -1
- package/index.mjs +7 -7
- package/index.mjs.map +1 -1
- package/options.d.mts +9 -6
- package/options.d.mts.map +1 -1
- package/options.d.ts +9 -6
- package/options.d.ts.map +1 -1
- package/options.js +126 -16
- package/options.js.map +1 -1
- package/options.mjs +125 -16
- package/options.mjs.map +1 -1
- package/package.json +171 -10
- package/server.d.mts +3 -16
- package/server.d.mts.map +1 -1
- package/server.d.ts +3 -16
- package/server.d.ts.map +1 -1
- package/server.js +87 -25
- package/server.js.map +1 -1
- package/server.mjs +86 -24
- package/server.mjs.map +1 -1
- package/src/code-tool-paths.cts +3 -0
- package/src/code-tool-types.ts +14 -0
- package/src/code-tool-worker.ts +46 -0
- package/src/code-tool.ts +147 -0
- package/src/compat.ts +4 -2
- package/src/docs-search-tool.ts +48 -0
- package/src/dynamic-tools.ts +3 -3
- package/src/headers.ts +2 -3
- package/src/http.ts +54 -26
- package/src/index.ts +7 -7
- package/src/options.ts +147 -22
- package/src/server.ts +99 -36
- package/src/stdio.ts +3 -4
- package/src/tools/index.ts +12 -0
- package/src/tools/v1/alerts/archive-v1-alerts.ts +3 -3
- package/src/tools/v1/alerts/create-v1-alerts.ts +15 -14
- package/src/tools/v1/audit-logs/list-v1-audit-logs.ts +1 -1
- package/src/tools/v1/billable-metrics/archive-v1-billable-metrics.ts +1 -1
- package/src/tools/v1/billable-metrics/create-v1-billable-metrics.ts +1 -1
- package/src/tools/v1/billable-metrics/list-v1-billable-metrics.ts +1 -1
- package/src/tools/v1/billable-metrics/retrieve-v1-billable-metrics.ts +1 -1
- package/src/tools/v1/contracts/add-manual-balance-entry-v1-contracts.ts +2 -1
- package/src/tools/v1/contracts/amend-v1-contracts.ts +86 -143
- package/src/tools/v1/contracts/archive-v1-contracts.ts +1 -1
- package/src/tools/v1/contracts/create-historical-invoices-v1-contracts.ts +3 -1
- package/src/tools/v1/contracts/create-v1-contracts.ts +258 -517
- package/src/tools/v1/contracts/list-balances-v1-contracts.ts +4 -2
- package/src/tools/v1/contracts/list-v1-contracts.ts +1 -1
- package/src/tools/v1/contracts/named-schedules/retrieve-contracts-v1-named-schedules.ts +1 -1
- package/src/tools/v1/contracts/products/archive-contracts-v1-products.ts +1 -1
- package/src/tools/v1/contracts/products/create-contracts-v1-products.ts +2 -1
- package/src/tools/v1/contracts/products/list-contracts-v1-products.ts +1 -1
- package/src/tools/v1/contracts/products/retrieve-contracts-v1-products.ts +1 -1
- package/src/tools/v1/contracts/products/update-contracts-v1-products.ts +1 -1
- package/src/tools/v1/contracts/rate-cards/archive-contracts-v1-rate-cards.ts +1 -1
- package/src/tools/v1/contracts/rate-cards/create-contracts-v1-rate-cards.ts +2 -1
- package/src/tools/v1/contracts/rate-cards/list-contracts-v1-rate-cards.ts +1 -1
- package/src/tools/v1/contracts/rate-cards/named-schedules/retrieve-rate-cards-contracts-v1-named-schedules.ts +1 -1
- package/src/tools/v1/contracts/rate-cards/product-orders/set-rate-cards-contracts-v1-product-orders.ts +1 -1
- package/src/tools/v1/contracts/rate-cards/product-orders/update-rate-cards-contracts-v1-product-orders.ts +1 -1
- package/src/tools/v1/contracts/rate-cards/rates/add-many-rate-cards-contracts-v1-rates.ts +25 -22
- package/src/tools/v1/contracts/rate-cards/rates/add-rate-cards-contracts-v1-rates.ts +25 -22
- package/src/tools/v1/contracts/rate-cards/rates/list-rate-cards-contracts-v1-rates.ts +1 -1
- package/src/tools/v1/contracts/rate-cards/retrieve-contracts-v1-rate-cards.ts +1 -1
- package/src/tools/v1/contracts/rate-cards/retrieve-rate-schedule-contracts-v1-rate-cards.ts +1 -1
- package/src/tools/v1/contracts/rate-cards/update-contracts-v1-rate-cards.ts +1 -1
- package/src/tools/v1/contracts/retrieve-rate-schedule-v1-contracts.ts +1 -1
- package/src/tools/v1/contracts/retrieve-subscription-quantity-history-v1-contracts.ts +1 -1
- package/src/tools/v1/contracts/set-usage-filter-v1-contracts.ts +2 -1
- package/src/tools/v1/contracts/update-end-date-v1-contracts.ts +1 -1
- package/src/tools/v1/credit-grants/create-v1-credit-grants.ts +1 -1
- package/src/tools/v1/credit-grants/edit-v1-credit-grants.ts +1 -1
- package/src/tools/v1/credit-grants/list-entries-v1-credit-grants.ts +3 -2
- package/src/tools/v1/credit-grants/list-v1-credit-grants.ts +1 -1
- package/src/tools/v1/credit-grants/void-v1-credit-grants.ts +1 -1
- package/src/tools/v1/custom-fields/add-key-v1-custom-fields.ts +1 -1
- package/src/tools/v1/custom-fields/delete-values-v1-custom-fields.ts +2 -1
- package/src/tools/v1/custom-fields/list-keys-v1-custom-fields.ts +3 -2
- package/src/tools/v1/custom-fields/remove-key-v1-custom-fields.ts +2 -1
- package/src/tools/v1/custom-fields/set-values-v1-custom-fields.ts +2 -1
- package/src/tools/v1/customers/alerts/list-customers-v1-alerts.ts +5 -3
- package/src/tools/v1/customers/alerts/reset-customers-v1-alerts.ts +3 -2
- package/src/tools/v1/customers/alerts/retrieve-customers-v1-alerts.ts +24 -12
- package/src/tools/v1/customers/archive-v1-customers.ts +1 -1
- package/src/tools/v1/customers/billing-config/create-customers-v1-billing-config.ts +6 -1
- package/src/tools/v1/customers/billing-config/retrieve-customers-v1-billing-config.ts +1 -1
- package/src/tools/v1/customers/commits/create-customers-v1-commits.ts +32 -33
- package/src/tools/v1/customers/commits/list-customers-v1-commits.ts +4 -2
- package/src/tools/v1/customers/commits/update-end-date-customers-v1-commits.ts +1 -1
- package/src/tools/v1/customers/create-v1-customers.ts +14 -2
- package/src/tools/v1/customers/credits/create-customers-v1-credits.ts +30 -24
- package/src/tools/v1/customers/credits/list-customers-v1-credits.ts +4 -2
- package/src/tools/v1/customers/credits/update-end-date-customers-v1-credits.ts +1 -1
- package/src/tools/v1/customers/invoices/add-charge-customers-v1-invoices.ts +1 -1
- package/src/tools/v1/customers/invoices/list-breakdowns-customers-v1-invoices.ts +1 -1
- package/src/tools/v1/customers/invoices/list-customers-v1-invoices.ts +1 -1
- package/src/tools/v1/customers/invoices/retrieve-customers-v1-invoices.ts +2 -1
- package/src/tools/v1/customers/invoices/retrieve-pdf-customers-v1-invoices.ts +43 -0
- package/src/tools/v1/customers/list-billable-metrics-v1-customers.ts +1 -1
- package/src/tools/v1/customers/list-costs-v1-customers.ts +1 -1
- package/src/tools/v1/customers/list-v1-customers.ts +1 -1
- package/src/tools/v1/customers/named-schedules/retrieve-customers-v1-named-schedules.ts +1 -1
- package/src/tools/v1/customers/plans/add-customers-v1-plans.ts +1 -1
- package/src/tools/v1/customers/plans/end-customers-v1-plans.ts +1 -1
- package/src/tools/v1/customers/plans/list-customers-v1-plans.ts +1 -1
- package/src/tools/v1/customers/plans/list-price-adjustments-customers-v1-plans.ts +1 -1
- package/src/tools/v1/customers/preview-events-v1-customers.ts +2 -7
- package/src/tools/v1/customers/retrieve-billing-configurations-v1-customers.ts +50 -0
- package/src/tools/v1/customers/retrieve-v1-customers.ts +1 -1
- package/src/tools/v1/customers/set-billing-configurations-v1-customers.ts +85 -0
- package/src/tools/v1/customers/set-ingest-aliases-v1-customers.ts +1 -1
- package/src/tools/v1/customers/set-name-v1-customers.ts +1 -1
- package/src/tools/v1/customers/update-config-v1-customers.ts +2 -1
- package/src/tools/v1/dashboards/get-embeddable-url-v1-dashboards.ts +1 -1
- package/src/tools/v1/invoices/regenerate-v1-invoices.ts +1 -1
- package/src/tools/v1/invoices/void-v1-invoices.ts +1 -1
- package/src/tools/v1/payments/attempt-v1-payments.ts +48 -0
- package/src/tools/v1/payments/cancel-v1-payments.ts +48 -0
- package/src/tools/v1/payments/list-v1-payments.ts +69 -0
- package/src/tools/v1/plans/get-details-v1-plans.ts +1 -1
- package/src/tools/v1/plans/list-charges-v1-plans.ts +1 -1
- package/src/tools/v1/plans/list-customers-v1-plans.ts +1 -1
- package/src/tools/v1/plans/list-v1-plans.ts +1 -1
- package/src/tools/v1/pricing-units/list-v1-pricing-units.ts +1 -1
- package/src/tools/v1/services/list-v1-services.ts +1 -1
- package/src/tools/v1/usage/ingest-v1-usage.ts +2 -2
- package/src/tools/v1/usage/list-v1-usage.ts +3 -2
- package/src/tools/v1/usage/list-with-groups-v1-usage.ts +1 -1
- package/src/tools/v1/usage/search-v1-usage.ts +1 -1
- package/src/tools/v2/contracts/edit-commit-v2-contracts.ts +84 -24
- package/src/tools/v2/contracts/edit-credit-v2-contracts.ts +84 -24
- package/src/tools/v2/contracts/edit-v2-contracts.ts +314 -782
- package/src/tools/v2/contracts/get-edit-history-v2-contracts.ts +1 -1
- package/src/tools/v2/contracts/list-v2-contracts.ts +1 -1
- package/src/tools/v2/contracts/retrieve-v2-contracts.ts +2 -1
- package/stdio.d.mts +1 -2
- package/stdio.d.mts.map +1 -1
- package/stdio.d.ts +1 -2
- package/stdio.d.ts.map +1 -1
- package/stdio.js +2 -2
- package/stdio.js.map +1 -1
- package/stdio.mjs +3 -3
- package/stdio.mjs.map +1 -1
- package/tools/index.d.mts.map +1 -1
- package/tools/index.d.ts.map +1 -1
- package/tools/index.js +12 -0
- package/tools/index.js.map +1 -1
- package/tools/index.mjs +12 -0
- package/tools/index.mjs.map +1 -1
- package/tools/v1/alerts/archive-v1-alerts.js +3 -3
- package/tools/v1/alerts/archive-v1-alerts.js.map +1 -1
- package/tools/v1/alerts/archive-v1-alerts.mjs +3 -3
- package/tools/v1/alerts/archive-v1-alerts.mjs.map +1 -1
- package/tools/v1/alerts/create-v1-alerts.d.mts.map +1 -1
- package/tools/v1/alerts/create-v1-alerts.d.ts.map +1 -1
- package/tools/v1/alerts/create-v1-alerts.js +14 -14
- package/tools/v1/alerts/create-v1-alerts.js.map +1 -1
- package/tools/v1/alerts/create-v1-alerts.mjs +14 -14
- package/tools/v1/alerts/create-v1-alerts.mjs.map +1 -1
- package/tools/v1/audit-logs/list-v1-audit-logs.js +1 -1
- package/tools/v1/audit-logs/list-v1-audit-logs.js.map +1 -1
- package/tools/v1/audit-logs/list-v1-audit-logs.mjs +1 -1
- package/tools/v1/audit-logs/list-v1-audit-logs.mjs.map +1 -1
- package/tools/v1/billable-metrics/archive-v1-billable-metrics.js +1 -1
- package/tools/v1/billable-metrics/archive-v1-billable-metrics.js.map +1 -1
- package/tools/v1/billable-metrics/archive-v1-billable-metrics.mjs +1 -1
- package/tools/v1/billable-metrics/archive-v1-billable-metrics.mjs.map +1 -1
- package/tools/v1/billable-metrics/create-v1-billable-metrics.js +1 -1
- package/tools/v1/billable-metrics/create-v1-billable-metrics.js.map +1 -1
- package/tools/v1/billable-metrics/create-v1-billable-metrics.mjs +1 -1
- package/tools/v1/billable-metrics/create-v1-billable-metrics.mjs.map +1 -1
- package/tools/v1/billable-metrics/list-v1-billable-metrics.js +1 -1
- package/tools/v1/billable-metrics/list-v1-billable-metrics.js.map +1 -1
- package/tools/v1/billable-metrics/list-v1-billable-metrics.mjs +1 -1
- package/tools/v1/billable-metrics/list-v1-billable-metrics.mjs.map +1 -1
- package/tools/v1/billable-metrics/retrieve-v1-billable-metrics.js +1 -1
- package/tools/v1/billable-metrics/retrieve-v1-billable-metrics.js.map +1 -1
- package/tools/v1/billable-metrics/retrieve-v1-billable-metrics.mjs +1 -1
- package/tools/v1/billable-metrics/retrieve-v1-billable-metrics.mjs.map +1 -1
- package/tools/v1/contracts/add-manual-balance-entry-v1-contracts.d.mts.map +1 -1
- package/tools/v1/contracts/add-manual-balance-entry-v1-contracts.d.ts.map +1 -1
- package/tools/v1/contracts/add-manual-balance-entry-v1-contracts.js +1 -1
- package/tools/v1/contracts/add-manual-balance-entry-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/add-manual-balance-entry-v1-contracts.mjs +1 -1
- package/tools/v1/contracts/add-manual-balance-entry-v1-contracts.mjs.map +1 -1
- package/tools/v1/contracts/amend-v1-contracts.d.mts.map +1 -1
- package/tools/v1/contracts/amend-v1-contracts.d.ts.map +1 -1
- package/tools/v1/contracts/amend-v1-contracts.js +85 -139
- package/tools/v1/contracts/amend-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/amend-v1-contracts.mjs +85 -139
- package/tools/v1/contracts/amend-v1-contracts.mjs.map +1 -1
- package/tools/v1/contracts/archive-v1-contracts.js +1 -1
- package/tools/v1/contracts/archive-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/archive-v1-contracts.mjs +1 -1
- package/tools/v1/contracts/archive-v1-contracts.mjs.map +1 -1
- package/tools/v1/contracts/create-historical-invoices-v1-contracts.d.mts.map +1 -1
- package/tools/v1/contracts/create-historical-invoices-v1-contracts.d.ts.map +1 -1
- package/tools/v1/contracts/create-historical-invoices-v1-contracts.js +2 -1
- package/tools/v1/contracts/create-historical-invoices-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/create-historical-invoices-v1-contracts.mjs +2 -1
- package/tools/v1/contracts/create-historical-invoices-v1-contracts.mjs.map +1 -1
- package/tools/v1/contracts/create-v1-contracts.d.mts.map +1 -1
- package/tools/v1/contracts/create-v1-contracts.d.ts.map +1 -1
- package/tools/v1/contracts/create-v1-contracts.js +241 -485
- package/tools/v1/contracts/create-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/create-v1-contracts.mjs +241 -485
- package/tools/v1/contracts/create-v1-contracts.mjs.map +1 -1
- package/tools/v1/contracts/list-balances-v1-contracts.d.mts.map +1 -1
- package/tools/v1/contracts/list-balances-v1-contracts.d.ts.map +1 -1
- package/tools/v1/contracts/list-balances-v1-contracts.js +3 -2
- package/tools/v1/contracts/list-balances-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/list-balances-v1-contracts.mjs +3 -2
- package/tools/v1/contracts/list-balances-v1-contracts.mjs.map +1 -1
- package/tools/v1/contracts/list-v1-contracts.js +1 -1
- package/tools/v1/contracts/list-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/list-v1-contracts.mjs +1 -1
- package/tools/v1/contracts/list-v1-contracts.mjs.map +1 -1
- package/tools/v1/contracts/named-schedules/retrieve-contracts-v1-named-schedules.js +1 -1
- package/tools/v1/contracts/named-schedules/retrieve-contracts-v1-named-schedules.js.map +1 -1
- package/tools/v1/contracts/named-schedules/retrieve-contracts-v1-named-schedules.mjs +1 -1
- package/tools/v1/contracts/named-schedules/retrieve-contracts-v1-named-schedules.mjs.map +1 -1
- package/tools/v1/contracts/products/archive-contracts-v1-products.js +1 -1
- package/tools/v1/contracts/products/archive-contracts-v1-products.js.map +1 -1
- package/tools/v1/contracts/products/archive-contracts-v1-products.mjs +1 -1
- package/tools/v1/contracts/products/archive-contracts-v1-products.mjs.map +1 -1
- package/tools/v1/contracts/products/create-contracts-v1-products.d.mts.map +1 -1
- package/tools/v1/contracts/products/create-contracts-v1-products.d.ts.map +1 -1
- package/tools/v1/contracts/products/create-contracts-v1-products.js +2 -1
- package/tools/v1/contracts/products/create-contracts-v1-products.js.map +1 -1
- package/tools/v1/contracts/products/create-contracts-v1-products.mjs +2 -1
- package/tools/v1/contracts/products/create-contracts-v1-products.mjs.map +1 -1
- package/tools/v1/contracts/products/list-contracts-v1-products.js +1 -1
- package/tools/v1/contracts/products/list-contracts-v1-products.js.map +1 -1
- package/tools/v1/contracts/products/list-contracts-v1-products.mjs +1 -1
- package/tools/v1/contracts/products/list-contracts-v1-products.mjs.map +1 -1
- package/tools/v1/contracts/products/retrieve-contracts-v1-products.js +1 -1
- package/tools/v1/contracts/products/retrieve-contracts-v1-products.js.map +1 -1
- package/tools/v1/contracts/products/retrieve-contracts-v1-products.mjs +1 -1
- package/tools/v1/contracts/products/retrieve-contracts-v1-products.mjs.map +1 -1
- package/tools/v1/contracts/products/update-contracts-v1-products.js +1 -1
- package/tools/v1/contracts/products/update-contracts-v1-products.js.map +1 -1
- package/tools/v1/contracts/products/update-contracts-v1-products.mjs +1 -1
- package/tools/v1/contracts/products/update-contracts-v1-products.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/archive-contracts-v1-rate-cards.js +1 -1
- package/tools/v1/contracts/rate-cards/archive-contracts-v1-rate-cards.js.map +1 -1
- package/tools/v1/contracts/rate-cards/archive-contracts-v1-rate-cards.mjs +1 -1
- package/tools/v1/contracts/rate-cards/archive-contracts-v1-rate-cards.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/create-contracts-v1-rate-cards.d.mts.map +1 -1
- package/tools/v1/contracts/rate-cards/create-contracts-v1-rate-cards.d.ts.map +1 -1
- package/tools/v1/contracts/rate-cards/create-contracts-v1-rate-cards.js +2 -1
- package/tools/v1/contracts/rate-cards/create-contracts-v1-rate-cards.js.map +1 -1
- package/tools/v1/contracts/rate-cards/create-contracts-v1-rate-cards.mjs +2 -1
- package/tools/v1/contracts/rate-cards/create-contracts-v1-rate-cards.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/list-contracts-v1-rate-cards.js +1 -1
- package/tools/v1/contracts/rate-cards/list-contracts-v1-rate-cards.js.map +1 -1
- package/tools/v1/contracts/rate-cards/list-contracts-v1-rate-cards.mjs +1 -1
- package/tools/v1/contracts/rate-cards/list-contracts-v1-rate-cards.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/named-schedules/retrieve-rate-cards-contracts-v1-named-schedules.js +1 -1
- package/tools/v1/contracts/rate-cards/named-schedules/retrieve-rate-cards-contracts-v1-named-schedules.js.map +1 -1
- package/tools/v1/contracts/rate-cards/named-schedules/retrieve-rate-cards-contracts-v1-named-schedules.mjs +1 -1
- package/tools/v1/contracts/rate-cards/named-schedules/retrieve-rate-cards-contracts-v1-named-schedules.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/product-orders/set-rate-cards-contracts-v1-product-orders.js +1 -1
- package/tools/v1/contracts/rate-cards/product-orders/set-rate-cards-contracts-v1-product-orders.js.map +1 -1
- package/tools/v1/contracts/rate-cards/product-orders/set-rate-cards-contracts-v1-product-orders.mjs +1 -1
- package/tools/v1/contracts/rate-cards/product-orders/set-rate-cards-contracts-v1-product-orders.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/product-orders/update-rate-cards-contracts-v1-product-orders.js +1 -1
- package/tools/v1/contracts/rate-cards/product-orders/update-rate-cards-contracts-v1-product-orders.js.map +1 -1
- package/tools/v1/contracts/rate-cards/product-orders/update-rate-cards-contracts-v1-product-orders.mjs +1 -1
- package/tools/v1/contracts/rate-cards/product-orders/update-rate-cards-contracts-v1-product-orders.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/rates/add-many-rate-cards-contracts-v1-rates.d.mts.map +1 -1
- package/tools/v1/contracts/rate-cards/rates/add-many-rate-cards-contracts-v1-rates.d.ts.map +1 -1
- package/tools/v1/contracts/rate-cards/rates/add-many-rate-cards-contracts-v1-rates.js +24 -21
- package/tools/v1/contracts/rate-cards/rates/add-many-rate-cards-contracts-v1-rates.js.map +1 -1
- package/tools/v1/contracts/rate-cards/rates/add-many-rate-cards-contracts-v1-rates.mjs +24 -21
- package/tools/v1/contracts/rate-cards/rates/add-many-rate-cards-contracts-v1-rates.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/rates/add-rate-cards-contracts-v1-rates.d.mts.map +1 -1
- package/tools/v1/contracts/rate-cards/rates/add-rate-cards-contracts-v1-rates.d.ts.map +1 -1
- package/tools/v1/contracts/rate-cards/rates/add-rate-cards-contracts-v1-rates.js +24 -21
- package/tools/v1/contracts/rate-cards/rates/add-rate-cards-contracts-v1-rates.js.map +1 -1
- package/tools/v1/contracts/rate-cards/rates/add-rate-cards-contracts-v1-rates.mjs +24 -21
- package/tools/v1/contracts/rate-cards/rates/add-rate-cards-contracts-v1-rates.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/rates/list-rate-cards-contracts-v1-rates.js +1 -1
- package/tools/v1/contracts/rate-cards/rates/list-rate-cards-contracts-v1-rates.js.map +1 -1
- package/tools/v1/contracts/rate-cards/rates/list-rate-cards-contracts-v1-rates.mjs +1 -1
- package/tools/v1/contracts/rate-cards/rates/list-rate-cards-contracts-v1-rates.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/retrieve-contracts-v1-rate-cards.js +1 -1
- package/tools/v1/contracts/rate-cards/retrieve-contracts-v1-rate-cards.js.map +1 -1
- package/tools/v1/contracts/rate-cards/retrieve-contracts-v1-rate-cards.mjs +1 -1
- package/tools/v1/contracts/rate-cards/retrieve-contracts-v1-rate-cards.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/retrieve-rate-schedule-contracts-v1-rate-cards.js +1 -1
- package/tools/v1/contracts/rate-cards/retrieve-rate-schedule-contracts-v1-rate-cards.js.map +1 -1
- package/tools/v1/contracts/rate-cards/retrieve-rate-schedule-contracts-v1-rate-cards.mjs +1 -1
- package/tools/v1/contracts/rate-cards/retrieve-rate-schedule-contracts-v1-rate-cards.mjs.map +1 -1
- package/tools/v1/contracts/rate-cards/update-contracts-v1-rate-cards.js +1 -1
- package/tools/v1/contracts/rate-cards/update-contracts-v1-rate-cards.js.map +1 -1
- package/tools/v1/contracts/rate-cards/update-contracts-v1-rate-cards.mjs +1 -1
- package/tools/v1/contracts/rate-cards/update-contracts-v1-rate-cards.mjs.map +1 -1
- package/tools/v1/contracts/retrieve-rate-schedule-v1-contracts.js +1 -1
- package/tools/v1/contracts/retrieve-rate-schedule-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/retrieve-rate-schedule-v1-contracts.mjs +1 -1
- package/tools/v1/contracts/retrieve-rate-schedule-v1-contracts.mjs.map +1 -1
- package/tools/v1/contracts/retrieve-subscription-quantity-history-v1-contracts.js +1 -1
- package/tools/v1/contracts/retrieve-subscription-quantity-history-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/retrieve-subscription-quantity-history-v1-contracts.mjs +1 -1
- package/tools/v1/contracts/retrieve-subscription-quantity-history-v1-contracts.mjs.map +1 -1
- package/tools/v1/contracts/set-usage-filter-v1-contracts.d.mts.map +1 -1
- package/tools/v1/contracts/set-usage-filter-v1-contracts.d.ts.map +1 -1
- package/tools/v1/contracts/set-usage-filter-v1-contracts.js +1 -1
- package/tools/v1/contracts/set-usage-filter-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/set-usage-filter-v1-contracts.mjs +1 -1
- package/tools/v1/contracts/set-usage-filter-v1-contracts.mjs.map +1 -1
- package/tools/v1/contracts/update-end-date-v1-contracts.js +1 -1
- package/tools/v1/contracts/update-end-date-v1-contracts.js.map +1 -1
- package/tools/v1/contracts/update-end-date-v1-contracts.mjs +1 -1
- package/tools/v1/contracts/update-end-date-v1-contracts.mjs.map +1 -1
- package/tools/v1/credit-grants/create-v1-credit-grants.js +1 -1
- package/tools/v1/credit-grants/create-v1-credit-grants.js.map +1 -1
- package/tools/v1/credit-grants/create-v1-credit-grants.mjs +1 -1
- package/tools/v1/credit-grants/create-v1-credit-grants.mjs.map +1 -1
- package/tools/v1/credit-grants/edit-v1-credit-grants.js +1 -1
- package/tools/v1/credit-grants/edit-v1-credit-grants.js.map +1 -1
- package/tools/v1/credit-grants/edit-v1-credit-grants.mjs +1 -1
- package/tools/v1/credit-grants/edit-v1-credit-grants.mjs.map +1 -1
- package/tools/v1/credit-grants/list-entries-v1-credit-grants.d.mts.map +1 -1
- package/tools/v1/credit-grants/list-entries-v1-credit-grants.d.ts.map +1 -1
- package/tools/v1/credit-grants/list-entries-v1-credit-grants.js +3 -2
- package/tools/v1/credit-grants/list-entries-v1-credit-grants.js.map +1 -1
- package/tools/v1/credit-grants/list-entries-v1-credit-grants.mjs +3 -2
- package/tools/v1/credit-grants/list-entries-v1-credit-grants.mjs.map +1 -1
- package/tools/v1/credit-grants/list-v1-credit-grants.js +1 -1
- package/tools/v1/credit-grants/list-v1-credit-grants.js.map +1 -1
- package/tools/v1/credit-grants/list-v1-credit-grants.mjs +1 -1
- package/tools/v1/credit-grants/list-v1-credit-grants.mjs.map +1 -1
- package/tools/v1/credit-grants/void-v1-credit-grants.js +1 -1
- package/tools/v1/credit-grants/void-v1-credit-grants.js.map +1 -1
- package/tools/v1/credit-grants/void-v1-credit-grants.mjs +1 -1
- package/tools/v1/credit-grants/void-v1-credit-grants.mjs.map +1 -1
- package/tools/v1/custom-fields/add-key-v1-custom-fields.js +1 -1
- package/tools/v1/custom-fields/add-key-v1-custom-fields.js.map +1 -1
- package/tools/v1/custom-fields/add-key-v1-custom-fields.mjs +1 -1
- package/tools/v1/custom-fields/add-key-v1-custom-fields.mjs.map +1 -1
- package/tools/v1/custom-fields/delete-values-v1-custom-fields.d.mts.map +1 -1
- package/tools/v1/custom-fields/delete-values-v1-custom-fields.d.ts.map +1 -1
- package/tools/v1/custom-fields/delete-values-v1-custom-fields.js +1 -1
- package/tools/v1/custom-fields/delete-values-v1-custom-fields.js.map +1 -1
- package/tools/v1/custom-fields/delete-values-v1-custom-fields.mjs +1 -1
- package/tools/v1/custom-fields/delete-values-v1-custom-fields.mjs.map +1 -1
- package/tools/v1/custom-fields/list-keys-v1-custom-fields.d.mts.map +1 -1
- package/tools/v1/custom-fields/list-keys-v1-custom-fields.d.ts.map +1 -1
- package/tools/v1/custom-fields/list-keys-v1-custom-fields.js +3 -2
- package/tools/v1/custom-fields/list-keys-v1-custom-fields.js.map +1 -1
- package/tools/v1/custom-fields/list-keys-v1-custom-fields.mjs +3 -2
- package/tools/v1/custom-fields/list-keys-v1-custom-fields.mjs.map +1 -1
- package/tools/v1/custom-fields/remove-key-v1-custom-fields.d.mts.map +1 -1
- package/tools/v1/custom-fields/remove-key-v1-custom-fields.d.ts.map +1 -1
- package/tools/v1/custom-fields/remove-key-v1-custom-fields.js +1 -1
- package/tools/v1/custom-fields/remove-key-v1-custom-fields.js.map +1 -1
- package/tools/v1/custom-fields/remove-key-v1-custom-fields.mjs +1 -1
- package/tools/v1/custom-fields/remove-key-v1-custom-fields.mjs.map +1 -1
- package/tools/v1/custom-fields/set-values-v1-custom-fields.d.mts.map +1 -1
- package/tools/v1/custom-fields/set-values-v1-custom-fields.d.ts.map +1 -1
- package/tools/v1/custom-fields/set-values-v1-custom-fields.js +2 -1
- package/tools/v1/custom-fields/set-values-v1-custom-fields.js.map +1 -1
- package/tools/v1/custom-fields/set-values-v1-custom-fields.mjs +2 -1
- package/tools/v1/custom-fields/set-values-v1-custom-fields.mjs.map +1 -1
- package/tools/v1/customers/alerts/list-customers-v1-alerts.d.mts.map +1 -1
- package/tools/v1/customers/alerts/list-customers-v1-alerts.d.ts.map +1 -1
- package/tools/v1/customers/alerts/list-customers-v1-alerts.js +4 -3
- package/tools/v1/customers/alerts/list-customers-v1-alerts.js.map +1 -1
- package/tools/v1/customers/alerts/list-customers-v1-alerts.mjs +4 -3
- package/tools/v1/customers/alerts/list-customers-v1-alerts.mjs.map +1 -1
- package/tools/v1/customers/alerts/reset-customers-v1-alerts.d.mts.map +1 -1
- package/tools/v1/customers/alerts/reset-customers-v1-alerts.d.ts.map +1 -1
- package/tools/v1/customers/alerts/reset-customers-v1-alerts.js +2 -2
- package/tools/v1/customers/alerts/reset-customers-v1-alerts.js.map +1 -1
- package/tools/v1/customers/alerts/reset-customers-v1-alerts.mjs +2 -2
- package/tools/v1/customers/alerts/reset-customers-v1-alerts.mjs.map +1 -1
- package/tools/v1/customers/alerts/retrieve-customers-v1-alerts.d.mts.map +1 -1
- package/tools/v1/customers/alerts/retrieve-customers-v1-alerts.d.ts.map +1 -1
- package/tools/v1/customers/alerts/retrieve-customers-v1-alerts.js +22 -11
- package/tools/v1/customers/alerts/retrieve-customers-v1-alerts.js.map +1 -1
- package/tools/v1/customers/alerts/retrieve-customers-v1-alerts.mjs +22 -11
- package/tools/v1/customers/alerts/retrieve-customers-v1-alerts.mjs.map +1 -1
- package/tools/v1/customers/archive-v1-customers.js +1 -1
- package/tools/v1/customers/archive-v1-customers.js.map +1 -1
- package/tools/v1/customers/archive-v1-customers.mjs +1 -1
- package/tools/v1/customers/archive-v1-customers.mjs.map +1 -1
- package/tools/v1/customers/billing-config/create-customers-v1-billing-config.d.mts.map +1 -1
- package/tools/v1/customers/billing-config/create-customers-v1-billing-config.d.ts.map +1 -1
- package/tools/v1/customers/billing-config/create-customers-v1-billing-config.js +6 -1
- package/tools/v1/customers/billing-config/create-customers-v1-billing-config.js.map +1 -1
- package/tools/v1/customers/billing-config/create-customers-v1-billing-config.mjs +6 -1
- package/tools/v1/customers/billing-config/create-customers-v1-billing-config.mjs.map +1 -1
- package/tools/v1/customers/billing-config/retrieve-customers-v1-billing-config.js +1 -1
- package/tools/v1/customers/billing-config/retrieve-customers-v1-billing-config.js.map +1 -1
- package/tools/v1/customers/billing-config/retrieve-customers-v1-billing-config.mjs +1 -1
- package/tools/v1/customers/billing-config/retrieve-customers-v1-billing-config.mjs.map +1 -1
- package/tools/v1/customers/commits/create-customers-v1-commits.d.mts.map +1 -1
- package/tools/v1/customers/commits/create-customers-v1-commits.d.ts.map +1 -1
- package/tools/v1/customers/commits/create-customers-v1-commits.js +31 -31
- package/tools/v1/customers/commits/create-customers-v1-commits.js.map +1 -1
- package/tools/v1/customers/commits/create-customers-v1-commits.mjs +31 -31
- package/tools/v1/customers/commits/create-customers-v1-commits.mjs.map +1 -1
- package/tools/v1/customers/commits/list-customers-v1-commits.d.mts.map +1 -1
- package/tools/v1/customers/commits/list-customers-v1-commits.d.ts.map +1 -1
- package/tools/v1/customers/commits/list-customers-v1-commits.js +3 -2
- package/tools/v1/customers/commits/list-customers-v1-commits.js.map +1 -1
- package/tools/v1/customers/commits/list-customers-v1-commits.mjs +3 -2
- package/tools/v1/customers/commits/list-customers-v1-commits.mjs.map +1 -1
- package/tools/v1/customers/commits/update-end-date-customers-v1-commits.js +1 -1
- package/tools/v1/customers/commits/update-end-date-customers-v1-commits.js.map +1 -1
- package/tools/v1/customers/commits/update-end-date-customers-v1-commits.mjs +1 -1
- package/tools/v1/customers/commits/update-end-date-customers-v1-commits.mjs.map +1 -1
- package/tools/v1/customers/create-v1-customers.d.mts.map +1 -1
- package/tools/v1/customers/create-v1-customers.d.ts.map +1 -1
- package/tools/v1/customers/create-v1-customers.js +13 -2
- package/tools/v1/customers/create-v1-customers.js.map +1 -1
- package/tools/v1/customers/create-v1-customers.mjs +13 -2
- package/tools/v1/customers/create-v1-customers.mjs.map +1 -1
- package/tools/v1/customers/credits/create-customers-v1-credits.d.mts.map +1 -1
- package/tools/v1/customers/credits/create-customers-v1-credits.d.ts.map +1 -1
- package/tools/v1/customers/credits/create-customers-v1-credits.js +29 -23
- package/tools/v1/customers/credits/create-customers-v1-credits.js.map +1 -1
- package/tools/v1/customers/credits/create-customers-v1-credits.mjs +29 -23
- package/tools/v1/customers/credits/create-customers-v1-credits.mjs.map +1 -1
- package/tools/v1/customers/credits/list-customers-v1-credits.d.mts.map +1 -1
- package/tools/v1/customers/credits/list-customers-v1-credits.d.ts.map +1 -1
- package/tools/v1/customers/credits/list-customers-v1-credits.js +3 -2
- package/tools/v1/customers/credits/list-customers-v1-credits.js.map +1 -1
- package/tools/v1/customers/credits/list-customers-v1-credits.mjs +3 -2
- package/tools/v1/customers/credits/list-customers-v1-credits.mjs.map +1 -1
- package/tools/v1/customers/credits/update-end-date-customers-v1-credits.js +1 -1
- package/tools/v1/customers/credits/update-end-date-customers-v1-credits.js.map +1 -1
- package/tools/v1/customers/credits/update-end-date-customers-v1-credits.mjs +1 -1
- package/tools/v1/customers/credits/update-end-date-customers-v1-credits.mjs.map +1 -1
- package/tools/v1/customers/invoices/add-charge-customers-v1-invoices.js +1 -1
- package/tools/v1/customers/invoices/add-charge-customers-v1-invoices.js.map +1 -1
- package/tools/v1/customers/invoices/add-charge-customers-v1-invoices.mjs +1 -1
- package/tools/v1/customers/invoices/add-charge-customers-v1-invoices.mjs.map +1 -1
- package/tools/v1/customers/invoices/list-breakdowns-customers-v1-invoices.js +1 -1
- package/tools/v1/customers/invoices/list-breakdowns-customers-v1-invoices.js.map +1 -1
- package/tools/v1/customers/invoices/list-breakdowns-customers-v1-invoices.mjs +1 -1
- package/tools/v1/customers/invoices/list-breakdowns-customers-v1-invoices.mjs.map +1 -1
- package/tools/v1/customers/invoices/list-customers-v1-invoices.js +1 -1
- package/tools/v1/customers/invoices/list-customers-v1-invoices.js.map +1 -1
- package/tools/v1/customers/invoices/list-customers-v1-invoices.mjs +1 -1
- package/tools/v1/customers/invoices/list-customers-v1-invoices.mjs.map +1 -1
- package/tools/v1/customers/invoices/retrieve-customers-v1-invoices.d.mts.map +1 -1
- package/tools/v1/customers/invoices/retrieve-customers-v1-invoices.d.ts.map +1 -1
- package/tools/v1/customers/invoices/retrieve-customers-v1-invoices.js +1 -1
- package/tools/v1/customers/invoices/retrieve-customers-v1-invoices.js.map +1 -1
- package/tools/v1/customers/invoices/retrieve-customers-v1-invoices.mjs +1 -1
- package/tools/v1/customers/invoices/retrieve-customers-v1-invoices.mjs.map +1 -1
- package/tools/v1/customers/invoices/retrieve-pdf-customers-v1-invoices.d.mts +45 -0
- package/tools/v1/customers/invoices/retrieve-pdf-customers-v1-invoices.d.mts.map +1 -0
- package/tools/v1/customers/invoices/retrieve-pdf-customers-v1-invoices.d.ts +45 -0
- package/tools/v1/customers/invoices/retrieve-pdf-customers-v1-invoices.d.ts.map +1 -0
- package/tools/v1/customers/invoices/retrieve-pdf-customers-v1-invoices.js +39 -0
- package/tools/v1/customers/invoices/retrieve-pdf-customers-v1-invoices.js.map +1 -0
- package/tools/v1/customers/invoices/retrieve-pdf-customers-v1-invoices.mjs +35 -0
- package/tools/v1/customers/invoices/retrieve-pdf-customers-v1-invoices.mjs.map +1 -0
- package/tools/v1/customers/list-billable-metrics-v1-customers.js +1 -1
- package/tools/v1/customers/list-billable-metrics-v1-customers.js.map +1 -1
- package/tools/v1/customers/list-billable-metrics-v1-customers.mjs +1 -1
- package/tools/v1/customers/list-billable-metrics-v1-customers.mjs.map +1 -1
- package/tools/v1/customers/list-costs-v1-customers.js +1 -1
- package/tools/v1/customers/list-costs-v1-customers.js.map +1 -1
- package/tools/v1/customers/list-costs-v1-customers.mjs +1 -1
- package/tools/v1/customers/list-costs-v1-customers.mjs.map +1 -1
- package/tools/v1/customers/list-v1-customers.js +1 -1
- package/tools/v1/customers/list-v1-customers.js.map +1 -1
- package/tools/v1/customers/list-v1-customers.mjs +1 -1
- package/tools/v1/customers/list-v1-customers.mjs.map +1 -1
- package/tools/v1/customers/named-schedules/retrieve-customers-v1-named-schedules.js +1 -1
- package/tools/v1/customers/named-schedules/retrieve-customers-v1-named-schedules.js.map +1 -1
- package/tools/v1/customers/named-schedules/retrieve-customers-v1-named-schedules.mjs +1 -1
- package/tools/v1/customers/named-schedules/retrieve-customers-v1-named-schedules.mjs.map +1 -1
- package/tools/v1/customers/plans/add-customers-v1-plans.js +1 -1
- package/tools/v1/customers/plans/add-customers-v1-plans.js.map +1 -1
- package/tools/v1/customers/plans/add-customers-v1-plans.mjs +1 -1
- package/tools/v1/customers/plans/add-customers-v1-plans.mjs.map +1 -1
- package/tools/v1/customers/plans/end-customers-v1-plans.js +1 -1
- package/tools/v1/customers/plans/end-customers-v1-plans.js.map +1 -1
- package/tools/v1/customers/plans/end-customers-v1-plans.mjs +1 -1
- package/tools/v1/customers/plans/end-customers-v1-plans.mjs.map +1 -1
- package/tools/v1/customers/plans/list-customers-v1-plans.js +1 -1
- package/tools/v1/customers/plans/list-customers-v1-plans.js.map +1 -1
- package/tools/v1/customers/plans/list-customers-v1-plans.mjs +1 -1
- package/tools/v1/customers/plans/list-customers-v1-plans.mjs.map +1 -1
- package/tools/v1/customers/plans/list-price-adjustments-customers-v1-plans.js +1 -1
- package/tools/v1/customers/plans/list-price-adjustments-customers-v1-plans.js.map +1 -1
- package/tools/v1/customers/plans/list-price-adjustments-customers-v1-plans.mjs +1 -1
- package/tools/v1/customers/plans/list-price-adjustments-customers-v1-plans.mjs.map +1 -1
- package/tools/v1/customers/preview-events-v1-customers.d.mts.map +1 -1
- package/tools/v1/customers/preview-events-v1-customers.d.ts.map +1 -1
- package/tools/v1/customers/preview-events-v1-customers.js +2 -6
- package/tools/v1/customers/preview-events-v1-customers.js.map +1 -1
- package/tools/v1/customers/preview-events-v1-customers.mjs +2 -6
- package/tools/v1/customers/preview-events-v1-customers.mjs.map +1 -1
- package/tools/v1/customers/retrieve-billing-configurations-v1-customers.d.mts +45 -0
- package/tools/v1/customers/retrieve-billing-configurations-v1-customers.d.mts.map +1 -0
- package/tools/v1/customers/retrieve-billing-configurations-v1-customers.d.ts +45 -0
- package/tools/v1/customers/retrieve-billing-configurations-v1-customers.d.ts.map +1 -0
- package/tools/v1/customers/retrieve-billing-configurations-v1-customers.js +43 -0
- package/tools/v1/customers/retrieve-billing-configurations-v1-customers.js.map +1 -0
- package/tools/v1/customers/retrieve-billing-configurations-v1-customers.mjs +39 -0
- package/tools/v1/customers/retrieve-billing-configurations-v1-customers.mjs.map +1 -0
- package/tools/v1/customers/retrieve-v1-customers.js +1 -1
- package/tools/v1/customers/retrieve-v1-customers.js.map +1 -1
- package/tools/v1/customers/retrieve-v1-customers.mjs +1 -1
- package/tools/v1/customers/retrieve-v1-customers.mjs.map +1 -1
- package/tools/v1/customers/set-billing-configurations-v1-customers.d.mts +45 -0
- package/tools/v1/customers/set-billing-configurations-v1-customers.d.mts.map +1 -0
- package/tools/v1/customers/set-billing-configurations-v1-customers.d.ts +45 -0
- package/tools/v1/customers/set-billing-configurations-v1-customers.d.ts.map +1 -0
- package/tools/v1/customers/set-billing-configurations-v1-customers.js +77 -0
- package/tools/v1/customers/set-billing-configurations-v1-customers.js.map +1 -0
- package/tools/v1/customers/set-billing-configurations-v1-customers.mjs +73 -0
- package/tools/v1/customers/set-billing-configurations-v1-customers.mjs.map +1 -0
- package/tools/v1/customers/set-ingest-aliases-v1-customers.js +1 -1
- package/tools/v1/customers/set-ingest-aliases-v1-customers.js.map +1 -1
- package/tools/v1/customers/set-ingest-aliases-v1-customers.mjs +1 -1
- package/tools/v1/customers/set-ingest-aliases-v1-customers.mjs.map +1 -1
- package/tools/v1/customers/set-name-v1-customers.js +1 -1
- package/tools/v1/customers/set-name-v1-customers.js.map +1 -1
- package/tools/v1/customers/set-name-v1-customers.mjs +1 -1
- package/tools/v1/customers/set-name-v1-customers.mjs.map +1 -1
- package/tools/v1/customers/update-config-v1-customers.d.mts.map +1 -1
- package/tools/v1/customers/update-config-v1-customers.d.ts.map +1 -1
- package/tools/v1/customers/update-config-v1-customers.js +1 -1
- package/tools/v1/customers/update-config-v1-customers.js.map +1 -1
- package/tools/v1/customers/update-config-v1-customers.mjs +1 -1
- package/tools/v1/customers/update-config-v1-customers.mjs.map +1 -1
- package/tools/v1/dashboards/get-embeddable-url-v1-dashboards.js +1 -1
- package/tools/v1/dashboards/get-embeddable-url-v1-dashboards.js.map +1 -1
- package/tools/v1/dashboards/get-embeddable-url-v1-dashboards.mjs +1 -1
- package/tools/v1/dashboards/get-embeddable-url-v1-dashboards.mjs.map +1 -1
- package/tools/v1/invoices/regenerate-v1-invoices.js +1 -1
- package/tools/v1/invoices/regenerate-v1-invoices.js.map +1 -1
- package/tools/v1/invoices/regenerate-v1-invoices.mjs +1 -1
- package/tools/v1/invoices/regenerate-v1-invoices.mjs.map +1 -1
- package/tools/v1/invoices/void-v1-invoices.js +1 -1
- package/tools/v1/invoices/void-v1-invoices.js.map +1 -1
- package/tools/v1/invoices/void-v1-invoices.mjs +1 -1
- package/tools/v1/invoices/void-v1-invoices.mjs.map +1 -1
- package/tools/v1/payments/attempt-v1-payments.d.mts +45 -0
- package/tools/v1/payments/attempt-v1-payments.d.mts.map +1 -0
- package/tools/v1/payments/attempt-v1-payments.d.ts +45 -0
- package/tools/v1/payments/attempt-v1-payments.d.ts.map +1 -0
- package/tools/v1/payments/attempt-v1-payments.js +43 -0
- package/tools/v1/payments/attempt-v1-payments.js.map +1 -0
- package/tools/v1/payments/attempt-v1-payments.mjs +39 -0
- package/tools/v1/payments/attempt-v1-payments.mjs.map +1 -0
- package/tools/v1/payments/cancel-v1-payments.d.mts +45 -0
- package/tools/v1/payments/cancel-v1-payments.d.mts.map +1 -0
- package/tools/v1/payments/cancel-v1-payments.d.ts +45 -0
- package/tools/v1/payments/cancel-v1-payments.d.ts.map +1 -0
- package/tools/v1/payments/cancel-v1-payments.js +43 -0
- package/tools/v1/payments/cancel-v1-payments.js.map +1 -0
- package/tools/v1/payments/cancel-v1-payments.mjs +39 -0
- package/tools/v1/payments/cancel-v1-payments.mjs.map +1 -0
- package/tools/v1/payments/list-v1-payments.d.mts +45 -0
- package/tools/v1/payments/list-v1-payments.d.mts.map +1 -0
- package/tools/v1/payments/list-v1-payments.d.ts +45 -0
- package/tools/v1/payments/list-v1-payments.d.ts.map +1 -0
- package/tools/v1/payments/list-v1-payments.js +64 -0
- package/tools/v1/payments/list-v1-payments.js.map +1 -0
- package/tools/v1/payments/list-v1-payments.mjs +60 -0
- package/tools/v1/payments/list-v1-payments.mjs.map +1 -0
- package/tools/v1/plans/get-details-v1-plans.js +1 -1
- package/tools/v1/plans/get-details-v1-plans.js.map +1 -1
- package/tools/v1/plans/get-details-v1-plans.mjs +1 -1
- package/tools/v1/plans/get-details-v1-plans.mjs.map +1 -1
- package/tools/v1/plans/list-charges-v1-plans.js +1 -1
- package/tools/v1/plans/list-charges-v1-plans.js.map +1 -1
- package/tools/v1/plans/list-charges-v1-plans.mjs +1 -1
- package/tools/v1/plans/list-charges-v1-plans.mjs.map +1 -1
- package/tools/v1/plans/list-customers-v1-plans.js +1 -1
- package/tools/v1/plans/list-customers-v1-plans.js.map +1 -1
- package/tools/v1/plans/list-customers-v1-plans.mjs +1 -1
- package/tools/v1/plans/list-customers-v1-plans.mjs.map +1 -1
- package/tools/v1/plans/list-v1-plans.js +1 -1
- package/tools/v1/plans/list-v1-plans.js.map +1 -1
- package/tools/v1/plans/list-v1-plans.mjs +1 -1
- package/tools/v1/plans/list-v1-plans.mjs.map +1 -1
- package/tools/v1/pricing-units/list-v1-pricing-units.js +1 -1
- package/tools/v1/pricing-units/list-v1-pricing-units.js.map +1 -1
- package/tools/v1/pricing-units/list-v1-pricing-units.mjs +1 -1
- package/tools/v1/pricing-units/list-v1-pricing-units.mjs.map +1 -1
- package/tools/v1/services/list-v1-services.js +1 -1
- package/tools/v1/services/list-v1-services.js.map +1 -1
- package/tools/v1/services/list-v1-services.mjs +1 -1
- package/tools/v1/services/list-v1-services.mjs.map +1 -1
- package/tools/v1/usage/ingest-v1-usage.js +2 -2
- package/tools/v1/usage/ingest-v1-usage.js.map +1 -1
- package/tools/v1/usage/ingest-v1-usage.mjs +2 -2
- package/tools/v1/usage/ingest-v1-usage.mjs.map +1 -1
- package/tools/v1/usage/list-v1-usage.d.mts.map +1 -1
- package/tools/v1/usage/list-v1-usage.d.ts.map +1 -1
- package/tools/v1/usage/list-v1-usage.js +3 -2
- package/tools/v1/usage/list-v1-usage.js.map +1 -1
- package/tools/v1/usage/list-v1-usage.mjs +3 -2
- package/tools/v1/usage/list-v1-usage.mjs.map +1 -1
- package/tools/v1/usage/list-with-groups-v1-usage.js +1 -1
- package/tools/v1/usage/list-with-groups-v1-usage.js.map +1 -1
- package/tools/v1/usage/list-with-groups-v1-usage.mjs +1 -1
- package/tools/v1/usage/list-with-groups-v1-usage.mjs.map +1 -1
- package/tools/v1/usage/search-v1-usage.js +1 -1
- package/tools/v1/usage/search-v1-usage.js.map +1 -1
- package/tools/v1/usage/search-v1-usage.mjs +1 -1
- package/tools/v1/usage/search-v1-usage.mjs.map +1 -1
- package/tools/v2/contracts/edit-commit-v2-contracts.d.mts.map +1 -1
- package/tools/v2/contracts/edit-commit-v2-contracts.d.ts.map +1 -1
- package/tools/v2/contracts/edit-commit-v2-contracts.js +82 -23
- package/tools/v2/contracts/edit-commit-v2-contracts.js.map +1 -1
- package/tools/v2/contracts/edit-commit-v2-contracts.mjs +82 -23
- package/tools/v2/contracts/edit-commit-v2-contracts.mjs.map +1 -1
- package/tools/v2/contracts/edit-credit-v2-contracts.d.mts.map +1 -1
- package/tools/v2/contracts/edit-credit-v2-contracts.d.ts.map +1 -1
- package/tools/v2/contracts/edit-credit-v2-contracts.js +82 -23
- package/tools/v2/contracts/edit-credit-v2-contracts.js.map +1 -1
- package/tools/v2/contracts/edit-credit-v2-contracts.mjs +82 -23
- package/tools/v2/contracts/edit-credit-v2-contracts.mjs.map +1 -1
- package/tools/v2/contracts/edit-v2-contracts.d.mts.map +1 -1
- package/tools/v2/contracts/edit-v2-contracts.d.ts.map +1 -1
- package/tools/v2/contracts/edit-v2-contracts.js +303 -741
- package/tools/v2/contracts/edit-v2-contracts.js.map +1 -1
- package/tools/v2/contracts/edit-v2-contracts.mjs +303 -741
- package/tools/v2/contracts/edit-v2-contracts.mjs.map +1 -1
- package/tools/v2/contracts/get-edit-history-v2-contracts.js +1 -1
- package/tools/v2/contracts/get-edit-history-v2-contracts.js.map +1 -1
- package/tools/v2/contracts/get-edit-history-v2-contracts.mjs +1 -1
- package/tools/v2/contracts/get-edit-history-v2-contracts.mjs.map +1 -1
- package/tools/v2/contracts/list-v2-contracts.js +1 -1
- package/tools/v2/contracts/list-v2-contracts.js.map +1 -1
- package/tools/v2/contracts/list-v2-contracts.mjs +1 -1
- package/tools/v2/contracts/list-v2-contracts.mjs.map +1 -1
- package/tools/v2/contracts/retrieve-v2-contracts.d.mts.map +1 -1
- package/tools/v2/contracts/retrieve-v2-contracts.d.ts.map +1 -1
- package/tools/v2/contracts/retrieve-v2-contracts.js +1 -1
- package/tools/v2/contracts/retrieve-v2-contracts.js.map +1 -1
- package/tools/v2/contracts/retrieve-v2-contracts.mjs +1 -1
- package/tools/v2/contracts/retrieve-v2-contracts.mjs.map +1 -1
|
@@ -0,0 +1,6 @@
|
|
|
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.workerPath = void 0;
|
|
5
|
+
exports.workerPath = require.resolve('./code-tool-worker.mjs');
|
|
6
|
+
//# sourceMappingURL=code-tool-paths.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool-paths.cjs","sourceRoot":"","sources":["src/code-tool-paths.cts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEzE,QAAA,UAAU,GAAG,OAAO,CAAC,OAAO,CAAC,wBAAwB,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool-paths.d.cts","sourceRoot":"","sources":["src/code-tool-paths.cts"],"names":[],"mappings":"AAEA,eAAO,MAAM,UAAU,QAA4C,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ClientOptions } from '@metronome/sdk';
|
|
2
|
+
export type WorkerInput = {
|
|
3
|
+
opts: ClientOptions;
|
|
4
|
+
code: string;
|
|
5
|
+
};
|
|
6
|
+
export type WorkerSuccess = {
|
|
7
|
+
result: unknown | null;
|
|
8
|
+
logLines: string[];
|
|
9
|
+
errLines: string[];
|
|
10
|
+
};
|
|
11
|
+
export type WorkerError = {
|
|
12
|
+
message: string | undefined;
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=code-tool-types.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool-types.d.mts","sourceRoot":"","sources":["src/code-tool-types.ts"],"names":[],"mappings":"OAEO,EAAE,aAAa,EAAE,MAAM,gBAAgB;AAE9C,MAAM,MAAM,WAAW,GAAG;IACxB,IAAI,EAAE,aAAa,CAAC;IACpB,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AACF,MAAM,MAAM,aAAa,GAAG;IAC1B,MAAM,EAAE,OAAO,GAAG,IAAI,CAAC;IACvB,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,QAAQ,EAAE,MAAM,EAAE,CAAC;CACpB,CAAC;AACF,MAAM,MAAM,WAAW,GAAG;IAAE,OAAO,EAAE,MAAM,GAAG,SAAS,CAAA;CAAE,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ClientOptions } from '@metronome/sdk';
|
|
2
|
+
export type WorkerInput = {
|
|
3
|
+
opts: ClientOptions;
|
|
4
|
+
code: string;
|
|
5
|
+
};
|
|
6
|
+
export type WorkerSuccess = {
|
|
7
|
+
result: unknown | null;
|
|
8
|
+
logLines: string[];
|
|
9
|
+
errLines: string[];
|
|
10
|
+
};
|
|
11
|
+
export type WorkerError = {
|
|
12
|
+
message: string | undefined;
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=code-tool-types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool-types.d.ts","sourceRoot":"","sources":["src/code-tool-types.ts"],"names":[],"mappings":"OAEO,EAAE,aAAa,EAAE,MAAM,gBAAgB;AAE9C,MAAM,MAAM,WAAW,GAAG;IACxB,IAAI,EAAE,aAAa,CAAC;IACpB,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AACF,MAAM,MAAM,aAAa,GAAG;IAC1B,MAAM,EAAE,OAAO,GAAG,IAAI,CAAC;IACvB,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,QAAQ,EAAE,MAAM,EAAE,CAAC;CACpB,CAAC;AACF,MAAM,MAAM,WAAW,GAAG;IAAE,OAAO,EAAE,MAAM,GAAG,SAAS,CAAA;CAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool-types.js","sourceRoot":"","sources":["src/code-tool-types.ts"],"names":[],"mappings":";AAAA,sFAAsF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool-types.mjs","sourceRoot":"","sources":["src/code-tool-types.ts"],"names":[],"mappings":"AAAA,sFAAsF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool-worker.d.mts","sourceRoot":"","sources":["src/code-tool-worker.ts"],"names":[],"mappings":";iBAM0B,OAAO,KAAG,OAAO,CAAC,QAAQ,CAAC;;AAuCrD,wBAAyB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool-worker.d.ts","sourceRoot":"","sources":["src/code-tool-worker.ts"],"names":[],"mappings":";iBAM0B,OAAO,KAAG,OAAO,CAAC,QAAQ,CAAC;;AAuCrD,wBAAyB"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
const node_util_1 = __importDefault(require("node:util"));
|
|
8
|
+
const sdk_1 = require("@metronome/sdk");
|
|
9
|
+
const fetch = async (req) => {
|
|
10
|
+
const { opts, code } = (await req.json());
|
|
11
|
+
const client = new sdk_1.Metronome({
|
|
12
|
+
...opts,
|
|
13
|
+
});
|
|
14
|
+
const logLines = [];
|
|
15
|
+
const errLines = [];
|
|
16
|
+
const console = {
|
|
17
|
+
log: (...args) => {
|
|
18
|
+
logLines.push(node_util_1.default.format(...args));
|
|
19
|
+
},
|
|
20
|
+
error: (...args) => {
|
|
21
|
+
errLines.push(node_util_1.default.format(...args));
|
|
22
|
+
},
|
|
23
|
+
};
|
|
24
|
+
try {
|
|
25
|
+
let run_ = async (client) => { };
|
|
26
|
+
eval(`
|
|
27
|
+
${code}
|
|
28
|
+
run_ = run;
|
|
29
|
+
`);
|
|
30
|
+
const result = await run_(client);
|
|
31
|
+
return Response.json({
|
|
32
|
+
result,
|
|
33
|
+
logLines,
|
|
34
|
+
errLines,
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
catch (e) {
|
|
38
|
+
const message = e instanceof Error ? e.message : undefined;
|
|
39
|
+
return Response.json({
|
|
40
|
+
message,
|
|
41
|
+
}, { status: 400, statusText: 'Code execution error' });
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
exports.default = {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,CAAC,OAAO,CAAC,CAAC,CAAC,SAAS,CAAC;QAC3D,OAAO,QAAQ,CAAC,IAAI,CAClB;YACE,OAAO;SACc,EACvB,EAAE,MAAM,EAAE,GAAG,EAAE,UAAU,EAAE,sBAAsB,EAAE,CACpD,CAAC;IACJ,CAAC;AACH,CAAC,CAAC;AAEF,kBAAe,EAAE,KAAK,EAAE,CAAC"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import util from 'node:util';
|
|
3
|
+
import { Metronome } from '@metronome/sdk';
|
|
4
|
+
const fetch = async (req) => {
|
|
5
|
+
const { opts, code } = (await req.json());
|
|
6
|
+
const client = new Metronome({
|
|
7
|
+
...opts,
|
|
8
|
+
});
|
|
9
|
+
const logLines = [];
|
|
10
|
+
const errLines = [];
|
|
11
|
+
const console = {
|
|
12
|
+
log: (...args) => {
|
|
13
|
+
logLines.push(util.format(...args));
|
|
14
|
+
},
|
|
15
|
+
error: (...args) => {
|
|
16
|
+
errLines.push(util.format(...args));
|
|
17
|
+
},
|
|
18
|
+
};
|
|
19
|
+
try {
|
|
20
|
+
let run_ = async (client) => { };
|
|
21
|
+
eval(`
|
|
22
|
+
${code}
|
|
23
|
+
run_ = run;
|
|
24
|
+
`);
|
|
25
|
+
const result = await run_(client);
|
|
26
|
+
return Response.json({
|
|
27
|
+
result,
|
|
28
|
+
logLines,
|
|
29
|
+
errLines,
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
catch (e) {
|
|
33
|
+
const message = e instanceof Error ? e.message : undefined;
|
|
34
|
+
return Response.json({
|
|
35
|
+
message,
|
|
36
|
+
}, { status: 400, statusText: 'Code execution error' });
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
export default { fetch };
|
|
40
|
+
//# sourceMappingURL=code-tool-worker.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool-worker.mjs","sour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ACE,OAAO;SACc,EACvB,EAAE,MAAM,EAAE,GAAG,EAAE,UAAU,EAAE,sBAAsB,EAAE,CACpD,CAAC;IACJ,CAAC;AACH,CAAC,CAAC;AAEF,eAAe,EAAE,KAAK,EAAE,CAAC"}
|
package/code-tool.d.mts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Endpoint } from "./tools/types.mjs";
|
|
2
|
+
/**
|
|
3
|
+
* A tool that runs code against a copy of the SDK.
|
|
4
|
+
*
|
|
5
|
+
* Instead of exposing every endpoint as it's 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<Endpoint>;
|
|
12
|
+
//# sourceMappingURL=code-tool.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool.d.mts","sourceRoot":"","sources":["src/code-tool.ts"],"names":[],"mappings":"OAKO,EAAE,QAAQ,EAA0B;AAM3C;;;;;;;;GAQG;AACH,wBAAsB,QAAQ,IAAI,OAAO,CAAC,QAAQ,CAAC,CA8HlD"}
|
package/code-tool.d.ts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Endpoint } 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 it's 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<Endpoint>;
|
|
12
|
+
//# 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":"OAKO,EAAE,QAAQ,EAA0B;AAM3C;;;;;;;;GAQG;AACH,wBAAsB,QAAQ,IAAI,OAAO,CAAC,QAAQ,CAAC,CA8HlD"}
|
package/code-tool.js
ADDED
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37
|
+
exports.codeTool = codeTool;
|
|
38
|
+
const node_path_1 = require("node:path");
|
|
39
|
+
const node_url_1 = require("node:url");
|
|
40
|
+
/**
|
|
41
|
+
* A tool that runs code against a copy of the SDK.
|
|
42
|
+
*
|
|
43
|
+
* Instead of exposing every endpoint as it's own tool, which uses up too many tokens for LLMs to use at once,
|
|
44
|
+
* we expose a single tool that can be used to search for endpoints by name, resource, operation, or tag, and then
|
|
45
|
+
* a generic endpoint that can be used to invoke any endpoint with the provided arguments.
|
|
46
|
+
*
|
|
47
|
+
* @param endpoints - The endpoints to include in the list.
|
|
48
|
+
*/
|
|
49
|
+
async function codeTool() {
|
|
50
|
+
const metadata = { resource: 'all', operation: 'write', tags: [] };
|
|
51
|
+
const tool = {
|
|
52
|
+
name: 'execute',
|
|
53
|
+
description: 'Runs Typescript code to interact with the API.\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 client, and it will be run.\nDo not initialize a client, but instead use the client that you are given as a parameter.\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.',
|
|
54
|
+
inputSchema: { type: 'object', properties: { code: { type: 'string' } } },
|
|
55
|
+
};
|
|
56
|
+
// Import dynamically to avoid failing at import time in cases where the environment is not well-supported.
|
|
57
|
+
const { newDenoHTTPWorker } = await Promise.resolve().then(() => __importStar(require('@valtown/deno-http-worker')));
|
|
58
|
+
const { workerPath } = await Promise.resolve().then(() => __importStar(require('./code-tool-paths.cjs')));
|
|
59
|
+
const handler = async (client, args) => {
|
|
60
|
+
const baseURLHostname = new URL(client.baseURL).hostname;
|
|
61
|
+
const { code } = args;
|
|
62
|
+
const worker = await newDenoHTTPWorker((0, node_url_1.pathToFileURL)(workerPath), {
|
|
63
|
+
runFlags: [
|
|
64
|
+
`--node-modules-dir=manual`,
|
|
65
|
+
`--allow-read=code-tool-worker.mjs,${workerPath.replace(/([\/\\]node_modules)[\/\\].+$/, '$1')}/`,
|
|
66
|
+
`--allow-net=${baseURLHostname}`,
|
|
67
|
+
// Allow environment variables because instantiating the client will try to read from them,
|
|
68
|
+
// even though they are not set.
|
|
69
|
+
'--allow-env',
|
|
70
|
+
],
|
|
71
|
+
printOutput: true,
|
|
72
|
+
spawnOptions: {
|
|
73
|
+
cwd: (0, node_path_1.dirname)(workerPath),
|
|
74
|
+
},
|
|
75
|
+
});
|
|
76
|
+
try {
|
|
77
|
+
const resp = await new Promise((resolve, reject) => {
|
|
78
|
+
worker.addEventListener('exit', (exitCode) => {
|
|
79
|
+
reject(new Error(`Worker exited with code ${exitCode}`));
|
|
80
|
+
});
|
|
81
|
+
const opts = {
|
|
82
|
+
baseURL: client.baseURL,
|
|
83
|
+
bearerToken: client.bearerToken,
|
|
84
|
+
webhookSecret: client.webhookSecret,
|
|
85
|
+
defaultHeaders: {
|
|
86
|
+
'X-Stainless-MCP': 'true',
|
|
87
|
+
},
|
|
88
|
+
};
|
|
89
|
+
const req = worker.request('http://localhost', {
|
|
90
|
+
headers: {
|
|
91
|
+
'content-type': 'application/json',
|
|
92
|
+
},
|
|
93
|
+
method: 'POST',
|
|
94
|
+
}, (resp) => {
|
|
95
|
+
const body = [];
|
|
96
|
+
resp.on('error', (err) => {
|
|
97
|
+
reject(err);
|
|
98
|
+
});
|
|
99
|
+
resp.on('data', (chunk) => {
|
|
100
|
+
body.push(chunk);
|
|
101
|
+
});
|
|
102
|
+
resp.on('end', () => {
|
|
103
|
+
resolve(new Response(Buffer.concat(body).toString(), {
|
|
104
|
+
status: resp.statusCode ?? 200,
|
|
105
|
+
headers: resp.headers,
|
|
106
|
+
}));
|
|
107
|
+
});
|
|
108
|
+
});
|
|
109
|
+
const body = JSON.stringify({
|
|
110
|
+
opts,
|
|
111
|
+
code,
|
|
112
|
+
});
|
|
113
|
+
req.write(body, (err) => {
|
|
114
|
+
if (err !== null && err !== undefined) {
|
|
115
|
+
reject(err);
|
|
116
|
+
}
|
|
117
|
+
});
|
|
118
|
+
req.end();
|
|
119
|
+
});
|
|
120
|
+
if (resp.status === 200) {
|
|
121
|
+
const { result, logLines, errLines } = (await resp.json());
|
|
122
|
+
const returnOutput = result === null ? null
|
|
123
|
+
: result === undefined ? null
|
|
124
|
+
: {
|
|
125
|
+
type: 'text',
|
|
126
|
+
text: typeof result === 'string' ? result : JSON.stringify(result),
|
|
127
|
+
};
|
|
128
|
+
const logOutput = logLines.length === 0 ?
|
|
129
|
+
null
|
|
130
|
+
: {
|
|
131
|
+
type: 'text',
|
|
132
|
+
text: logLines.join('\n'),
|
|
133
|
+
};
|
|
134
|
+
const errOutput = errLines.length === 0 ?
|
|
135
|
+
null
|
|
136
|
+
: {
|
|
137
|
+
type: 'text',
|
|
138
|
+
text: 'Error output:\n' + errLines.join('\n'),
|
|
139
|
+
};
|
|
140
|
+
return {
|
|
141
|
+
content: [returnOutput, logOutput, errOutput].filter((block) => block !== null),
|
|
142
|
+
};
|
|
143
|
+
}
|
|
144
|
+
else {
|
|
145
|
+
const { message } = (await resp.json());
|
|
146
|
+
throw new Error(message);
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
catch (e) {
|
|
150
|
+
throw e;
|
|
151
|
+
}
|
|
152
|
+
finally {
|
|
153
|
+
worker.terminate();
|
|
154
|
+
}
|
|
155
|
+
};
|
|
156
|
+
return { metadata, tool, handler };
|
|
157
|
+
}
|
|
158
|
+
//# sourceMappingURL=code-tool.js.map
|
package/code-tool.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-tool.js","sourceRoot":"","sources":["src/code-tool.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAoBtF,4BA8HC;AAhJD,yCAAoC;AACpC,uCAAyC;AAQzC;;;;;;;;GAQG;AACI,KAAK,UAAU,QAAQ;IAC5B,MAAM,QAAQ,GAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,SAAS,EAAE,OAAO,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC;IAC7E,MAAM,IAAI,GAAS;QACjB,IAAI,EAAE,SAAS;QACf,WAAW,EACT,khCAAkhC;QACphC,WAAW,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,UAAU,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE;KAC1E,CAAC;IAEF,2GAA2G;IAC3G,MAAM,EAAE,iBAAiB,EAAE,GAAG,wDAAa,2BAA2B,GAAC,CAAC;IACxE,MAAM,EAAE,UAAU,EAAE,GAAG,wDAAa,uBAAuB,GAAC,CAAC;IAE7D,MAAM,OAAO,GAAG,KAAK,EAAE,MAAiB,EAAE,IAAa,EAAE,EAAE;QACzD,MAAM,eAAe,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,QAAQ,CAAC;QACzD,MAAM,EAAE,IAAI,EAAE,GAAG,IAAwB,CAAC;QAE1C,MAAM,MAAM,GAAG,MAAM,iBAAiB,CAAC,IAAA,wBAAa,EAAC,UAAU,CAAC,EAAE;YAChE,QAAQ,EAAE;gBACR,2BAA2B;gBAC3B,qCAAqC,UAAU,CAAC,OAAO,CAAC,+BAA+B,EAAE,IAAI,CAAC,GAAG;gBACjG,eAAe,eAAe,EAAE;gBAChC,2FAA2F;gBAC3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;gBACN,MAAM,SAAS,GACb,QAAQ,CAAC,MAAM,KAAK,CAAC,CAAC,CAAC;oBACrB,IAAI;oBACN,CAAC,CAAC;wBACE,IAAI,EAAE,MAAM;wBACZ,IAAI,EAAE,iBAAiB,GAAG,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC;qBAC9C,CAAC;gBACN,OAAO;oBACL,OAAO,EAAE,CAAC,YAAY,EAAE,SAAS,EAAE,SAAS,CAAC,CAAC,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,KAAK,IAAI,CAAC;iBAChF,CAAC;YACJ,CAAC;iBAAM,CAAC;gBACN,MAAM,EAAE,OAAO,EAAE,GAAG,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,CAAgB,CAAC;gBACvD,MAAM,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC;YAC3B,CAAC;QACH,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,MAAM,CAAC,CAAC;QACV,CAAC;gBAAS,CAAC;YACT,MAAM,CAAC,SAAS,EAAE,CAAC;QACrB,CAAC;IACH,CAAC,CAAC;IAEF,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;AACrC,CAAC"}
|
package/code-tool.mjs
ADDED
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { dirname } from 'node:path';
|
|
3
|
+
import { pathToFileURL } from 'node:url';
|
|
4
|
+
/**
|
|
5
|
+
* A tool that runs code against a copy of the SDK.
|
|
6
|
+
*
|
|
7
|
+
* Instead of exposing every endpoint as it's 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 Typescript code to interact with the API.\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 client, and it will be run.\nDo not initialize a client, but instead use the client that you are given as a parameter.\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
|
+
// Import dynamically to avoid failing at import time in cases where the environment is not well-supported.
|
|
21
|
+
const { newDenoHTTPWorker } = await import('@valtown/deno-http-worker');
|
|
22
|
+
const { workerPath } = await import('./code-tool-paths.cjs');
|
|
23
|
+
const handler = async (client, args) => {
|
|
24
|
+
const baseURLHostname = new URL(client.baseURL).hostname;
|
|
25
|
+
const { code } = args;
|
|
26
|
+
const worker = await newDenoHTTPWorker(pathToFileURL(workerPath), {
|
|
27
|
+
runFlags: [
|
|
28
|
+
`--node-modules-dir=manual`,
|
|
29
|
+
`--allow-read=code-tool-worker.mjs,${workerPath.replace(/([\/\\]node_modules)[\/\\].+$/, '$1')}/`,
|
|
30
|
+
`--allow-net=${baseURLHostname}`,
|
|
31
|
+
// Allow environment variables because instantiating the client will try to read from them,
|
|
32
|
+
// even though they are not set.
|
|
33
|
+
'--allow-env',
|
|
34
|
+
],
|
|
35
|
+
printOutput: true,
|
|
36
|
+
spawnOptions: {
|
|
37
|
+
cwd: dirname(workerPath),
|
|
38
|
+
},
|
|
39
|
+
});
|
|
40
|
+
try {
|
|
41
|
+
const resp = await new Promise((resolve, reject) => {
|
|
42
|
+
worker.addEventListener('exit', (exitCode) => {
|
|
43
|
+
reject(new Error(`Worker exited with code ${exitCode}`));
|
|
44
|
+
});
|
|
45
|
+
const opts = {
|
|
46
|
+
baseURL: client.baseURL,
|
|
47
|
+
bearerToken: client.bearerToken,
|
|
48
|
+
webhookSecret: client.webhookSecret,
|
|
49
|
+
defaultHeaders: {
|
|
50
|
+
'X-Stainless-MCP': 'true',
|
|
51
|
+
},
|
|
52
|
+
};
|
|
53
|
+
const req = worker.request('http://localhost', {
|
|
54
|
+
headers: {
|
|
55
|
+
'content-type': 'application/json',
|
|
56
|
+
},
|
|
57
|
+
method: 'POST',
|
|
58
|
+
}, (resp) => {
|
|
59
|
+
const body = [];
|
|
60
|
+
resp.on('error', (err) => {
|
|
61
|
+
reject(err);
|
|
62
|
+
});
|
|
63
|
+
resp.on('data', (chunk) => {
|
|
64
|
+
body.push(chunk);
|
|
65
|
+
});
|
|
66
|
+
resp.on('end', () => {
|
|
67
|
+
resolve(new Response(Buffer.concat(body).toString(), {
|
|
68
|
+
status: resp.statusCode ?? 200,
|
|
69
|
+
headers: resp.headers,
|
|
70
|
+
}));
|
|
71
|
+
});
|
|
72
|
+
});
|
|
73
|
+
const body = JSON.stringify({
|
|
74
|
+
opts,
|
|
75
|
+
code,
|
|
76
|
+
});
|
|
77
|
+
req.write(body, (err) => {
|
|
78
|
+
if (err !== null && err !== undefined) {
|
|
79
|
+
reject(err);
|
|
80
|
+
}
|
|
81
|
+
});
|
|
82
|
+
req.end();
|
|
83
|
+
});
|
|
84
|
+
if (resp.status === 200) {
|
|
85
|
+
const { result, logLines, errLines } = (await resp.json());
|
|
86
|
+
const returnOutput = result === null ? null
|
|
87
|
+
: result === undefined ? null
|
|
88
|
+
: {
|
|
89
|
+
type: 'text',
|
|
90
|
+
text: typeof result === 'string' ? result : JSON.stringify(result),
|
|
91
|
+
};
|
|
92
|
+
const logOutput = logLines.length === 0 ?
|
|
93
|
+
null
|
|
94
|
+
: {
|
|
95
|
+
type: 'text',
|
|
96
|
+
text: logLines.join('\n'),
|
|
97
|
+
};
|
|
98
|
+
const errOutput = errLines.length === 0 ?
|
|
99
|
+
null
|
|
100
|
+
: {
|
|
101
|
+
type: 'text',
|
|
102
|
+
text: 'Error output:\n' + errLines.join('\n'),
|
|
103
|
+
};
|
|
104
|
+
return {
|
|
105
|
+
content: [returnOutput, logOutput, errOutput].filter((block) => block !== null),
|
|
106
|
+
};
|
|
107
|
+
}
|
|
108
|
+
else {
|
|
109
|
+
const { message } = (await resp.json());
|
|
110
|
+
throw new Error(message);
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
catch (e) {
|
|
114
|
+
throw e;
|
|
115
|
+
}
|
|
116
|
+
finally {
|
|
117
|
+
worker.terminate();
|
|
118
|
+
}
|
|
119
|
+
};
|
|
120
|
+
return { metadata, tool, handler };
|
|
121
|
+
}
|
|
122
|
+
//# 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,EAAE,OAAO,EAAE,MAAM,WAAW;OAC5B,EAAE,aAAa,EAAE,MAAM,UAAU;AAQxC;;;;;;;;GAQG;AACH,MAAM,CAAC,KAAK,UAAU,QAAQ;IAC5B,MAAM,QAAQ,GAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,SAAS,EAAE,OAAO,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC;IAC7E,MAAM,IAAI,GAAS;QACjB,IAAI,EAAE,SAAS;QACf,WAAW,EACT,khCAAkhC;QACphC,WAAW,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,UAAU,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE;KAC1E,CAAC;IAEF,2GAA2G;IAC3G,MAAM,EAAE,iBAAiB,EAAE,GAAG,MAAM,MAAM,CAAC,2BAA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EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;AACrC,CAAC"}
|
package/compat.d.mts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Tool } from '@modelcontextprotocol/sdk/types.js';
|
|
2
|
+
import { z } from 'zod';
|
|
2
3
|
import { Endpoint } from "./tools.mjs";
|
|
3
4
|
export interface ClientCapabilities {
|
|
4
5
|
topLevelUnions: boolean;
|
|
@@ -9,8 +10,9 @@ export interface ClientCapabilities {
|
|
|
9
10
|
toolNameLength: number | undefined;
|
|
10
11
|
}
|
|
11
12
|
export declare const defaultClientCapabilities: ClientCapabilities;
|
|
12
|
-
export
|
|
13
|
-
export
|
|
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>;
|
|
14
16
|
/**
|
|
15
17
|
* Attempts to parse strings into JSON objects
|
|
16
18
|
*/
|
package/compat.d.mts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compat.d.mts","sourceRoot":"","sources":["src/compat.ts"],"names":[],"mappings":"OAAO,EAAE,IAAI,EAAE,MAAM,oCAAoC;OAClD,EAAE,QAAQ,EAAE;AAEnB,MAAM,WAAW,kBAAkB;IACjC,cAAc,EAAE,OAAO,CAAC;IACxB,SAAS,EAAE,OAAO,CAAC;IACnB,IAAI,EAAE,OAAO,CAAC;IACd,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,OAAO,CAAC;IACjB,cAAc,EAAE,MAAM,GAAG,SAAS,CAAC;CACpC;AAED,eAAO,MAAM,yBAAyB,EAAE,kBAOvC,CAAC;AAEF,MAAM,MAAM,UAAU,GAAG,
|
|
1
|
+
{"version":3,"file":"compat.d.mts","sourceRoot":"","sources":["src/compat.ts"],"names":[],"mappings":"OAAO,EAAE,IAAI,EAAE,MAAM,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zF;AAED;;;GAGG;AACH,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,EAAE,CAyCvD;AAED,iBAAS,YAAY,CACnB,MAAM,EAAE,UAAU,EAClB,IAAI,EAAE,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
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Tool } from '@modelcontextprotocol/sdk/types.js';
|
|
2
|
+
import { z } from 'zod';
|
|
2
3
|
import { Endpoint } from "./tools.js";
|
|
3
4
|
export interface ClientCapabilities {
|
|
4
5
|
topLevelUnions: boolean;
|
|
@@ -9,8 +10,9 @@ export interface ClientCapabilities {
|
|
|
9
10
|
toolNameLength: number | undefined;
|
|
10
11
|
}
|
|
11
12
|
export declare const defaultClientCapabilities: ClientCapabilities;
|
|
12
|
-
export
|
|
13
|
-
export
|
|
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>;
|
|
14
16
|
/**
|
|
15
17
|
* Attempts to parse strings into JSON objects
|
|
16
18
|
*/
|
package/compat.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compat.d.ts","sourceRoot":"","sources":["src/compat.ts"],"names":[],"mappings":"OAAO,EAAE,IAAI,EAAE,MAAM,oCAAoC;OAClD,EAAE,QAAQ,EAAE;AAEnB,MAAM,WAAW,kBAAkB;IACjC,cAAc,EAAE,OAAO,CAAC;IACxB,SAAS,EAAE,OAAO,CAAC;IACnB,IAAI,EAAE,OAAO,CAAC;IACd,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,OAAO,CAAC;IACjB,cAAc,EAAE,MAAM,GAAG,SAAS,CAAC;CACpC;AAED,eAAO,MAAM,yBAAyB,EAAE,kBAOvC,CAAC;AAEF,MAAM,MAAM,UAAU,GAAG,
|
|
1
|
+
{"version":3,"file":"compat.d.ts","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,OAAO,CAAC;IACnB,IAAI,EAAE,OAAO,CAAC;IACd,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,OAAO,CAAC;IACjB,cAAc,EAAE,MAAM,GAAG,SAAS,CAAC;CACpC;AAED,eAAO,MAAM,yBAAyB,EAAE,kBAOvC,CAAC;AAEF,eAAO,MAAM,UAAU,0EAAwE,CAAC;AAChG,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AAKpD,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,OAAO,CAAC,UAAU,EAAE,OAAO,CAAC,EAAE,kBAAkB,CAiCjF,CAAC;AAEF;;GAEG;AACH,wBAAgB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AgB,iCAAiC,CAC/C,SAAS,EAAE,QAAQ,EAAE,EACrB,YAAY,EAAE,kBAAkB,GAC/B,QAAQ,EAAE,CAiEZ"}
|
package/compat.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.knownClients = exports.defaultClientCapabilities = void 0;
|
|
3
|
+
exports.knownClients = exports.ClientType = exports.defaultClientCapabilities = void 0;
|
|
4
4
|
exports.parseEmbeddedJSON = parseEmbeddedJSON;
|
|
5
5
|
exports.truncateToolNames = truncateToolNames;
|
|
6
6
|
exports.removeTopLevelUnions = removeTopLevelUnions;
|
|
@@ -9,6 +9,7 @@ exports.inlineRefs = inlineRefs;
|
|
|
9
9
|
exports.removeAnyOf = removeAnyOf;
|
|
10
10
|
exports.removeFormats = removeFormats;
|
|
11
11
|
exports.applyCompatibilityTransformations = applyCompatibilityTransformations;
|
|
12
|
+
const zod_1 = require("zod");
|
|
12
13
|
exports.defaultClientCapabilities = {
|
|
13
14
|
topLevelUnions: true,
|
|
14
15
|
validJson: true,
|
|
@@ -17,6 +18,7 @@ exports.defaultClientCapabilities = {
|
|
|
17
18
|
formats: true,
|
|
18
19
|
toolNameLength: undefined,
|
|
19
20
|
};
|
|
21
|
+
exports.ClientType = zod_1.z.enum(['openai-agents', 'claude', 'claude-code', 'cursor', 'infer']);
|
|
20
22
|
// Client presets for compatibility
|
|
21
23
|
// Note that these could change over time as models get better, so this is
|
|
22
24
|
// a best effort.
|