@anthropic-ai/sdk 0.120.0 → 0.122.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/CHANGELOG.md +62 -0
- package/README.md +1 -1
- package/core/middleware.d.mts.map +1 -1
- package/core/middleware.d.ts.map +1 -1
- package/core/middleware.js +4 -4
- package/core/middleware.js.map +1 -1
- package/core/middleware.mjs +4 -4
- package/core/middleware.mjs.map +1 -1
- package/helpers/beta/standard-schema.d.mts +45 -0
- package/helpers/beta/standard-schema.d.mts.map +1 -0
- package/helpers/beta/standard-schema.d.ts +45 -0
- package/helpers/beta/standard-schema.d.ts.map +1 -0
- package/helpers/beta/standard-schema.js +58 -0
- package/helpers/beta/standard-schema.js.map +1 -0
- package/helpers/beta/standard-schema.mjs +54 -0
- package/helpers/beta/standard-schema.mjs.map +1 -0
- package/internal/detect-platform.js +1 -1
- package/internal/detect-platform.js.map +1 -1
- package/internal/detect-platform.mjs +1 -1
- package/internal/detect-platform.mjs.map +1 -1
- package/internal/errors.d.mts.map +1 -1
- package/internal/errors.d.ts.map +1 -1
- package/internal/errors.js +3 -1
- package/internal/errors.js.map +1 -1
- package/internal/errors.mjs +3 -1
- package/internal/errors.mjs.map +1 -1
- package/internal/parse.js +1 -1
- package/internal/parse.js.map +1 -1
- package/internal/parse.mjs +1 -1
- package/internal/parse.mjs.map +1 -1
- package/internal/uploads.js +10 -6
- package/internal/uploads.js.map +1 -1
- package/internal/uploads.mjs +10 -6
- package/internal/uploads.mjs.map +1 -1
- package/internal/utils/values.d.mts +6 -0
- package/internal/utils/values.d.mts.map +1 -1
- package/internal/utils/values.d.ts +6 -0
- package/internal/utils/values.d.ts.map +1 -1
- package/internal/utils/values.js +7 -0
- package/internal/utils/values.js.map +1 -1
- package/internal/utils/values.mjs +6 -0
- package/internal/utils/values.mjs.map +1 -1
- package/lib/BetaMessageStream.d.mts.map +1 -1
- package/lib/BetaMessageStream.d.ts.map +1 -1
- package/lib/BetaMessageStream.js +3 -4
- package/lib/BetaMessageStream.js.map +1 -1
- package/lib/BetaMessageStream.mjs +1 -2
- package/lib/BetaMessageStream.mjs.map +1 -1
- package/lib/MessageStream.d.mts.map +1 -1
- package/lib/MessageStream.d.ts.map +1 -1
- package/lib/MessageStream.js +3 -4
- package/lib/MessageStream.js.map +1 -1
- package/lib/MessageStream.mjs +1 -2
- package/lib/MessageStream.mjs.map +1 -1
- package/lib/sessions/accumulate.d.mts +3 -2
- package/lib/sessions/accumulate.d.mts.map +1 -1
- package/lib/sessions/accumulate.d.ts +3 -2
- package/lib/sessions/accumulate.d.ts.map +1 -1
- package/lib/sessions/accumulate.js +3 -46
- package/lib/sessions/accumulate.js.map +1 -1
- package/lib/sessions/accumulate.mjs +3 -46
- package/lib/sessions/accumulate.mjs.map +1 -1
- package/lib/standard-schema.d.mts +131 -0
- package/lib/standard-schema.d.mts.map +1 -0
- package/lib/standard-schema.d.ts +131 -0
- package/lib/standard-schema.d.ts.map +1 -0
- package/lib/standard-schema.js +45 -0
- package/lib/standard-schema.js.map +1 -0
- package/lib/standard-schema.mjs +41 -0
- package/lib/standard-schema.mjs.map +1 -0
- package/lib/tools/BetaToolRunner.d.mts.map +1 -1
- package/lib/tools/BetaToolRunner.d.ts.map +1 -1
- package/lib/tools/BetaToolRunner.js +35 -6
- package/lib/tools/BetaToolRunner.js.map +1 -1
- package/lib/tools/BetaToolRunner.mjs +35 -6
- package/lib/tools/BetaToolRunner.mjs.map +1 -1
- package/package.json +2 -11
- package/resources/beta/beta.d.mts +11 -7
- package/resources/beta/beta.d.mts.map +1 -1
- package/resources/beta/beta.d.ts +11 -7
- package/resources/beta/beta.d.ts.map +1 -1
- package/resources/beta/beta.js +4 -0
- package/resources/beta/beta.js.map +1 -1
- package/resources/beta/beta.mjs +4 -0
- package/resources/beta/beta.mjs.map +1 -1
- package/resources/beta/environments/environments.d.mts +8 -1
- package/resources/beta/environments/environments.d.mts.map +1 -1
- package/resources/beta/environments/environments.d.ts +8 -1
- package/resources/beta/environments/environments.d.ts.map +1 -1
- package/resources/beta/environments/environments.js.map +1 -1
- package/resources/beta/environments/environments.mjs.map +1 -1
- package/resources/beta/files.d.mts +25 -5
- package/resources/beta/files.d.mts.map +1 -1
- package/resources/beta/files.d.ts +25 -5
- package/resources/beta/files.d.ts.map +1 -1
- package/resources/beta/files.js +6 -6
- package/resources/beta/files.js.map +1 -1
- package/resources/beta/files.mjs +7 -7
- package/resources/beta/files.mjs.map +1 -1
- package/resources/beta/index.d.mts +4 -3
- package/resources/beta/index.d.mts.map +1 -1
- package/resources/beta/index.d.ts +4 -3
- package/resources/beta/index.d.ts.map +1 -1
- package/resources/beta/index.js +11 -9
- package/resources/beta/index.js.map +1 -1
- package/resources/beta/index.mjs +1 -0
- package/resources/beta/index.mjs.map +1 -1
- package/resources/beta/memory-stores/memories.d.mts +6 -5
- package/resources/beta/memory-stores/memories.d.mts.map +1 -1
- package/resources/beta/memory-stores/memories.d.ts +6 -5
- package/resources/beta/memory-stores/memories.d.ts.map +1 -1
- package/resources/beta/memory-stores/memory-versions.d.mts +8 -5
- package/resources/beta/memory-stores/memory-versions.d.mts.map +1 -1
- package/resources/beta/memory-stores/memory-versions.d.ts +8 -5
- package/resources/beta/memory-stores/memory-versions.d.ts.map +1 -1
- package/resources/beta/messages/index.d.mts +1 -1
- package/resources/beta/messages/index.d.mts.map +1 -1
- package/resources/beta/messages/index.d.ts +1 -1
- package/resources/beta/messages/index.d.ts.map +1 -1
- package/resources/beta/messages/messages.d.mts +69 -27
- package/resources/beta/messages/messages.d.mts.map +1 -1
- package/resources/beta/messages/messages.d.ts +69 -27
- package/resources/beta/messages/messages.d.ts.map +1 -1
- package/resources/beta/messages/messages.js.map +1 -1
- package/resources/beta/messages/messages.mjs.map +1 -1
- package/resources/beta/organization/api-keys.d.mts +177 -0
- package/resources/beta/organization/api-keys.d.mts.map +1 -0
- package/resources/beta/organization/api-keys.d.ts +177 -0
- package/resources/beta/organization/api-keys.d.ts.map +1 -0
- package/resources/beta/organization/api-keys.js +56 -0
- package/resources/beta/organization/api-keys.js.map +1 -0
- package/resources/beta/organization/api-keys.mjs +52 -0
- package/resources/beta/organization/api-keys.mjs.map +1 -0
- package/resources/beta/organization/external-keys.d.mts +269 -0
- package/resources/beta/organization/external-keys.d.mts.map +1 -0
- package/resources/beta/organization/external-keys.d.ts +269 -0
- package/resources/beta/organization/external-keys.d.ts.map +1 -0
- package/resources/beta/organization/external-keys.js +119 -0
- package/resources/beta/organization/external-keys.js.map +1 -0
- package/resources/beta/organization/external-keys.mjs +115 -0
- package/resources/beta/organization/external-keys.mjs.map +1 -0
- package/resources/beta/organization/federation/federation.d.mts +14 -0
- package/resources/beta/organization/federation/federation.d.mts.map +1 -0
- package/resources/beta/organization/federation/federation.d.ts +14 -0
- package/resources/beta/organization/federation/federation.d.ts.map +1 -0
- package/resources/beta/organization/federation/federation.js +21 -0
- package/resources/beta/organization/federation/federation.js.map +1 -0
- package/resources/beta/organization/federation/federation.mjs +16 -0
- package/resources/beta/organization/federation/federation.mjs.map +1 -0
- package/resources/beta/organization/federation/index.d.mts +4 -0
- package/resources/beta/organization/federation/index.d.mts.map +1 -0
- package/resources/beta/organization/federation/index.d.ts +4 -0
- package/resources/beta/organization/federation/index.d.ts.map +1 -0
- package/resources/beta/organization/federation/index.js +11 -0
- package/resources/beta/organization/federation/index.js.map +1 -0
- package/resources/beta/organization/federation/index.mjs +5 -0
- package/resources/beta/organization/federation/index.mjs.map +1 -0
- package/resources/beta/organization/federation/issuers.d.mts +353 -0
- package/resources/beta/organization/federation/issuers.d.mts.map +1 -0
- package/resources/beta/organization/federation/issuers.d.ts +353 -0
- package/resources/beta/organization/federation/issuers.d.ts.map +1 -0
- package/resources/beta/organization/federation/issuers.js +169 -0
- package/resources/beta/organization/federation/issuers.js.map +1 -0
- package/resources/beta/organization/federation/issuers.mjs +165 -0
- package/resources/beta/organization/federation/issuers.mjs.map +1 -0
- package/resources/beta/organization/federation/rules/index.d.mts +3 -0
- package/resources/beta/organization/federation/rules/index.d.mts.map +1 -0
- package/resources/beta/organization/federation/rules/index.d.ts +3 -0
- package/resources/beta/organization/federation/rules/index.d.ts.map +1 -0
- package/resources/beta/organization/federation/rules/index.js +9 -0
- package/resources/beta/organization/federation/rules/index.js.map +1 -0
- package/resources/beta/organization/federation/rules/index.mjs +4 -0
- package/resources/beta/organization/federation/rules/index.mjs.map +1 -0
- package/resources/beta/organization/federation/rules/rules.d.mts +468 -0
- package/resources/beta/organization/federation/rules/rules.d.mts.map +1 -0
- package/resources/beta/organization/federation/rules/rules.d.ts +468 -0
- package/resources/beta/organization/federation/rules/rules.d.ts.map +1 -0
- package/resources/beta/organization/federation/rules/rules.js +198 -0
- package/resources/beta/organization/federation/rules/rules.js.map +1 -0
- package/resources/beta/organization/federation/rules/rules.mjs +193 -0
- package/resources/beta/organization/federation/rules/rules.mjs.map +1 -0
- package/resources/beta/organization/federation/rules/workspaces.d.mts +124 -0
- package/resources/beta/organization/federation/rules/workspaces.d.mts.map +1 -0
- package/resources/beta/organization/federation/rules/workspaces.d.ts +124 -0
- package/resources/beta/organization/federation/rules/workspaces.d.ts.map +1 -0
- package/resources/beta/organization/federation/rules/workspaces.js +114 -0
- package/resources/beta/organization/federation/rules/workspaces.js.map +1 -0
- package/resources/beta/organization/federation/rules/workspaces.mjs +110 -0
- package/resources/beta/organization/federation/rules/workspaces.mjs.map +1 -0
- package/resources/beta/organization/federation/rules.d.mts +2 -0
- package/resources/beta/organization/federation/rules.d.mts.map +1 -0
- package/resources/beta/organization/federation/rules.d.ts +2 -0
- package/resources/beta/organization/federation/rules.d.ts.map +1 -0
- package/resources/beta/organization/federation/rules.js +6 -0
- package/resources/beta/organization/federation/rules.js.map +1 -0
- package/resources/beta/organization/federation/rules.mjs +3 -0
- package/resources/beta/organization/federation/rules.mjs.map +1 -0
- package/resources/beta/organization/federation.d.mts +2 -0
- package/resources/beta/organization/federation.d.mts.map +1 -0
- package/resources/beta/organization/federation.d.ts +2 -0
- package/resources/beta/organization/federation.d.ts.map +1 -0
- package/resources/beta/organization/federation.js +6 -0
- package/resources/beta/organization/federation.js.map +1 -0
- package/resources/beta/organization/federation.mjs +3 -0
- package/resources/beta/organization/federation.mjs.map +1 -0
- package/resources/beta/organization/index.d.mts +10 -0
- package/resources/beta/organization/index.d.mts.map +1 -0
- package/resources/beta/organization/index.d.ts +10 -0
- package/resources/beta/organization/index.d.ts.map +1 -0
- package/resources/beta/organization/index.js +23 -0
- package/resources/beta/organization/index.js.map +1 -0
- package/resources/beta/organization/index.mjs +11 -0
- package/resources/beta/organization/index.mjs.map +1 -0
- package/resources/beta/organization/invites.d.mts +162 -0
- package/resources/beta/organization/invites.d.mts.map +1 -0
- package/resources/beta/organization/invites.d.ts +162 -0
- package/resources/beta/organization/invites.d.ts.map +1 -0
- package/resources/beta/organization/invites.js +76 -0
- package/resources/beta/organization/invites.js.map +1 -0
- package/resources/beta/organization/invites.mjs +72 -0
- package/resources/beta/organization/invites.mjs.map +1 -0
- package/resources/beta/organization/organization.d.mts +69 -0
- package/resources/beta/organization/organization.d.mts.map +1 -0
- package/resources/beta/organization/organization.d.ts +69 -0
- package/resources/beta/organization/organization.d.ts.map +1 -0
- package/resources/beta/organization/organization.js +58 -0
- package/resources/beta/organization/organization.js.map +1 -0
- package/resources/beta/organization/organization.mjs +53 -0
- package/resources/beta/organization/organization.mjs.map +1 -0
- package/resources/beta/organization/rate-limits.d.mts +77 -0
- package/resources/beta/organization/rate-limits.d.mts.map +1 -0
- package/resources/beta/organization/rate-limits.d.ts +77 -0
- package/resources/beta/organization/rate-limits.d.ts.map +1 -0
- package/resources/beta/organization/rate-limits.js +31 -0
- package/resources/beta/organization/rate-limits.js.map +1 -0
- package/resources/beta/organization/rate-limits.mjs +27 -0
- package/resources/beta/organization/rate-limits.mjs.map +1 -0
- package/resources/beta/organization/service-accounts/index.d.mts +3 -0
- package/resources/beta/organization/service-accounts/index.d.mts.map +1 -0
- package/resources/beta/organization/service-accounts/index.d.ts +3 -0
- package/resources/beta/organization/service-accounts/index.d.ts.map +1 -0
- package/resources/beta/organization/service-accounts/index.js +9 -0
- package/resources/beta/organization/service-accounts/index.js.map +1 -0
- package/resources/beta/organization/service-accounts/index.mjs +4 -0
- package/resources/beta/organization/service-accounts/index.mjs.map +1 -0
- package/resources/beta/organization/service-accounts/service-accounts.d.mts +258 -0
- package/resources/beta/organization/service-accounts/service-accounts.d.mts.map +1 -0
- package/resources/beta/organization/service-accounts/service-accounts.d.ts +258 -0
- package/resources/beta/organization/service-accounts/service-accounts.d.ts.map +1 -0
- package/resources/beta/organization/service-accounts/service-accounts.js +174 -0
- package/resources/beta/organization/service-accounts/service-accounts.js.map +1 -0
- package/resources/beta/organization/service-accounts/service-accounts.mjs +169 -0
- package/resources/beta/organization/service-accounts/service-accounts.mjs.map +1 -0
- package/resources/beta/organization/service-accounts/workspaces.d.mts +141 -0
- package/resources/beta/organization/service-accounts/workspaces.d.mts.map +1 -0
- package/resources/beta/organization/service-accounts/workspaces.d.ts +141 -0
- package/resources/beta/organization/service-accounts/workspaces.d.ts.map +1 -0
- package/resources/beta/organization/service-accounts/workspaces.js +125 -0
- package/resources/beta/organization/service-accounts/workspaces.js.map +1 -0
- package/resources/beta/organization/service-accounts/workspaces.mjs +121 -0
- package/resources/beta/organization/service-accounts/workspaces.mjs.map +1 -0
- package/resources/beta/organization/service-accounts.d.mts +2 -0
- package/resources/beta/organization/service-accounts.d.mts.map +1 -0
- package/resources/beta/organization/service-accounts.d.ts +2 -0
- package/resources/beta/organization/service-accounts.d.ts.map +1 -0
- package/resources/beta/organization/service-accounts.js +6 -0
- package/resources/beta/organization/service-accounts.js.map +1 -0
- package/resources/beta/organization/service-accounts.mjs +3 -0
- package/resources/beta/organization/service-accounts.mjs.map +1 -0
- package/resources/beta/organization/users.d.mts +124 -0
- package/resources/beta/organization/users.d.mts.map +1 -0
- package/resources/beta/organization/users.d.ts +124 -0
- package/resources/beta/organization/users.d.ts.map +1 -0
- package/resources/beta/organization/users.js +67 -0
- package/resources/beta/organization/users.js.map +1 -0
- package/resources/beta/organization/users.mjs +63 -0
- package/resources/beta/organization/users.mjs.map +1 -0
- package/resources/beta/organization/workspaces/index.d.mts +5 -0
- package/resources/beta/organization/workspaces/index.d.mts.map +1 -0
- package/resources/beta/organization/workspaces/index.d.ts +5 -0
- package/resources/beta/organization/workspaces/index.d.ts.map +1 -0
- package/resources/beta/organization/workspaces/index.js +13 -0
- package/resources/beta/organization/workspaces/index.js.map +1 -0
- package/resources/beta/organization/workspaces/index.mjs +6 -0
- package/resources/beta/organization/workspaces/index.mjs.map +1 -0
- package/resources/beta/organization/workspaces/members.d.mts +135 -0
- package/resources/beta/organization/workspaces/members.d.mts.map +1 -0
- package/resources/beta/organization/workspaces/members.d.ts +135 -0
- package/resources/beta/organization/workspaces/members.d.ts.map +1 -0
- package/resources/beta/organization/workspaces/members.js +102 -0
- package/resources/beta/organization/workspaces/members.js.map +1 -0
- package/resources/beta/organization/workspaces/members.mjs +98 -0
- package/resources/beta/organization/workspaces/members.mjs.map +1 -0
- package/resources/beta/organization/workspaces/rate-limits.d.mts +83 -0
- package/resources/beta/organization/workspaces/rate-limits.d.mts.map +1 -0
- package/resources/beta/organization/workspaces/rate-limits.d.ts +83 -0
- package/resources/beta/organization/workspaces/rate-limits.d.ts.map +1 -0
- package/resources/beta/organization/workspaces/rate-limits.js +34 -0
- package/resources/beta/organization/workspaces/rate-limits.js.map +1 -0
- package/resources/beta/organization/workspaces/rate-limits.mjs +30 -0
- package/resources/beta/organization/workspaces/rate-limits.mjs.map +1 -0
- package/resources/beta/organization/workspaces/service-accounts.d.mts +210 -0
- package/resources/beta/organization/workspaces/service-accounts.d.mts.map +1 -0
- package/resources/beta/organization/workspaces/service-accounts.d.ts +210 -0
- package/resources/beta/organization/workspaces/service-accounts.d.ts.map +1 -0
- package/resources/beta/organization/workspaces/service-accounts.js +189 -0
- package/resources/beta/organization/workspaces/service-accounts.js.map +1 -0
- package/resources/beta/organization/workspaces/service-accounts.mjs +185 -0
- package/resources/beta/organization/workspaces/service-accounts.mjs.map +1 -0
- package/resources/beta/organization/workspaces/workspaces.d.mts +287 -0
- package/resources/beta/organization/workspaces/workspaces.d.mts.map +1 -0
- package/resources/beta/organization/workspaces/workspaces.d.ts +287 -0
- package/resources/beta/organization/workspaces/workspaces.d.ts.map +1 -0
- package/resources/beta/organization/workspaces/workspaces.js +112 -0
- package/resources/beta/organization/workspaces/workspaces.js.map +1 -0
- package/resources/beta/organization/workspaces/workspaces.mjs +107 -0
- package/resources/beta/organization/workspaces/workspaces.mjs.map +1 -0
- package/resources/beta/organization/workspaces.d.mts +2 -0
- package/resources/beta/organization/workspaces.d.mts.map +1 -0
- package/resources/beta/organization/workspaces.d.ts +2 -0
- package/resources/beta/organization/workspaces.d.ts.map +1 -0
- package/resources/beta/organization/workspaces.js +6 -0
- package/resources/beta/organization/workspaces.js.map +1 -0
- package/resources/beta/organization/workspaces.mjs +3 -0
- package/resources/beta/organization/workspaces.mjs.map +1 -0
- package/resources/beta/organization.d.mts +2 -0
- package/resources/beta/organization.d.mts.map +1 -0
- package/resources/beta/organization.d.ts +2 -0
- package/resources/beta/organization.d.ts.map +1 -0
- package/resources/beta/organization.js +6 -0
- package/resources/beta/organization.js.map +1 -0
- package/resources/beta/organization.mjs +3 -0
- package/resources/beta/organization.mjs.map +1 -0
- package/resources/beta/sessions/threads/threads.d.mts +2 -1
- package/resources/beta/sessions/threads/threads.d.mts.map +1 -1
- package/resources/beta/sessions/threads/threads.d.ts +2 -1
- package/resources/beta/sessions/threads/threads.d.ts.map +1 -1
- package/resources/beta/sessions/threads/threads.js.map +1 -1
- package/resources/beta/sessions/threads/threads.mjs.map +1 -1
- package/resources/beta/skills/index.d.mts +2 -2
- package/resources/beta/skills/index.d.mts.map +1 -1
- package/resources/beta/skills/index.d.ts +2 -2
- package/resources/beta/skills/index.d.ts.map +1 -1
- package/resources/beta/skills/index.js.map +1 -1
- package/resources/beta/skills/index.mjs.map +1 -1
- package/resources/beta/skills/skills.d.mts +48 -120
- package/resources/beta/skills/skills.d.mts.map +1 -1
- package/resources/beta/skills/skills.d.ts +48 -120
- package/resources/beta/skills/skills.d.ts.map +1 -1
- package/resources/beta/skills/skills.js +12 -8
- package/resources/beta/skills/skills.js.map +1 -1
- package/resources/beta/skills/skills.mjs +12 -8
- package/resources/beta/skills/skills.mjs.map +1 -1
- package/resources/beta/skills/versions.d.mts +35 -138
- package/resources/beta/skills/versions.d.mts.map +1 -1
- package/resources/beta/skills/versions.d.ts +35 -138
- package/resources/beta/skills/versions.d.ts.map +1 -1
- package/resources/beta/skills/versions.js +18 -18
- package/resources/beta/skills/versions.js.map +1 -1
- package/resources/beta/skills/versions.mjs +18 -18
- package/resources/beta/skills/versions.mjs.map +1 -1
- package/resources/beta/webhooks.d.mts +16 -17
- package/resources/beta/webhooks.d.mts.map +1 -1
- package/resources/beta/webhooks.d.ts +16 -17
- package/resources/beta/webhooks.d.ts.map +1 -1
- package/resources/beta/webhooks.js +21 -8
- package/resources/beta/webhooks.js.map +1 -1
- package/resources/beta/webhooks.mjs +21 -8
- package/resources/beta/webhooks.mjs.map +1 -1
- package/src/core/middleware.ts +4 -3
- package/src/helpers/beta/standard-schema.ts +99 -0
- package/src/internal/detect-platform.ts +1 -1
- package/src/internal/errors.ts +3 -1
- package/src/internal/parse.ts +1 -1
- package/src/internal/uploads.ts +10 -7
- package/src/internal/utils/values.ts +7 -0
- package/src/lib/BetaMessageStream.ts +1 -3
- package/src/lib/MessageStream.ts +1 -3
- package/src/lib/sessions/accumulate.ts +7 -49
- package/src/lib/standard-schema.ts +209 -0
- package/src/lib/tools/BetaToolRunner.ts +38 -6
- package/src/resources/beta/beta.ts +30 -15
- package/src/resources/beta/environments/environments.ts +8 -1
- package/src/resources/beta/files.ts +34 -11
- package/src/resources/beta/index.ts +7 -7
- package/src/resources/beta/memory-stores/memories.ts +6 -5
- package/src/resources/beta/memory-stores/memory-versions.ts +8 -5
- package/src/resources/beta/messages/index.ts +1 -1
- package/src/resources/beta/messages/messages.ts +72 -30
- package/src/resources/beta/organization/api-keys.ts +231 -0
- package/src/resources/beta/organization/external-keys.ts +362 -0
- package/src/resources/beta/organization/federation/federation.ts +71 -0
- package/src/resources/beta/organization/federation/index.ts +31 -0
- package/src/resources/beta/organization/federation/issuers.ts +486 -0
- package/src/resources/beta/organization/federation/rules/index.ts +23 -0
- package/src/resources/beta/organization/federation/rules/rules.ts +624 -0
- package/src/resources/beta/organization/federation/rules/workspaces.ts +196 -0
- package/src/resources/beta/organization/federation/rules.ts +3 -0
- package/src/resources/beta/organization/federation.ts +3 -0
- package/src/resources/beta/organization/index.ts +83 -0
- package/src/resources/beta/organization/invites.ts +207 -0
- package/src/resources/beta/organization/organization.ts +245 -0
- package/src/resources/beta/organization/rate-limits.ts +104 -0
- package/src/resources/beta/organization/service-accounts/index.ts +21 -0
- package/src/resources/beta/organization/service-accounts/service-accounts.ts +389 -0
- package/src/resources/beta/organization/service-accounts/workspaces.ts +217 -0
- package/src/resources/beta/organization/service-accounts.ts +3 -0
- package/src/resources/beta/organization/users.ts +163 -0
- package/src/resources/beta/organization/workspaces/index.ts +43 -0
- package/src/resources/beta/organization/workspaces/members.ts +209 -0
- package/src/resources/beta/organization/workspaces/rate-limits.ts +113 -0
- package/src/resources/beta/organization/workspaces/service-accounts.ts +325 -0
- package/src/resources/beta/organization/workspaces/workspaces.ts +434 -0
- package/src/resources/beta/organization/workspaces.ts +3 -0
- package/src/resources/beta/organization.ts +3 -0
- package/src/resources/beta/sessions/threads/threads.ts +2 -1
- package/src/resources/beta/skills/index.ts +7 -10
- package/src/resources/beta/skills/skills.ts +60 -150
- package/src/resources/beta/skills/versions.ts +43 -166
- package/src/resources/beta/webhooks.ts +25 -29
- package/src/tools/agent-toolset/node.browser.ts +1 -5
- package/src/tools/agent-toolset/node.ts +122 -17
- package/src/tools/agent-toolset/skills.ts +5 -33
- package/src/version.ts +1 -1
- package/tools/agent-toolset/node.browser.d.mts +1 -2
- package/tools/agent-toolset/node.browser.d.mts.map +1 -1
- package/tools/agent-toolset/node.browser.d.ts +1 -2
- package/tools/agent-toolset/node.browser.d.ts.map +1 -1
- package/tools/agent-toolset/node.browser.js +0 -4
- package/tools/agent-toolset/node.browser.js.map +1 -1
- package/tools/agent-toolset/node.browser.mjs +0 -3
- package/tools/agent-toolset/node.browser.mjs.map +1 -1
- package/tools/agent-toolset/node.d.mts +11 -9
- package/tools/agent-toolset/node.d.mts.map +1 -1
- package/tools/agent-toolset/node.d.ts +11 -9
- package/tools/agent-toolset/node.d.ts.map +1 -1
- package/tools/agent-toolset/node.js +96 -8
- package/tools/agent-toolset/node.js.map +1 -1
- package/tools/agent-toolset/node.mjs +96 -7
- package/tools/agent-toolset/node.mjs.map +1 -1
- package/tools/agent-toolset/skills.d.mts +0 -8
- package/tools/agent-toolset/skills.d.mts.map +1 -1
- package/tools/agent-toolset/skills.d.ts +0 -8
- package/tools/agent-toolset/skills.d.ts.map +1 -1
- package/tools/agent-toolset/skills.js +5 -25
- package/tools/agent-toolset/skills.js.map +1 -1
- package/tools/agent-toolset/skills.mjs +5 -24
- package/tools/agent-toolset/skills.mjs.map +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../src/resources/beta/messages/messages.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,6CAAgD;AAEhD,iEAAwC;AAExC,wDAAqD;AAErD,8DAAwE;AACxE,0DAAyD;AAEzD,0FAAkF;AAClF,6DAIkC;AAClC,yEAAmE;AACnE,yEAI2C;AAC3C,+DAAyD;AAKzD,0CAkBmB;AAEnB,MAAM,iBAAiB,GAEnB,EAAE,CAAC;AAEP,MAAM,oCAAoC,GAAY,CAAC,uBAAuB,EAAE,iBAAiB,CAAC,CAAC;AAEnG,MAAa,QAAS,SAAQ,sBAAW;IAAzC;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AAC,GAAG,CAAC,KAAK,IAAI,EAAE,CAAC,EAAE,2BAA2B,CAAC,CAAC,QAAQ,EAAE;oBAC5E,GAAG,CAAC,eAAe,IAAI,IAAI,CAAC,CAAC,CAAC,EAAE,2BAA2B,EAAE,eAAe,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC;iBAC5F;gBACD,OAAO,EAAE,OAAO;aACjB,CAAC;SACH,CAAC,CAAC;IACL,CAAC;IAWD,UAAU,CAAC,IAA0B,EAAE,OAAsC;QAC3E,OAAO,IAAI,cAAc,CAAC,IAAI,CAAC,OAAoB,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;IACtE,CAAC;CACF;AAED;;;GAGG;AACH,SAAS,qBAAqB,CAA2D,MAAS;IAChG,IAAI,CAAC,MAAM,CAAC,aAAa,EAAE,CAAC;QAC1B,OAAO,MAAM,CAAC;IAChB,CAAC;IAED,IAAI,MAAM,CAAC,aAAa,EAAE,MAAM,EAAE,CAAC;QACjC,MAAM,IAAI,cAAc,CACtB,6DAA6D;YAC3D,qEAAqE,CACxE,CAAC;IACJ,CAAC;IAED,MAAM,EAAE,aAAa,EAAE,GAAG,IAAI,EAAE,GAAG,MAAM,CAAC;IAE1C,OAAO;QACL,GAAG,IAAI;QACP,aAAa,EAAE;YACb,GAAG,MAAM,CAAC,aAAa;YACvB,MAAM,EAAE,aAAa;SACtB;KACG,CAAC;AACT,CAAC;AAq7MD,OAAO,EAAE,cAAc,EAA6B,8CAA0C;AAC9F,OAAO,EAAE,SAAS,EAAE,yCAAqC;AAEzD,QAAQ,CAAC,OAAO,GAAG,OAAO,CAAC;AAE3B,QAAQ,CAAC,cAAc,GAAG,cAAc,CAAC;AACzC,QAAQ,CAAC,SAAS,GAAG,SAAS,CAAC"}
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
2
|
+
import { APIPromise } from "../../../core/api-promise.mjs";
|
|
3
|
+
import { Page, type PageParams, PagePromise } from "../../../core/pagination.mjs";
|
|
4
|
+
import { RequestOptions } from "../../../internal/request-options.mjs";
|
|
5
|
+
export declare class APIKeys extends APIResource {
|
|
6
|
+
/**
|
|
7
|
+
* Get API Key
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```ts
|
|
11
|
+
* const betaAPIKey =
|
|
12
|
+
* await client.beta.organization.apiKeys.retrieve(
|
|
13
|
+
* 'api_key_id',
|
|
14
|
+
* );
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
retrieve(apiKeyID: string, options?: RequestOptions): APIPromise<BetaAPIKey>;
|
|
18
|
+
/**
|
|
19
|
+
* Update API Key
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* ```ts
|
|
23
|
+
* const betaAPIKey =
|
|
24
|
+
* await client.beta.organization.apiKeys.update(
|
|
25
|
+
* 'api_key_id',
|
|
26
|
+
* );
|
|
27
|
+
* ```
|
|
28
|
+
*/
|
|
29
|
+
update(apiKeyID: string, body: APIKeyUpdateParams, options?: RequestOptions): APIPromise<BetaAPIKey>;
|
|
30
|
+
/**
|
|
31
|
+
* List API Keys
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```ts
|
|
35
|
+
* // Automatically fetches more pages as needed.
|
|
36
|
+
* for await (const betaAPIKey of client.beta.organization.apiKeys.list()) {
|
|
37
|
+
* // ...
|
|
38
|
+
* }
|
|
39
|
+
* ```
|
|
40
|
+
*/
|
|
41
|
+
list(query?: APIKeyListParams | null | undefined, options?: RequestOptions): PagePromise<BetaAPIKeysPage, BetaAPIKey>;
|
|
42
|
+
}
|
|
43
|
+
export type BetaAPIKeysPage = Page<BetaAPIKey>;
|
|
44
|
+
export interface BetaAPIKey {
|
|
45
|
+
/**
|
|
46
|
+
* ID of the API key.
|
|
47
|
+
*/
|
|
48
|
+
id: string;
|
|
49
|
+
/**
|
|
50
|
+
* RFC 3339 datetime string indicating when the API Key was created.
|
|
51
|
+
*/
|
|
52
|
+
created_at: string;
|
|
53
|
+
/**
|
|
54
|
+
* The ID and type of the actor that created the API key, or `null` when the
|
|
55
|
+
* creator is not recorded (legacy, workload-identity-federated, or system-created
|
|
56
|
+
* keys).
|
|
57
|
+
*/
|
|
58
|
+
created_by: BetaAPIKeyCreatedBy | null;
|
|
59
|
+
/**
|
|
60
|
+
* RFC 3339 datetime string indicating when the API Key expires, or `null` if it
|
|
61
|
+
* never expires.
|
|
62
|
+
*/
|
|
63
|
+
expires_at: string | null;
|
|
64
|
+
/**
|
|
65
|
+
* Name of the API key.
|
|
66
|
+
*/
|
|
67
|
+
name: string;
|
|
68
|
+
/**
|
|
69
|
+
* Partially redacted hint for the API key.
|
|
70
|
+
*/
|
|
71
|
+
partial_key_hint: string | null;
|
|
72
|
+
/**
|
|
73
|
+
* The principal the API key acts as (a User or a Service Account), or `null` if
|
|
74
|
+
* the API key is not bound to a principal.
|
|
75
|
+
*/
|
|
76
|
+
principal: BetaAPIKeyUserActor | BetaAPIKeyServiceAccountActor | null;
|
|
77
|
+
/**
|
|
78
|
+
* Where the API key belongs: its Workspace
|
|
79
|
+
* (`{"type": "workspace", "workspace_id": "wrkspc_..."}`, with the Workspace's
|
|
80
|
+
* real ID even when it is the organization's default Workspace), or the
|
|
81
|
+
* organization (`{"type": "organization"}`) for a principal-bound API key that has
|
|
82
|
+
* no Workspace.
|
|
83
|
+
*/
|
|
84
|
+
scope: BetaAPIKeyOrganizationScope | BetaAPIKeyWorkspaceScope;
|
|
85
|
+
/**
|
|
86
|
+
* Status of the API key.
|
|
87
|
+
*/
|
|
88
|
+
status: 'active' | 'archived' | 'expired' | 'inactive';
|
|
89
|
+
/**
|
|
90
|
+
* Object type.
|
|
91
|
+
*
|
|
92
|
+
* For API Keys, this is always `"api_key"`.
|
|
93
|
+
*/
|
|
94
|
+
type: 'api_key';
|
|
95
|
+
/**
|
|
96
|
+
* @deprecated Use `scope` instead. `workspace_id` is `null` both for an API key in
|
|
97
|
+
* the default Workspace and for a principal-bound API key that has no Workspace.
|
|
98
|
+
*/
|
|
99
|
+
workspace_id: string | null;
|
|
100
|
+
}
|
|
101
|
+
export interface BetaAPIKeyCreatedBy {
|
|
102
|
+
/**
|
|
103
|
+
* ID of the actor that created the object.
|
|
104
|
+
*/
|
|
105
|
+
id: string;
|
|
106
|
+
/**
|
|
107
|
+
* Type of the actor that created the object.
|
|
108
|
+
*/
|
|
109
|
+
type: 'service_account' | 'user';
|
|
110
|
+
}
|
|
111
|
+
export interface BetaAPIKeyOrganizationScope {
|
|
112
|
+
/**
|
|
113
|
+
* Scope type. Always `"organization"`: the API key has no Workspace. Only a
|
|
114
|
+
* principal-bound API key can have this scope.
|
|
115
|
+
*/
|
|
116
|
+
type: 'organization';
|
|
117
|
+
}
|
|
118
|
+
export interface BetaAPIKeyServiceAccountActor {
|
|
119
|
+
/**
|
|
120
|
+
* ID of the Service Account the API key acts as.
|
|
121
|
+
*/
|
|
122
|
+
service_account_id: string;
|
|
123
|
+
/**
|
|
124
|
+
* Principal type. Always `"service_account_actor"` for a Service Account.
|
|
125
|
+
*/
|
|
126
|
+
type: 'service_account_actor';
|
|
127
|
+
}
|
|
128
|
+
export interface BetaAPIKeyUserActor {
|
|
129
|
+
/**
|
|
130
|
+
* Principal type. Always `"user_actor"` for a User.
|
|
131
|
+
*/
|
|
132
|
+
type: 'user_actor';
|
|
133
|
+
/**
|
|
134
|
+
* ID of the User the API key acts as.
|
|
135
|
+
*/
|
|
136
|
+
user_id: string;
|
|
137
|
+
}
|
|
138
|
+
export interface BetaAPIKeyWorkspaceScope {
|
|
139
|
+
/**
|
|
140
|
+
* Scope type. Always `"workspace"`: the API key belongs to one Workspace.
|
|
141
|
+
*/
|
|
142
|
+
type: 'workspace';
|
|
143
|
+
/**
|
|
144
|
+
* ID of the Workspace the API key belongs to. Unlike the deprecated top-level
|
|
145
|
+
* `workspace_id`, this is the Workspace's real ID even for the organization's
|
|
146
|
+
* default Workspace.
|
|
147
|
+
*/
|
|
148
|
+
workspace_id: string;
|
|
149
|
+
}
|
|
150
|
+
export interface APIKeyUpdateParams {
|
|
151
|
+
/**
|
|
152
|
+
* Name of the API key.
|
|
153
|
+
*/
|
|
154
|
+
name?: string | null;
|
|
155
|
+
/**
|
|
156
|
+
* Status of the API key.
|
|
157
|
+
*/
|
|
158
|
+
status?: 'active' | 'archived' | 'inactive' | null;
|
|
159
|
+
}
|
|
160
|
+
export interface APIKeyListParams extends PageParams {
|
|
161
|
+
/**
|
|
162
|
+
* Filter by the ID of the User who created the object.
|
|
163
|
+
*/
|
|
164
|
+
created_by_user_id?: string | null;
|
|
165
|
+
/**
|
|
166
|
+
* Filter by API key status.
|
|
167
|
+
*/
|
|
168
|
+
status?: 'active' | 'archived' | 'expired' | 'inactive' | null;
|
|
169
|
+
/**
|
|
170
|
+
* Filter by Workspace ID.
|
|
171
|
+
*/
|
|
172
|
+
workspace_id?: string | null;
|
|
173
|
+
}
|
|
174
|
+
export declare namespace APIKeys {
|
|
175
|
+
export { type BetaAPIKey as BetaAPIKey, type BetaAPIKeyCreatedBy as BetaAPIKeyCreatedBy, type BetaAPIKeyOrganizationScope as BetaAPIKeyOrganizationScope, type BetaAPIKeyServiceAccountActor as BetaAPIKeyServiceAccountActor, type BetaAPIKeyUserActor as BetaAPIKeyUserActor, type BetaAPIKeyWorkspaceScope as BetaAPIKeyWorkspaceScope, type BetaAPIKeysPage as BetaAPIKeysPage, type APIKeyUpdateParams as APIKeyUpdateParams, type APIKeyListParams as APIKeyListParams, };
|
|
176
|
+
}
|
|
177
|
+
//# sourceMappingURL=api-keys.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-keys.d.mts","sourceRoot":"","sources":["../../../src/resources/beta/organization/api-keys.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,mCAA+B;AACrD,OAAO,EAAE,UAAU,EAAE,sCAAkC;AACvD,OAAO,EAAE,IAAI,EAAE,KAAK,UAAU,EAAE,WAAW,EAAE,qCAAiC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KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,eAAe,IAAI,eAAe,EACvC,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,gBAAgB,IAAI,gBAAgB,GAC1C,CAAC;CACH"}
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.js";
|
|
2
|
+
import { APIPromise } from "../../../core/api-promise.js";
|
|
3
|
+
import { Page, type PageParams, PagePromise } from "../../../core/pagination.js";
|
|
4
|
+
import { RequestOptions } from "../../../internal/request-options.js";
|
|
5
|
+
export declare class APIKeys extends APIResource {
|
|
6
|
+
/**
|
|
7
|
+
* Get API Key
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```ts
|
|
11
|
+
* const betaAPIKey =
|
|
12
|
+
* await client.beta.organization.apiKeys.retrieve(
|
|
13
|
+
* 'api_key_id',
|
|
14
|
+
* );
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
retrieve(apiKeyID: string, options?: RequestOptions): APIPromise<BetaAPIKey>;
|
|
18
|
+
/**
|
|
19
|
+
* Update API Key
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* ```ts
|
|
23
|
+
* const betaAPIKey =
|
|
24
|
+
* await client.beta.organization.apiKeys.update(
|
|
25
|
+
* 'api_key_id',
|
|
26
|
+
* );
|
|
27
|
+
* ```
|
|
28
|
+
*/
|
|
29
|
+
update(apiKeyID: string, body: APIKeyUpdateParams, options?: RequestOptions): APIPromise<BetaAPIKey>;
|
|
30
|
+
/**
|
|
31
|
+
* List API Keys
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```ts
|
|
35
|
+
* // Automatically fetches more pages as needed.
|
|
36
|
+
* for await (const betaAPIKey of client.beta.organization.apiKeys.list()) {
|
|
37
|
+
* // ...
|
|
38
|
+
* }
|
|
39
|
+
* ```
|
|
40
|
+
*/
|
|
41
|
+
list(query?: APIKeyListParams | null | undefined, options?: RequestOptions): PagePromise<BetaAPIKeysPage, BetaAPIKey>;
|
|
42
|
+
}
|
|
43
|
+
export type BetaAPIKeysPage = Page<BetaAPIKey>;
|
|
44
|
+
export interface BetaAPIKey {
|
|
45
|
+
/**
|
|
46
|
+
* ID of the API key.
|
|
47
|
+
*/
|
|
48
|
+
id: string;
|
|
49
|
+
/**
|
|
50
|
+
* RFC 3339 datetime string indicating when the API Key was created.
|
|
51
|
+
*/
|
|
52
|
+
created_at: string;
|
|
53
|
+
/**
|
|
54
|
+
* The ID and type of the actor that created the API key, or `null` when the
|
|
55
|
+
* creator is not recorded (legacy, workload-identity-federated, or system-created
|
|
56
|
+
* keys).
|
|
57
|
+
*/
|
|
58
|
+
created_by: BetaAPIKeyCreatedBy | null;
|
|
59
|
+
/**
|
|
60
|
+
* RFC 3339 datetime string indicating when the API Key expires, or `null` if it
|
|
61
|
+
* never expires.
|
|
62
|
+
*/
|
|
63
|
+
expires_at: string | null;
|
|
64
|
+
/**
|
|
65
|
+
* Name of the API key.
|
|
66
|
+
*/
|
|
67
|
+
name: string;
|
|
68
|
+
/**
|
|
69
|
+
* Partially redacted hint for the API key.
|
|
70
|
+
*/
|
|
71
|
+
partial_key_hint: string | null;
|
|
72
|
+
/**
|
|
73
|
+
* The principal the API key acts as (a User or a Service Account), or `null` if
|
|
74
|
+
* the API key is not bound to a principal.
|
|
75
|
+
*/
|
|
76
|
+
principal: BetaAPIKeyUserActor | BetaAPIKeyServiceAccountActor | null;
|
|
77
|
+
/**
|
|
78
|
+
* Where the API key belongs: its Workspace
|
|
79
|
+
* (`{"type": "workspace", "workspace_id": "wrkspc_..."}`, with the Workspace's
|
|
80
|
+
* real ID even when it is the organization's default Workspace), or the
|
|
81
|
+
* organization (`{"type": "organization"}`) for a principal-bound API key that has
|
|
82
|
+
* no Workspace.
|
|
83
|
+
*/
|
|
84
|
+
scope: BetaAPIKeyOrganizationScope | BetaAPIKeyWorkspaceScope;
|
|
85
|
+
/**
|
|
86
|
+
* Status of the API key.
|
|
87
|
+
*/
|
|
88
|
+
status: 'active' | 'archived' | 'expired' | 'inactive';
|
|
89
|
+
/**
|
|
90
|
+
* Object type.
|
|
91
|
+
*
|
|
92
|
+
* For API Keys, this is always `"api_key"`.
|
|
93
|
+
*/
|
|
94
|
+
type: 'api_key';
|
|
95
|
+
/**
|
|
96
|
+
* @deprecated Use `scope` instead. `workspace_id` is `null` both for an API key in
|
|
97
|
+
* the default Workspace and for a principal-bound API key that has no Workspace.
|
|
98
|
+
*/
|
|
99
|
+
workspace_id: string | null;
|
|
100
|
+
}
|
|
101
|
+
export interface BetaAPIKeyCreatedBy {
|
|
102
|
+
/**
|
|
103
|
+
* ID of the actor that created the object.
|
|
104
|
+
*/
|
|
105
|
+
id: string;
|
|
106
|
+
/**
|
|
107
|
+
* Type of the actor that created the object.
|
|
108
|
+
*/
|
|
109
|
+
type: 'service_account' | 'user';
|
|
110
|
+
}
|
|
111
|
+
export interface BetaAPIKeyOrganizationScope {
|
|
112
|
+
/**
|
|
113
|
+
* Scope type. Always `"organization"`: the API key has no Workspace. Only a
|
|
114
|
+
* principal-bound API key can have this scope.
|
|
115
|
+
*/
|
|
116
|
+
type: 'organization';
|
|
117
|
+
}
|
|
118
|
+
export interface BetaAPIKeyServiceAccountActor {
|
|
119
|
+
/**
|
|
120
|
+
* ID of the Service Account the API key acts as.
|
|
121
|
+
*/
|
|
122
|
+
service_account_id: string;
|
|
123
|
+
/**
|
|
124
|
+
* Principal type. Always `"service_account_actor"` for a Service Account.
|
|
125
|
+
*/
|
|
126
|
+
type: 'service_account_actor';
|
|
127
|
+
}
|
|
128
|
+
export interface BetaAPIKeyUserActor {
|
|
129
|
+
/**
|
|
130
|
+
* Principal type. Always `"user_actor"` for a User.
|
|
131
|
+
*/
|
|
132
|
+
type: 'user_actor';
|
|
133
|
+
/**
|
|
134
|
+
* ID of the User the API key acts as.
|
|
135
|
+
*/
|
|
136
|
+
user_id: string;
|
|
137
|
+
}
|
|
138
|
+
export interface BetaAPIKeyWorkspaceScope {
|
|
139
|
+
/**
|
|
140
|
+
* Scope type. Always `"workspace"`: the API key belongs to one Workspace.
|
|
141
|
+
*/
|
|
142
|
+
type: 'workspace';
|
|
143
|
+
/**
|
|
144
|
+
* ID of the Workspace the API key belongs to. Unlike the deprecated top-level
|
|
145
|
+
* `workspace_id`, this is the Workspace's real ID even for the organization's
|
|
146
|
+
* default Workspace.
|
|
147
|
+
*/
|
|
148
|
+
workspace_id: string;
|
|
149
|
+
}
|
|
150
|
+
export interface APIKeyUpdateParams {
|
|
151
|
+
/**
|
|
152
|
+
* Name of the API key.
|
|
153
|
+
*/
|
|
154
|
+
name?: string | null;
|
|
155
|
+
/**
|
|
156
|
+
* Status of the API key.
|
|
157
|
+
*/
|
|
158
|
+
status?: 'active' | 'archived' | 'inactive' | null;
|
|
159
|
+
}
|
|
160
|
+
export interface APIKeyListParams extends PageParams {
|
|
161
|
+
/**
|
|
162
|
+
* Filter by the ID of the User who created the object.
|
|
163
|
+
*/
|
|
164
|
+
created_by_user_id?: string | null;
|
|
165
|
+
/**
|
|
166
|
+
* Filter by API key status.
|
|
167
|
+
*/
|
|
168
|
+
status?: 'active' | 'archived' | 'expired' | 'inactive' | null;
|
|
169
|
+
/**
|
|
170
|
+
* Filter by Workspace ID.
|
|
171
|
+
*/
|
|
172
|
+
workspace_id?: string | null;
|
|
173
|
+
}
|
|
174
|
+
export declare namespace APIKeys {
|
|
175
|
+
export { type BetaAPIKey as BetaAPIKey, type BetaAPIKeyCreatedBy as BetaAPIKeyCreatedBy, type BetaAPIKeyOrganizationScope as BetaAPIKeyOrganizationScope, type BetaAPIKeyServiceAccountActor as BetaAPIKeyServiceAccountActor, type BetaAPIKeyUserActor as BetaAPIKeyUserActor, type BetaAPIKeyWorkspaceScope as BetaAPIKeyWorkspaceScope, type BetaAPIKeysPage as BetaAPIKeysPage, type APIKeyUpdateParams as APIKeyUpdateParams, type APIKeyListParams as APIKeyListParams, };
|
|
176
|
+
}
|
|
177
|
+
//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IACH,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC9B;AAED,MAAM,CAAC,OAAO,WAAW,OAAO,CAAC;IAC/B,OAAO,EACL,KAAK,UAAU,IAAI,UAAU,EAC7B,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,6BAA6B,IAAI,6BAA6B,EACnE,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,eAAe,IAAI,eAAe,EACvC,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,gBAAgB,IAAI,gBAAgB,GAC1C,CAAC;CACH"}
|
|
@@ -0,0 +1,56 @@
|
|
|
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.APIKeys = void 0;
|
|
5
|
+
const resource_1 = require("../../../core/resource.js");
|
|
6
|
+
const pagination_1 = require("../../../core/pagination.js");
|
|
7
|
+
const path_1 = require("../../../internal/utils/path.js");
|
|
8
|
+
class APIKeys extends resource_1.APIResource {
|
|
9
|
+
/**
|
|
10
|
+
* Get API Key
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```ts
|
|
14
|
+
* const betaAPIKey =
|
|
15
|
+
* await client.beta.organization.apiKeys.retrieve(
|
|
16
|
+
* 'api_key_id',
|
|
17
|
+
* );
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
retrieve(apiKeyID, options) {
|
|
21
|
+
return this._client.get((0, path_1.path) `/v1/organizations/api_keys/${apiKeyID}?beta=true`, options);
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Update API Key
|
|
25
|
+
*
|
|
26
|
+
* @example
|
|
27
|
+
* ```ts
|
|
28
|
+
* const betaAPIKey =
|
|
29
|
+
* await client.beta.organization.apiKeys.update(
|
|
30
|
+
* 'api_key_id',
|
|
31
|
+
* );
|
|
32
|
+
* ```
|
|
33
|
+
*/
|
|
34
|
+
update(apiKeyID, body, options) {
|
|
35
|
+
return this._client.post((0, path_1.path) `/v1/organizations/api_keys/${apiKeyID}?beta=true`, { body, ...options });
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* List API Keys
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* ```ts
|
|
42
|
+
* // Automatically fetches more pages as needed.
|
|
43
|
+
* for await (const betaAPIKey of client.beta.organization.apiKeys.list()) {
|
|
44
|
+
* // ...
|
|
45
|
+
* }
|
|
46
|
+
* ```
|
|
47
|
+
*/
|
|
48
|
+
list(query = {}, options) {
|
|
49
|
+
return this._client.getAPIList('/v1/organizations/api_keys?beta=true', (pagination_1.Page), {
|
|
50
|
+
query,
|
|
51
|
+
...options,
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
exports.APIKeys = APIKeys;
|
|
56
|
+
//# sourceMappingURL=api-keys.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-keys.js","sourceRoot":"","sources":["../../../src/resources/beta/organization/api-keys.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAErD,4DAA8E;AAE9E,0DAAoD;AAEpD,MAAa,OAAQ,SAAQ,sBAAW;IACtC;;;;;;;;;;OAUG;IACH,QAAQ,CAAC,QAAgB,EAAE,OAAwB;QACjD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,8BAA8B,QAAQ,YAAY,EAAE,OAAO,CAAC,CAAC;IAC3F,CAAC;IAED;;;;;;;;;;OAUG;IACH,MAAM,CAAC,QAAgB,EAAE,IAAwB,EAAE,OAAwB;QACzE,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAA,WAAI,EAAA,8BAA8B,QAAQ,YAAY,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACzG,CAAC;IAED;;;;;;;;;;OAUG;IACH,IAAI,CACF,QAA6C,EAAE,EAC/C,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,sCAAsC,EAAE,CAAA,iBAAgB,CAAA,EAAE;YACvF,KAAK;YACL,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;CACF;AAnDD,0BAmDC"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
3
|
+
import { Page } from "../../../core/pagination.mjs";
|
|
4
|
+
import { path } from "../../../internal/utils/path.mjs";
|
|
5
|
+
export class APIKeys extends APIResource {
|
|
6
|
+
/**
|
|
7
|
+
* Get API Key
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```ts
|
|
11
|
+
* const betaAPIKey =
|
|
12
|
+
* await client.beta.organization.apiKeys.retrieve(
|
|
13
|
+
* 'api_key_id',
|
|
14
|
+
* );
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
retrieve(apiKeyID, options) {
|
|
18
|
+
return this._client.get(path `/v1/organizations/api_keys/${apiKeyID}?beta=true`, options);
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Update API Key
|
|
22
|
+
*
|
|
23
|
+
* @example
|
|
24
|
+
* ```ts
|
|
25
|
+
* const betaAPIKey =
|
|
26
|
+
* await client.beta.organization.apiKeys.update(
|
|
27
|
+
* 'api_key_id',
|
|
28
|
+
* );
|
|
29
|
+
* ```
|
|
30
|
+
*/
|
|
31
|
+
update(apiKeyID, body, options) {
|
|
32
|
+
return this._client.post(path `/v1/organizations/api_keys/${apiKeyID}?beta=true`, { body, ...options });
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* List API Keys
|
|
36
|
+
*
|
|
37
|
+
* @example
|
|
38
|
+
* ```ts
|
|
39
|
+
* // Automatically fetches more pages as needed.
|
|
40
|
+
* for await (const betaAPIKey of client.beta.organization.apiKeys.list()) {
|
|
41
|
+
* // ...
|
|
42
|
+
* }
|
|
43
|
+
* ```
|
|
44
|
+
*/
|
|
45
|
+
list(query = {}, options) {
|
|
46
|
+
return this._client.getAPIList('/v1/organizations/api_keys?beta=true', (Page), {
|
|
47
|
+
query,
|
|
48
|
+
...options,
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
//# sourceMappingURL=api-keys.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-keys.mjs","sourceRoot":"","sources":["../../../src/resources/beta/organization/api-keys.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,mCAA+B;AAErD,OAAO,EAAE,IAAI,EAAgC,qCAAiC;AAE9E,OAAO,EAAE,IAAI,EAAE,yCAAqC;AAEpD,MAAM,OAAO,OAAQ,SAAQ,WAAW;IACtC;;;;;;;;;;OAUG;IACH,QAAQ,CAAC,QAAgB,EAAE,OAAwB;QACjD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,8BAA8B,QAAQ,YAAY,EAAE,OAAO,CAAC,CAAC;IAC3F,CAAC;IAED;;;;;;;;;;OAUG;IACH,MAAM,CAAC,QAAgB,EAAE,IAAwB,EAAE,OAAwB;QACzE,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAA,8BAA8B,QAAQ,YAAY,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACzG,CAAC;IAED;;;;;;;;;;OAUG;IACH,IAAI,CACF,QAA6C,EAAE,EAC/C,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,sCAAsC,EAAE,CAAA,IAAgB,CAAA,EAAE;YACvF,KAAK;YACL,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;CACF"}
|