openai 7.19.0 → 7.20.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 +16 -0
- package/package.json +1 -1
- package/resources/admin/organization/admin-api-keys.d.mts +8 -1
- package/resources/admin/organization/admin-api-keys.d.mts.map +1 -1
- package/resources/admin/organization/admin-api-keys.d.ts +8 -1
- package/resources/admin/organization/admin-api-keys.d.ts.map +1 -1
- package/resources/admin/organization/admin-api-keys.js +58 -11
- package/resources/admin/organization/admin-api-keys.js.map +1 -1
- package/resources/admin/organization/admin-api-keys.mjs +58 -11
- package/resources/admin/organization/admin-api-keys.mjs.map +1 -1
- package/resources/admin/organization/audit-logs.d.mts +56 -3
- package/resources/admin/organization/audit-logs.d.mts.map +1 -1
- package/resources/admin/organization/audit-logs.d.ts +56 -3
- package/resources/admin/organization/audit-logs.d.ts.map +1 -1
- package/resources/admin/organization/audit-logs.js +69 -11
- package/resources/admin/organization/audit-logs.js.map +1 -1
- package/resources/admin/organization/audit-logs.mjs +69 -11
- package/resources/admin/organization/audit-logs.mjs.map +1 -1
- package/resources/admin/organization/certificates.d.mts +16 -2
- package/resources/admin/organization/certificates.d.mts.map +1 -1
- package/resources/admin/organization/certificates.d.ts +16 -2
- package/resources/admin/organization/certificates.d.ts.map +1 -1
- package/resources/admin/organization/certificates.js +64 -24
- package/resources/admin/organization/certificates.js.map +1 -1
- package/resources/admin/organization/certificates.mjs +64 -24
- package/resources/admin/organization/certificates.mjs.map +1 -1
- package/resources/admin/organization/external-storage.d.mts +141 -0
- package/resources/admin/organization/external-storage.d.mts.map +1 -0
- package/resources/admin/organization/external-storage.d.ts +141 -0
- package/resources/admin/organization/external-storage.d.ts.map +1 -0
- package/resources/admin/organization/external-storage.js +146 -0
- package/resources/admin/organization/external-storage.js.map +1 -0
- package/resources/admin/organization/external-storage.mjs +142 -0
- package/resources/admin/organization/external-storage.mjs.map +1 -0
- package/resources/admin/organization/groups/groups.d.mts +8 -1
- package/resources/admin/organization/groups/groups.d.mts.map +1 -1
- package/resources/admin/organization/groups/groups.d.ts +8 -1
- package/resources/admin/organization/groups/groups.d.ts.map +1 -1
- package/resources/admin/organization/groups/groups.js +58 -11
- package/resources/admin/organization/groups/groups.js.map +1 -1
- package/resources/admin/organization/groups/groups.mjs +58 -11
- package/resources/admin/organization/groups/groups.mjs.map +1 -1
- package/resources/admin/organization/groups/roles.d.mts +8 -1
- package/resources/admin/organization/groups/roles.d.mts.map +1 -1
- package/resources/admin/organization/groups/roles.d.ts +8 -1
- package/resources/admin/organization/groups/roles.d.ts.map +1 -1
- package/resources/admin/organization/groups/roles.js +58 -13
- package/resources/admin/organization/groups/roles.js.map +1 -1
- package/resources/admin/organization/groups/roles.mjs +58 -13
- package/resources/admin/organization/groups/roles.mjs.map +1 -1
- package/resources/admin/organization/groups/users.d.mts +8 -1
- package/resources/admin/organization/groups/users.d.mts.map +1 -1
- package/resources/admin/organization/groups/users.d.ts +8 -1
- package/resources/admin/organization/groups/users.d.ts.map +1 -1
- package/resources/admin/organization/groups/users.js +58 -13
- package/resources/admin/organization/groups/users.js.map +1 -1
- package/resources/admin/organization/groups/users.mjs +58 -13
- package/resources/admin/organization/groups/users.mjs.map +1 -1
- package/resources/admin/organization/index.d.mts +1 -0
- package/resources/admin/organization/index.d.mts.map +1 -1
- package/resources/admin/organization/index.d.ts +1 -0
- package/resources/admin/organization/index.d.ts.map +1 -1
- package/resources/admin/organization/index.js +3 -1
- package/resources/admin/organization/index.js.map +1 -1
- package/resources/admin/organization/index.mjs +1 -0
- package/resources/admin/organization/index.mjs.map +1 -1
- package/resources/admin/organization/invites.d.mts +8 -1
- package/resources/admin/organization/invites.d.mts.map +1 -1
- package/resources/admin/organization/invites.d.ts +8 -1
- package/resources/admin/organization/invites.d.ts.map +1 -1
- package/resources/admin/organization/invites.js +58 -11
- package/resources/admin/organization/invites.js.map +1 -1
- package/resources/admin/organization/invites.mjs +58 -11
- package/resources/admin/organization/invites.mjs.map +1 -1
- package/resources/admin/organization/organization.d.mts +4 -0
- package/resources/admin/organization/organization.d.mts.map +1 -1
- package/resources/admin/organization/organization.d.ts +4 -0
- package/resources/admin/organization/organization.d.ts.map +1 -1
- package/resources/admin/organization/organization.js +4 -0
- package/resources/admin/organization/organization.js.map +1 -1
- package/resources/admin/organization/organization.mjs +4 -0
- package/resources/admin/organization/organization.mjs.map +1 -1
- package/resources/admin/organization/projects/api-keys.d.mts +8 -1
- package/resources/admin/organization/projects/api-keys.d.mts.map +1 -1
- package/resources/admin/organization/projects/api-keys.d.ts +8 -1
- package/resources/admin/organization/projects/api-keys.d.ts.map +1 -1
- package/resources/admin/organization/projects/api-keys.js +58 -13
- package/resources/admin/organization/projects/api-keys.js.map +1 -1
- package/resources/admin/organization/projects/api-keys.mjs +58 -13
- package/resources/admin/organization/projects/api-keys.mjs.map +1 -1
- package/resources/admin/organization/projects/certificates.d.mts +8 -1
- package/resources/admin/organization/projects/certificates.d.mts.map +1 -1
- package/resources/admin/organization/projects/certificates.d.ts +8 -1
- package/resources/admin/organization/projects/certificates.d.ts.map +1 -1
- package/resources/admin/organization/projects/certificates.js +58 -13
- package/resources/admin/organization/projects/certificates.js.map +1 -1
- package/resources/admin/organization/projects/certificates.mjs +58 -13
- package/resources/admin/organization/projects/certificates.mjs.map +1 -1
- package/resources/admin/organization/projects/groups/groups.d.mts +8 -1
- package/resources/admin/organization/projects/groups/groups.d.mts.map +1 -1
- package/resources/admin/organization/projects/groups/groups.d.ts +8 -1
- package/resources/admin/organization/projects/groups/groups.d.ts.map +1 -1
- package/resources/admin/organization/projects/groups/groups.js +58 -13
- package/resources/admin/organization/projects/groups/groups.js.map +1 -1
- package/resources/admin/organization/projects/groups/groups.mjs +58 -13
- package/resources/admin/organization/projects/groups/groups.mjs.map +1 -1
- package/resources/admin/organization/projects/projects.d.mts +8 -1
- package/resources/admin/organization/projects/projects.d.mts.map +1 -1
- package/resources/admin/organization/projects/projects.d.ts +8 -1
- package/resources/admin/organization/projects/projects.d.ts.map +1 -1
- package/resources/admin/organization/projects/projects.js +58 -11
- package/resources/admin/organization/projects/projects.js.map +1 -1
- package/resources/admin/organization/projects/projects.mjs +58 -11
- package/resources/admin/organization/projects/projects.mjs.map +1 -1
- package/resources/admin/organization/projects/rate-limits.d.mts +8 -1
- package/resources/admin/organization/projects/rate-limits.d.mts.map +1 -1
- package/resources/admin/organization/projects/rate-limits.d.ts +8 -1
- package/resources/admin/organization/projects/rate-limits.d.ts.map +1 -1
- package/resources/admin/organization/projects/rate-limits.js +58 -13
- package/resources/admin/organization/projects/rate-limits.js.map +1 -1
- package/resources/admin/organization/projects/rate-limits.mjs +58 -13
- package/resources/admin/organization/projects/rate-limits.mjs.map +1 -1
- package/resources/admin/organization/projects/roles.d.mts +8 -1
- package/resources/admin/organization/projects/roles.d.mts.map +1 -1
- package/resources/admin/organization/projects/roles.d.ts +8 -1
- package/resources/admin/organization/projects/roles.d.ts.map +1 -1
- package/resources/admin/organization/projects/roles.js +58 -13
- package/resources/admin/organization/projects/roles.js.map +1 -1
- package/resources/admin/organization/projects/roles.mjs +58 -13
- package/resources/admin/organization/projects/roles.mjs.map +1 -1
- package/resources/admin/organization/projects/service-accounts/service-accounts.d.mts +8 -1
- package/resources/admin/organization/projects/service-accounts/service-accounts.d.mts.map +1 -1
- package/resources/admin/organization/projects/service-accounts/service-accounts.d.ts +8 -1
- package/resources/admin/organization/projects/service-accounts/service-accounts.d.ts.map +1 -1
- package/resources/admin/organization/projects/service-accounts/service-accounts.js +58 -13
- package/resources/admin/organization/projects/service-accounts/service-accounts.js.map +1 -1
- package/resources/admin/organization/projects/service-accounts/service-accounts.mjs +58 -13
- package/resources/admin/organization/projects/service-accounts/service-accounts.mjs.map +1 -1
- package/resources/admin/organization/projects/spend-alerts.d.mts +8 -1
- package/resources/admin/organization/projects/spend-alerts.d.mts.map +1 -1
- package/resources/admin/organization/projects/spend-alerts.d.ts +8 -1
- package/resources/admin/organization/projects/spend-alerts.d.ts.map +1 -1
- package/resources/admin/organization/projects/spend-alerts.js +58 -13
- package/resources/admin/organization/projects/spend-alerts.js.map +1 -1
- package/resources/admin/organization/projects/spend-alerts.mjs +58 -13
- package/resources/admin/organization/projects/spend-alerts.mjs.map +1 -1
- package/resources/admin/organization/projects/users/users.d.mts +8 -1
- package/resources/admin/organization/projects/users/users.d.mts.map +1 -1
- package/resources/admin/organization/projects/users/users.d.ts +8 -1
- package/resources/admin/organization/projects/users/users.d.ts.map +1 -1
- package/resources/admin/organization/projects/users/users.js +58 -13
- package/resources/admin/organization/projects/users/users.js.map +1 -1
- package/resources/admin/organization/projects/users/users.mjs +58 -13
- package/resources/admin/organization/projects/users/users.mjs.map +1 -1
- package/resources/admin/organization/roles.d.mts +8 -1
- package/resources/admin/organization/roles.d.mts.map +1 -1
- package/resources/admin/organization/roles.d.ts +8 -1
- package/resources/admin/organization/roles.d.ts.map +1 -1
- package/resources/admin/organization/roles.js +58 -11
- package/resources/admin/organization/roles.js.map +1 -1
- package/resources/admin/organization/roles.mjs +58 -11
- package/resources/admin/organization/roles.mjs.map +1 -1
- package/resources/admin/organization/spend-alerts.d.mts +8 -1
- package/resources/admin/organization/spend-alerts.d.mts.map +1 -1
- package/resources/admin/organization/spend-alerts.d.ts +8 -1
- package/resources/admin/organization/spend-alerts.d.ts.map +1 -1
- package/resources/admin/organization/spend-alerts.js +58 -11
- package/resources/admin/organization/spend-alerts.js.map +1 -1
- package/resources/admin/organization/spend-alerts.mjs +58 -11
- package/resources/admin/organization/spend-alerts.mjs.map +1 -1
- package/resources/admin/organization/users/roles.d.mts +8 -1
- package/resources/admin/organization/users/roles.d.mts.map +1 -1
- package/resources/admin/organization/users/roles.d.ts +8 -1
- package/resources/admin/organization/users/roles.d.ts.map +1 -1
- package/resources/admin/organization/users/roles.js +58 -13
- package/resources/admin/organization/users/roles.js.map +1 -1
- package/resources/admin/organization/users/roles.mjs +58 -13
- package/resources/admin/organization/users/roles.mjs.map +1 -1
- package/resources/admin/organization/users/users.d.mts +8 -1
- package/resources/admin/organization/users/users.d.mts.map +1 -1
- package/resources/admin/organization/users/users.d.ts +8 -1
- package/resources/admin/organization/users/users.d.ts.map +1 -1
- package/resources/admin/organization/users/users.js +58 -11
- package/resources/admin/organization/users/users.js.map +1 -1
- package/resources/admin/organization/users/users.mjs +58 -11
- package/resources/admin/organization/users/users.mjs.map +1 -1
- package/resources/batches.d.mts +8 -1
- package/resources/batches.d.mts.map +1 -1
- package/resources/batches.d.ts +8 -1
- package/resources/batches.d.ts.map +1 -1
- package/resources/batches.js +58 -3
- package/resources/batches.js.map +1 -1
- package/resources/batches.mjs +58 -3
- package/resources/batches.mjs.map +1 -1
- package/resources/beta/agents/agents.d.mts +61 -43
- package/resources/beta/agents/agents.d.mts.map +1 -1
- package/resources/beta/agents/agents.d.ts +61 -43
- package/resources/beta/agents/agents.d.ts.map +1 -1
- package/resources/beta/agents/agents.js +58 -12
- package/resources/beta/agents/agents.js.map +1 -1
- package/resources/beta/agents/agents.mjs +58 -12
- package/resources/beta/agents/agents.mjs.map +1 -1
- package/resources/beta/agents/environments/templates.d.mts +22 -9
- package/resources/beta/agents/environments/templates.d.mts.map +1 -1
- package/resources/beta/agents/environments/templates.d.ts +22 -9
- package/resources/beta/agents/environments/templates.d.ts.map +1 -1
- package/resources/beta/agents/environments/templates.js +58 -12
- package/resources/beta/agents/environments/templates.js.map +1 -1
- package/resources/beta/agents/environments/templates.mjs +58 -12
- package/resources/beta/agents/environments/templates.mjs.map +1 -1
- package/resources/beta/agents/sessions/artifacts.d.mts +8 -1
- package/resources/beta/agents/sessions/artifacts.d.mts.map +1 -1
- package/resources/beta/agents/sessions/artifacts.d.ts +8 -1
- package/resources/beta/agents/sessions/artifacts.d.ts.map +1 -1
- package/resources/beta/agents/sessions/artifacts.js +58 -14
- package/resources/beta/agents/sessions/artifacts.js.map +1 -1
- package/resources/beta/agents/sessions/artifacts.mjs +58 -14
- package/resources/beta/agents/sessions/artifacts.mjs.map +1 -1
- package/resources/beta/agents/sessions/items.d.mts +8 -1
- package/resources/beta/agents/sessions/items.d.mts.map +1 -1
- package/resources/beta/agents/sessions/items.d.ts +8 -1
- package/resources/beta/agents/sessions/items.d.ts.map +1 -1
- package/resources/beta/agents/sessions/items.js +58 -15
- package/resources/beta/agents/sessions/items.js.map +1 -1
- package/resources/beta/agents/sessions/items.mjs +58 -15
- package/resources/beta/agents/sessions/items.mjs.map +1 -1
- package/resources/beta/agents/sessions/sessions.d.mts +17 -6
- package/resources/beta/agents/sessions/sessions.d.mts.map +1 -1
- package/resources/beta/agents/sessions/sessions.d.ts +17 -6
- package/resources/beta/agents/sessions/sessions.d.ts.map +1 -1
- package/resources/beta/agents/sessions/sessions.js +58 -13
- package/resources/beta/agents/sessions/sessions.js.map +1 -1
- package/resources/beta/agents/sessions/sessions.mjs +58 -13
- package/resources/beta/agents/sessions/sessions.mjs.map +1 -1
- package/resources/beta/agents/sessions/subagents/subagents.d.mts +8 -1
- package/resources/beta/agents/sessions/subagents/subagents.d.mts.map +1 -1
- package/resources/beta/agents/sessions/subagents/subagents.d.ts +8 -1
- package/resources/beta/agents/sessions/subagents/subagents.d.ts.map +1 -1
- package/resources/beta/agents/sessions/subagents/subagents.js +58 -14
- package/resources/beta/agents/sessions/subagents/subagents.js.map +1 -1
- package/resources/beta/agents/sessions/subagents/subagents.mjs +58 -14
- package/resources/beta/agents/sessions/subagents/subagents.mjs.map +1 -1
- package/resources/beta/agents/sessions/turns.d.mts +11 -3
- package/resources/beta/agents/sessions/turns.d.mts.map +1 -1
- package/resources/beta/agents/sessions/turns.d.ts +11 -3
- package/resources/beta/agents/sessions/turns.d.ts.map +1 -1
- package/resources/beta/agents/sessions/turns.js +58 -15
- package/resources/beta/agents/sessions/turns.js.map +1 -1
- package/resources/beta/agents/sessions/turns.mjs +58 -15
- package/resources/beta/agents/sessions/turns.mjs.map +1 -1
- package/resources/beta/agents/vaults/credentials.d.mts +163 -23
- package/resources/beta/agents/vaults/credentials.d.mts.map +1 -1
- package/resources/beta/agents/vaults/credentials.d.ts +163 -23
- package/resources/beta/agents/vaults/credentials.d.ts.map +1 -1
- package/resources/beta/agents/vaults/credentials.js +58 -15
- package/resources/beta/agents/vaults/credentials.js.map +1 -1
- package/resources/beta/agents/vaults/credentials.mjs +58 -15
- package/resources/beta/agents/vaults/credentials.mjs.map +1 -1
- package/resources/beta/agents/vaults/index.d.mts +1 -1
- package/resources/beta/agents/vaults/index.d.mts.map +1 -1
- package/resources/beta/agents/vaults/index.d.ts +1 -1
- package/resources/beta/agents/vaults/index.d.ts.map +1 -1
- package/resources/beta/agents/vaults/index.js.map +1 -1
- package/resources/beta/agents/vaults/index.mjs.map +1 -1
- package/resources/beta/agents/vaults/vaults.d.mts +11 -5
- package/resources/beta/agents/vaults/vaults.d.mts.map +1 -1
- package/resources/beta/agents/vaults/vaults.d.ts +11 -5
- package/resources/beta/agents/vaults/vaults.d.ts.map +1 -1
- package/resources/beta/agents/vaults/vaults.js +58 -12
- package/resources/beta/agents/vaults/vaults.js.map +1 -1
- package/resources/beta/agents/vaults/vaults.mjs +58 -12
- package/resources/beta/agents/vaults/vaults.mjs.map +1 -1
- package/resources/beta/assistants.d.mts +8 -1
- package/resources/beta/assistants.d.mts.map +1 -1
- package/resources/beta/assistants.d.ts +8 -1
- package/resources/beta/assistants.d.ts.map +1 -1
- package/resources/beta/assistants.js +58 -5
- package/resources/beta/assistants.js.map +1 -1
- package/resources/beta/assistants.mjs +58 -5
- package/resources/beta/assistants.mjs.map +1 -1
- package/resources/beta/chatkit/threads.d.mts +16 -2
- package/resources/beta/chatkit/threads.d.mts.map +1 -1
- package/resources/beta/chatkit/threads.d.ts +16 -2
- package/resources/beta/chatkit/threads.d.ts.map +1 -1
- package/resources/beta/chatkit/threads.js +64 -24
- package/resources/beta/chatkit/threads.js.map +1 -1
- package/resources/beta/chatkit/threads.mjs +64 -24
- package/resources/beta/chatkit/threads.mjs.map +1 -1
- package/resources/beta/responses/responses.d.mts +4 -5
- package/resources/beta/responses/responses.d.mts.map +1 -1
- package/resources/beta/responses/responses.d.ts +4 -5
- package/resources/beta/responses/responses.d.ts.map +1 -1
- package/resources/beta/responses/responses.js.map +1 -1
- package/resources/beta/responses/responses.mjs.map +1 -1
- package/resources/beta/threads/messages.d.mts +8 -1
- package/resources/beta/threads/messages.d.mts.map +1 -1
- package/resources/beta/threads/messages.d.ts +8 -1
- package/resources/beta/threads/messages.d.ts.map +1 -1
- package/resources/beta/threads/messages.js +58 -5
- package/resources/beta/threads/messages.js.map +1 -1
- package/resources/beta/threads/messages.mjs +58 -5
- package/resources/beta/threads/messages.mjs.map +1 -1
- package/resources/beta/threads/runs/runs.d.mts +8 -1
- package/resources/beta/threads/runs/runs.d.mts.map +1 -1
- package/resources/beta/threads/runs/runs.d.ts +8 -1
- package/resources/beta/threads/runs/runs.d.ts.map +1 -1
- package/resources/beta/threads/runs/runs.js +58 -5
- package/resources/beta/threads/runs/runs.js.map +1 -1
- package/resources/beta/threads/runs/runs.mjs +58 -5
- package/resources/beta/threads/runs/runs.mjs.map +1 -1
- package/resources/chat/completions/completions.d.mts +13 -3
- package/resources/chat/completions/completions.d.mts.map +1 -1
- package/resources/chat/completions/completions.d.ts +13 -3
- package/resources/chat/completions/completions.d.ts.map +1 -1
- package/resources/chat/completions/completions.js +58 -12
- package/resources/chat/completions/completions.js.map +1 -1
- package/resources/chat/completions/completions.mjs +58 -12
- package/resources/chat/completions/completions.mjs.map +1 -1
- package/resources/chat/completions/messages.d.mts +8 -1
- package/resources/chat/completions/messages.d.mts.map +1 -1
- package/resources/chat/completions/messages.d.ts +8 -1
- package/resources/chat/completions/messages.d.ts.map +1 -1
- package/resources/chat/completions/messages.js +58 -14
- package/resources/chat/completions/messages.js.map +1 -1
- package/resources/chat/completions/messages.mjs +58 -14
- package/resources/chat/completions/messages.mjs.map +1 -1
- package/resources/containers/containers.d.mts +8 -1
- package/resources/containers/containers.d.mts.map +1 -1
- package/resources/containers/containers.d.ts +8 -1
- package/resources/containers/containers.d.ts.map +1 -1
- package/resources/containers/containers.js +58 -3
- package/resources/containers/containers.js.map +1 -1
- package/resources/containers/containers.mjs +58 -3
- package/resources/containers/containers.mjs.map +1 -1
- package/resources/containers/files/files.d.mts +8 -1
- package/resources/containers/files/files.d.mts.map +1 -1
- package/resources/containers/files/files.d.ts +8 -1
- package/resources/containers/files/files.d.ts.map +1 -1
- package/resources/containers/files/files.js +58 -3
- package/resources/containers/files/files.js.map +1 -1
- package/resources/containers/files/files.mjs +58 -3
- package/resources/containers/files/files.mjs.map +1 -1
- package/resources/conversations/conversations.d.mts +3 -4
- package/resources/conversations/conversations.d.mts.map +1 -1
- package/resources/conversations/conversations.d.ts +3 -4
- package/resources/conversations/conversations.d.ts.map +1 -1
- package/resources/conversations/conversations.js.map +1 -1
- package/resources/conversations/conversations.mjs.map +1 -1
- package/resources/conversations/items.d.mts +8 -1
- package/resources/conversations/items.d.mts.map +1 -1
- package/resources/conversations/items.d.ts +8 -1
- package/resources/conversations/items.d.ts.map +1 -1
- package/resources/conversations/items.js +58 -3
- package/resources/conversations/items.js.map +1 -1
- package/resources/conversations/items.mjs +58 -3
- package/resources/conversations/items.mjs.map +1 -1
- package/resources/evals/evals.d.mts +8 -1
- package/resources/evals/evals.d.mts.map +1 -1
- package/resources/evals/evals.d.ts +8 -1
- package/resources/evals/evals.d.ts.map +1 -1
- package/resources/evals/evals.js +58 -3
- package/resources/evals/evals.js.map +1 -1
- package/resources/evals/evals.mjs +58 -3
- package/resources/evals/evals.mjs.map +1 -1
- package/resources/evals/runs/runs.d.mts +8 -1
- package/resources/evals/runs/runs.d.mts.map +1 -1
- package/resources/evals/runs/runs.d.ts +8 -1
- package/resources/evals/runs/runs.d.ts.map +1 -1
- package/resources/evals/runs/runs.js +58 -3
- package/resources/evals/runs/runs.js.map +1 -1
- package/resources/evals/runs/runs.mjs +58 -3
- package/resources/evals/runs/runs.mjs.map +1 -1
- package/resources/files.d.mts +8 -1
- package/resources/files.d.mts.map +1 -1
- package/resources/files.d.ts +8 -1
- package/resources/files.d.ts.map +1 -1
- package/resources/files.js +58 -3
- package/resources/files.js.map +1 -1
- package/resources/files.mjs +58 -3
- package/resources/files.mjs.map +1 -1
- package/resources/fine-tuning/checkpoints/permissions.d.mts +16 -2
- package/resources/fine-tuning/checkpoints/permissions.d.mts.map +1 -1
- package/resources/fine-tuning/checkpoints/permissions.d.ts +16 -2
- package/resources/fine-tuning/checkpoints/permissions.d.ts.map +1 -1
- package/resources/fine-tuning/checkpoints/permissions.js +64 -26
- package/resources/fine-tuning/checkpoints/permissions.js.map +1 -1
- package/resources/fine-tuning/checkpoints/permissions.mjs +64 -26
- package/resources/fine-tuning/checkpoints/permissions.mjs.map +1 -1
- package/resources/fine-tuning/jobs/checkpoints.d.mts +8 -1
- package/resources/fine-tuning/jobs/checkpoints.d.mts.map +1 -1
- package/resources/fine-tuning/jobs/checkpoints.d.ts +8 -1
- package/resources/fine-tuning/jobs/checkpoints.d.ts.map +1 -1
- package/resources/fine-tuning/jobs/checkpoints.js +58 -13
- package/resources/fine-tuning/jobs/checkpoints.js.map +1 -1
- package/resources/fine-tuning/jobs/checkpoints.mjs +58 -13
- package/resources/fine-tuning/jobs/checkpoints.mjs.map +1 -1
- package/resources/fine-tuning/jobs/jobs.d.mts +16 -2
- package/resources/fine-tuning/jobs/jobs.d.mts.map +1 -1
- package/resources/fine-tuning/jobs/jobs.d.ts +16 -2
- package/resources/fine-tuning/jobs/jobs.d.ts.map +1 -1
- package/resources/fine-tuning/jobs/jobs.js +64 -24
- package/resources/fine-tuning/jobs/jobs.js.map +1 -1
- package/resources/fine-tuning/jobs/jobs.mjs +64 -24
- package/resources/fine-tuning/jobs/jobs.mjs.map +1 -1
- package/resources/images.d.mts +3 -4
- package/resources/images.d.mts.map +1 -1
- package/resources/images.d.ts +3 -4
- package/resources/images.d.ts.map +1 -1
- package/resources/responses/input-items.d.mts +8 -1
- package/resources/responses/input-items.d.mts.map +1 -1
- package/resources/responses/input-items.d.ts +8 -1
- package/resources/responses/input-items.d.ts.map +1 -1
- package/resources/responses/input-items.js +58 -13
- package/resources/responses/input-items.js.map +1 -1
- package/resources/responses/input-items.mjs +58 -13
- package/resources/responses/input-items.mjs.map +1 -1
- package/resources/responses/responses.d.mts +18 -8
- package/resources/responses/responses.d.mts.map +1 -1
- package/resources/responses/responses.d.ts +18 -8
- package/resources/responses/responses.d.ts.map +1 -1
- package/resources/responses/responses.js +58 -0
- package/resources/responses/responses.js.map +1 -1
- package/resources/responses/responses.mjs +58 -0
- package/resources/responses/responses.mjs.map +1 -1
- package/resources/safety/cases.d.mts +26 -0
- package/resources/safety/cases.d.mts.map +1 -0
- package/resources/safety/cases.d.ts +26 -0
- package/resources/safety/cases.d.ts.map +1 -0
- package/resources/safety/cases.js +16 -0
- package/resources/safety/cases.js.map +1 -0
- package/resources/safety/cases.mjs +12 -0
- package/resources/safety/cases.mjs.map +1 -0
- package/resources/safety/index.d.mts +1 -0
- package/resources/safety/index.d.mts.map +1 -1
- package/resources/safety/index.d.ts +1 -0
- package/resources/safety/index.d.ts.map +1 -1
- package/resources/safety/index.js +3 -1
- package/resources/safety/index.js.map +1 -1
- package/resources/safety/index.mjs +1 -0
- package/resources/safety/index.mjs.map +1 -1
- package/resources/safety/safety.d.mts +4 -0
- package/resources/safety/safety.d.mts.map +1 -1
- package/resources/safety/safety.d.ts +4 -0
- package/resources/safety/safety.d.ts.map +1 -1
- package/resources/safety/safety.js +4 -0
- package/resources/safety/safety.js.map +1 -1
- package/resources/safety/safety.mjs +4 -0
- package/resources/safety/safety.mjs.map +1 -1
- package/resources/skills/skills.d.mts +8 -1
- package/resources/skills/skills.d.mts.map +1 -1
- package/resources/skills/skills.d.ts +8 -1
- package/resources/skills/skills.d.ts.map +1 -1
- package/resources/skills/skills.js +58 -3
- package/resources/skills/skills.js.map +1 -1
- package/resources/skills/skills.mjs +58 -3
- package/resources/skills/skills.mjs.map +1 -1
- package/resources/skills/versions/versions.d.mts +8 -1
- package/resources/skills/versions/versions.d.mts.map +1 -1
- package/resources/skills/versions/versions.d.ts +8 -1
- package/resources/skills/versions/versions.d.ts.map +1 -1
- package/resources/skills/versions/versions.js +58 -3
- package/resources/skills/versions/versions.js.map +1 -1
- package/resources/skills/versions/versions.mjs +58 -3
- package/resources/skills/versions/versions.mjs.map +1 -1
- package/resources/vector-stores/files.d.mts +8 -1
- package/resources/vector-stores/files.d.mts.map +1 -1
- package/resources/vector-stores/files.d.ts +8 -1
- package/resources/vector-stores/files.d.ts.map +1 -1
- package/resources/vector-stores/files.js +58 -3
- package/resources/vector-stores/files.js.map +1 -1
- package/resources/vector-stores/files.mjs +58 -3
- package/resources/vector-stores/files.mjs.map +1 -1
- package/resources/vector-stores/vector-stores.d.mts +8 -1
- package/resources/vector-stores/vector-stores.d.mts.map +1 -1
- package/resources/vector-stores/vector-stores.d.ts +8 -1
- package/resources/vector-stores/vector-stores.d.ts.map +1 -1
- package/resources/vector-stores/vector-stores.js +58 -3
- package/resources/vector-stores/vector-stores.js.map +1 -1
- package/resources/vector-stores/vector-stores.mjs +58 -3
- package/resources/vector-stores/vector-stores.mjs.map +1 -1
- package/resources/videos.d.mts +16 -2
- package/resources/videos.d.mts.map +1 -1
- package/resources/videos.d.ts +16 -2
- package/resources/videos.d.ts.map +1 -1
- package/resources/videos.js +64 -12
- package/resources/videos.js.map +1 -1
- package/resources/videos.mjs +64 -12
- package/resources/videos.mjs.map +1 -1
- package/resources/webhooks/webhooks.d.mts +91 -3
- package/resources/webhooks/webhooks.d.mts.map +1 -1
- package/resources/webhooks/webhooks.d.ts +91 -3
- package/resources/webhooks/webhooks.d.ts.map +1 -1
- package/resources/webhooks/webhooks.js +58 -11
- package/resources/webhooks/webhooks.js.map +1 -1
- package/resources/webhooks/webhooks.mjs +58 -11
- package/resources/webhooks/webhooks.mjs.map +1 -1
- package/src/resources/admin/organization/admin-api-keys.ts +200 -1
- package/src/resources/admin/organization/audit-logs.ts +270 -1
- package/src/resources/admin/organization/certificates.ts +295 -2
- package/src/resources/admin/organization/external-storage.ts +420 -0
- package/src/resources/admin/organization/groups/groups.ts +200 -1
- package/src/resources/admin/organization/groups/roles.ts +202 -1
- package/src/resources/admin/organization/groups/users.ts +202 -1
- package/src/resources/admin/organization/index.ts +10 -0
- package/src/resources/admin/organization/invites.ts +200 -1
- package/src/resources/admin/organization/organization.ts +24 -0
- package/src/resources/admin/organization/projects/api-keys.ts +202 -1
- package/src/resources/admin/organization/projects/certificates.ts +202 -1
- package/src/resources/admin/organization/projects/groups/groups.ts +202 -1
- package/src/resources/admin/organization/projects/projects.ts +200 -1
- package/src/resources/admin/organization/projects/rate-limits.ts +202 -1
- package/src/resources/admin/organization/projects/roles.ts +202 -1
- package/src/resources/admin/organization/projects/service-accounts/service-accounts.ts +202 -1
- package/src/resources/admin/organization/projects/spend-alerts.ts +202 -1
- package/src/resources/admin/organization/projects/users/users.ts +202 -1
- package/src/resources/admin/organization/roles.ts +200 -1
- package/src/resources/admin/organization/spend-alerts.ts +200 -1
- package/src/resources/admin/organization/users/roles.ts +202 -1
- package/src/resources/admin/organization/users/users.ts +200 -1
- package/src/resources/batches.ts +200 -1
- package/src/resources/beta/agents/agents.ts +253 -43
- package/src/resources/beta/agents/environments/templates.ts +214 -9
- package/src/resources/beta/agents/sessions/artifacts.ts +202 -1
- package/src/resources/beta/agents/sessions/items.ts +202 -1
- package/src/resources/beta/agents/sessions/sessions.ts +209 -6
- package/src/resources/beta/agents/sessions/subagents/subagents.ts +202 -1
- package/src/resources/beta/agents/sessions/turns.ts +205 -3
- package/src/resources/beta/agents/vaults/credentials.ts +382 -22
- package/src/resources/beta/agents/vaults/index.ts +2 -0
- package/src/resources/beta/agents/vaults/vaults.ts +205 -3
- package/src/resources/beta/assistants.ts +200 -1
- package/src/resources/beta/chatkit/threads.ts +311 -2
- package/src/resources/beta/responses/responses.ts +4 -5
- package/src/resources/beta/threads/messages.ts +202 -1
- package/src/resources/beta/threads/runs/runs.ts +202 -1
- package/src/resources/chat/completions/completions.ts +205 -3
- package/src/resources/chat/completions/messages.ts +202 -1
- package/src/resources/containers/containers.ts +200 -1
- package/src/resources/containers/files/files.ts +202 -1
- package/src/resources/conversations/conversations.ts +3 -4
- package/src/resources/conversations/items.ts +202 -1
- package/src/resources/evals/evals.ts +200 -1
- package/src/resources/evals/runs/runs.ts +202 -1
- package/src/resources/files.ts +200 -1
- package/src/resources/fine-tuning/checkpoints/permissions.ts +297 -2
- package/src/resources/fine-tuning/jobs/checkpoints.ts +202 -1
- package/src/resources/fine-tuning/jobs/jobs.ts +295 -2
- package/src/resources/images.ts +3 -4
- package/src/resources/responses/input-items.ts +202 -1
- package/src/resources/responses/responses.ts +255 -9
- package/src/resources/safety/cases.ts +39 -0
- package/src/resources/safety/index.ts +1 -0
- package/src/resources/safety/safety.ts +6 -0
- package/src/resources/skills/skills.ts +200 -1
- package/src/resources/skills/versions/versions.ts +202 -1
- package/src/resources/vector-stores/files.ts +202 -1
- package/src/resources/vector-stores/vector-stores.ts +200 -1
- package/src/resources/videos.ts +295 -2
- package/src/resources/webhooks/api.md +2 -0
- package/src/resources/webhooks/webhooks.ts +301 -2
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
package/src/resources/videos.ts
CHANGED
|
@@ -9,6 +9,113 @@ import { RequestOptions } from '../internal/request-options';
|
|
|
9
9
|
import { maybeMultipartFormRequestOptions, multipartFormRequestOptions } from '../internal/uploads';
|
|
10
10
|
import { path } from '../internal/utils/path';
|
|
11
11
|
|
|
12
|
+
// Recognizable options across SDK runtime versions. Keep this independent of
|
|
13
|
+
// private RequestOptions fields so older handwritten runtimes still compile.
|
|
14
|
+
const normalizeRequestOptionsForQueryKeys = new Set([
|
|
15
|
+
'method',
|
|
16
|
+
'path',
|
|
17
|
+
'query',
|
|
18
|
+
'body',
|
|
19
|
+
'headers',
|
|
20
|
+
'maxRetries',
|
|
21
|
+
'stream',
|
|
22
|
+
'timeout',
|
|
23
|
+
'httpAgent',
|
|
24
|
+
'fetchOptions',
|
|
25
|
+
'signal',
|
|
26
|
+
'idempotencyKey',
|
|
27
|
+
'defaultBaseURL',
|
|
28
|
+
'__metadata',
|
|
29
|
+
'__binaryRequest',
|
|
30
|
+
'__binaryResponse',
|
|
31
|
+
'__streamClass',
|
|
32
|
+
'__security',
|
|
33
|
+
'__synthesizeEventData',
|
|
34
|
+
]);
|
|
35
|
+
|
|
36
|
+
function normalizeRequestOptionsForQuery(
|
|
37
|
+
value: unknown,
|
|
38
|
+
queryKeys: ReadonlyArray<string>,
|
|
39
|
+
options: RequestOptions | undefined,
|
|
40
|
+
):
|
|
41
|
+
| ({
|
|
42
|
+
[K in 'headers' | 'maxRetries' | 'timeout' | 'signal' | 'idempotencyKey' | 'query']?: RequestOptions[K];
|
|
43
|
+
} & {
|
|
44
|
+
[
|
|
45
|
+
K in
|
|
46
|
+
| 'method'
|
|
47
|
+
| 'path'
|
|
48
|
+
| 'body'
|
|
49
|
+
| 'stream'
|
|
50
|
+
| 'httpAgent'
|
|
51
|
+
| 'fetchOptions'
|
|
52
|
+
| 'defaultBaseURL'
|
|
53
|
+
| '__metadata'
|
|
54
|
+
| '__binaryRequest'
|
|
55
|
+
| '__binaryResponse'
|
|
56
|
+
| '__streamClass'
|
|
57
|
+
| '__security'
|
|
58
|
+
| '__synthesizeEventData'
|
|
59
|
+
]?: never;
|
|
60
|
+
})
|
|
61
|
+
| undefined {
|
|
62
|
+
if (typeof value !== 'object' || value === null) return undefined;
|
|
63
|
+
// Optional never fields can still be explicitly undefined unless consumers
|
|
64
|
+
// enable exactOptionalPropertyTypes. Snapshot data without invoking getters.
|
|
65
|
+
const entries = Object.entries(Object.getOwnPropertyDescriptors(value)).filter(
|
|
66
|
+
([, descriptor]) => descriptor.enumerable && (!('value' in descriptor) || descriptor.value !== undefined),
|
|
67
|
+
);
|
|
68
|
+
const keys = entries.map(([key]) => key);
|
|
69
|
+
const requestOnly = keys.some(
|
|
70
|
+
(key) => normalizeRequestOptionsForQueryKeys.has(key) && !queryKeys.includes(key),
|
|
71
|
+
);
|
|
72
|
+
if (!requestOnly) return undefined;
|
|
73
|
+
// Declared query fields, including stream, must use the query argument.
|
|
74
|
+
// Mixing them with request-only options is ambiguous and could change the return type.
|
|
75
|
+
if (
|
|
76
|
+
options !== undefined ||
|
|
77
|
+
keys.some((key) => !normalizeRequestOptionsForQueryKeys.has(key) || queryKeys.includes(key))
|
|
78
|
+
) {
|
|
79
|
+
throw new TypeError('Query parameters and request options must be passed as separate arguments.');
|
|
80
|
+
}
|
|
81
|
+
// The query position must not gain authority to change the request destination
|
|
82
|
+
// or transport. Those overrides require the explicit request options argument.
|
|
83
|
+
if (
|
|
84
|
+
keys.some(
|
|
85
|
+
(key) => !['headers', 'maxRetries', 'timeout', 'signal', 'idempotencyKey', 'query'].includes(key),
|
|
86
|
+
)
|
|
87
|
+
) {
|
|
88
|
+
throw new TypeError('Pass transport overrides in the explicit request options argument.');
|
|
89
|
+
}
|
|
90
|
+
// Copy only the validated fields. Spreading value would reintroduce undefined
|
|
91
|
+
// transport overrides, and deleting them would mutate the caller's object.
|
|
92
|
+
return Object.fromEntries(
|
|
93
|
+
entries.map(([key, descriptor]) => {
|
|
94
|
+
if ('value' in descriptor) return [key, descriptor.value];
|
|
95
|
+
return [key, descriptor.get ? Reflect.apply(descriptor.get, value, []) : undefined];
|
|
96
|
+
}),
|
|
97
|
+
) as {
|
|
98
|
+
[K in 'headers' | 'maxRetries' | 'timeout' | 'signal' | 'idempotencyKey' | 'query']?: RequestOptions[K];
|
|
99
|
+
} & {
|
|
100
|
+
[
|
|
101
|
+
K in
|
|
102
|
+
| 'method'
|
|
103
|
+
| 'path'
|
|
104
|
+
| 'body'
|
|
105
|
+
| 'stream'
|
|
106
|
+
| 'httpAgent'
|
|
107
|
+
| 'fetchOptions'
|
|
108
|
+
| 'defaultBaseURL'
|
|
109
|
+
| '__metadata'
|
|
110
|
+
| '__binaryRequest'
|
|
111
|
+
| '__binaryResponse'
|
|
112
|
+
| '__streamClass'
|
|
113
|
+
| '__security'
|
|
114
|
+
| '__synthesizeEventData'
|
|
115
|
+
]?: never;
|
|
116
|
+
};
|
|
117
|
+
}
|
|
118
|
+
|
|
12
119
|
/**
|
|
13
120
|
* @deprecated The Sora API is scheduled to permanently shut down on September 24, 2026.
|
|
14
121
|
*/
|
|
@@ -40,9 +147,101 @@ export class Videos extends APIResource {
|
|
|
40
147
|
* @deprecated The Sora API is scheduled to permanently shut down on September 24, 2026.
|
|
41
148
|
*/
|
|
42
149
|
list(
|
|
43
|
-
query
|
|
150
|
+
query?:
|
|
151
|
+
| (VideoListParams &
|
|
152
|
+
(
|
|
153
|
+
| {
|
|
154
|
+
[
|
|
155
|
+
K in
|
|
156
|
+
| 'method'
|
|
157
|
+
| 'path'
|
|
158
|
+
| 'query'
|
|
159
|
+
| 'body'
|
|
160
|
+
| 'headers'
|
|
161
|
+
| 'maxRetries'
|
|
162
|
+
| 'stream'
|
|
163
|
+
| 'timeout'
|
|
164
|
+
| 'httpAgent'
|
|
165
|
+
| 'fetchOptions'
|
|
166
|
+
| 'signal'
|
|
167
|
+
| 'idempotencyKey'
|
|
168
|
+
| 'defaultBaseURL'
|
|
169
|
+
| '__metadata'
|
|
170
|
+
| '__binaryRequest'
|
|
171
|
+
| '__binaryResponse'
|
|
172
|
+
| '__streamClass'
|
|
173
|
+
| '__security'
|
|
174
|
+
| '__synthesizeEventData'
|
|
175
|
+
]?: never;
|
|
176
|
+
}
|
|
177
|
+
| null
|
|
178
|
+
| undefined
|
|
179
|
+
))
|
|
180
|
+
| null
|
|
181
|
+
| undefined,
|
|
182
|
+
options?: RequestOptions,
|
|
183
|
+
): PagePromise<VideosPage, Video>;
|
|
184
|
+
list(
|
|
185
|
+
options?: {
|
|
186
|
+
[K in 'headers' | 'maxRetries' | 'timeout' | 'signal' | 'idempotencyKey' | 'query']?: RequestOptions[K];
|
|
187
|
+
} & {
|
|
188
|
+
[
|
|
189
|
+
K in
|
|
190
|
+
| 'method'
|
|
191
|
+
| 'path'
|
|
192
|
+
| 'body'
|
|
193
|
+
| 'stream'
|
|
194
|
+
| 'httpAgent'
|
|
195
|
+
| 'fetchOptions'
|
|
196
|
+
| 'defaultBaseURL'
|
|
197
|
+
| '__metadata'
|
|
198
|
+
| '__binaryRequest'
|
|
199
|
+
| '__binaryResponse'
|
|
200
|
+
| '__streamClass'
|
|
201
|
+
| '__security'
|
|
202
|
+
| '__synthesizeEventData'
|
|
203
|
+
]?: never;
|
|
204
|
+
},
|
|
205
|
+
): PagePromise<VideosPage, Video>;
|
|
206
|
+
list(
|
|
207
|
+
query:
|
|
208
|
+
| VideoListParams
|
|
209
|
+
| ({
|
|
210
|
+
[
|
|
211
|
+
K in 'headers' | 'maxRetries' | 'timeout' | 'signal' | 'idempotencyKey' | 'query'
|
|
212
|
+
]?: RequestOptions[K];
|
|
213
|
+
} & {
|
|
214
|
+
[
|
|
215
|
+
K in
|
|
216
|
+
| 'method'
|
|
217
|
+
| 'path'
|
|
218
|
+
| 'body'
|
|
219
|
+
| 'stream'
|
|
220
|
+
| 'httpAgent'
|
|
221
|
+
| 'fetchOptions'
|
|
222
|
+
| 'defaultBaseURL'
|
|
223
|
+
| '__metadata'
|
|
224
|
+
| '__binaryRequest'
|
|
225
|
+
| '__binaryResponse'
|
|
226
|
+
| '__streamClass'
|
|
227
|
+
| '__security'
|
|
228
|
+
| '__synthesizeEventData'
|
|
229
|
+
]?: never;
|
|
230
|
+
})
|
|
231
|
+
| null
|
|
232
|
+
| undefined = {},
|
|
44
233
|
options?: RequestOptions,
|
|
45
234
|
): PagePromise<VideosPage, Video> {
|
|
235
|
+
const normalizeRequestOptionsForQueryOptions = normalizeRequestOptionsForQuery(
|
|
236
|
+
query,
|
|
237
|
+
['after', 'limit', 'order'],
|
|
238
|
+
options,
|
|
239
|
+
);
|
|
240
|
+
if (normalizeRequestOptionsForQueryOptions !== undefined) {
|
|
241
|
+
options = normalizeRequestOptionsForQueryOptions;
|
|
242
|
+
query = {};
|
|
243
|
+
}
|
|
244
|
+
query = query as VideoListParams | null | undefined;
|
|
46
245
|
return this._client.getAPIList('/videos', ConversationCursorPage<Video>, {
|
|
47
246
|
query,
|
|
48
247
|
...options,
|
|
@@ -83,9 +282,103 @@ export class Videos extends APIResource {
|
|
|
83
282
|
*/
|
|
84
283
|
downloadContent(
|
|
85
284
|
videoID: string,
|
|
86
|
-
query
|
|
285
|
+
query?:
|
|
286
|
+
| (VideoDownloadContentParams &
|
|
287
|
+
(
|
|
288
|
+
| {
|
|
289
|
+
[
|
|
290
|
+
K in
|
|
291
|
+
| 'method'
|
|
292
|
+
| 'path'
|
|
293
|
+
| 'query'
|
|
294
|
+
| 'body'
|
|
295
|
+
| 'headers'
|
|
296
|
+
| 'maxRetries'
|
|
297
|
+
| 'stream'
|
|
298
|
+
| 'timeout'
|
|
299
|
+
| 'httpAgent'
|
|
300
|
+
| 'fetchOptions'
|
|
301
|
+
| 'signal'
|
|
302
|
+
| 'idempotencyKey'
|
|
303
|
+
| 'defaultBaseURL'
|
|
304
|
+
| '__metadata'
|
|
305
|
+
| '__binaryRequest'
|
|
306
|
+
| '__binaryResponse'
|
|
307
|
+
| '__streamClass'
|
|
308
|
+
| '__security'
|
|
309
|
+
| '__synthesizeEventData'
|
|
310
|
+
]?: never;
|
|
311
|
+
}
|
|
312
|
+
| null
|
|
313
|
+
| undefined
|
|
314
|
+
))
|
|
315
|
+
| null
|
|
316
|
+
| undefined,
|
|
317
|
+
options?: RequestOptions,
|
|
318
|
+
): APIPromise<Response>;
|
|
319
|
+
downloadContent(
|
|
320
|
+
videoID: string,
|
|
321
|
+
options?: {
|
|
322
|
+
[K in 'headers' | 'maxRetries' | 'timeout' | 'signal' | 'idempotencyKey' | 'query']?: RequestOptions[K];
|
|
323
|
+
} & {
|
|
324
|
+
[
|
|
325
|
+
K in
|
|
326
|
+
| 'method'
|
|
327
|
+
| 'path'
|
|
328
|
+
| 'body'
|
|
329
|
+
| 'stream'
|
|
330
|
+
| 'httpAgent'
|
|
331
|
+
| 'fetchOptions'
|
|
332
|
+
| 'defaultBaseURL'
|
|
333
|
+
| '__metadata'
|
|
334
|
+
| '__binaryRequest'
|
|
335
|
+
| '__binaryResponse'
|
|
336
|
+
| '__streamClass'
|
|
337
|
+
| '__security'
|
|
338
|
+
| '__synthesizeEventData'
|
|
339
|
+
]?: never;
|
|
340
|
+
},
|
|
341
|
+
): APIPromise<Response>;
|
|
342
|
+
downloadContent(
|
|
343
|
+
videoID: string,
|
|
344
|
+
query:
|
|
345
|
+
| VideoDownloadContentParams
|
|
346
|
+
| ({
|
|
347
|
+
[
|
|
348
|
+
K in 'headers' | 'maxRetries' | 'timeout' | 'signal' | 'idempotencyKey' | 'query'
|
|
349
|
+
]?: RequestOptions[K];
|
|
350
|
+
} & {
|
|
351
|
+
[
|
|
352
|
+
K in
|
|
353
|
+
| 'method'
|
|
354
|
+
| 'path'
|
|
355
|
+
| 'body'
|
|
356
|
+
| 'stream'
|
|
357
|
+
| 'httpAgent'
|
|
358
|
+
| 'fetchOptions'
|
|
359
|
+
| 'defaultBaseURL'
|
|
360
|
+
| '__metadata'
|
|
361
|
+
| '__binaryRequest'
|
|
362
|
+
| '__binaryResponse'
|
|
363
|
+
| '__streamClass'
|
|
364
|
+
| '__security'
|
|
365
|
+
| '__synthesizeEventData'
|
|
366
|
+
]?: never;
|
|
367
|
+
})
|
|
368
|
+
| null
|
|
369
|
+
| undefined = {},
|
|
87
370
|
options?: RequestOptions,
|
|
88
371
|
): APIPromise<Response> {
|
|
372
|
+
const normalizeRequestOptionsForQueryOptions = normalizeRequestOptionsForQuery(
|
|
373
|
+
query,
|
|
374
|
+
['variant'],
|
|
375
|
+
options,
|
|
376
|
+
);
|
|
377
|
+
if (normalizeRequestOptionsForQueryOptions !== undefined) {
|
|
378
|
+
options = normalizeRequestOptionsForQueryOptions;
|
|
379
|
+
query = {};
|
|
380
|
+
}
|
|
381
|
+
query = query as VideoDownloadContentParams | null | undefined;
|
|
89
382
|
return this._client.get(path`/videos/${videoID}/content`, {
|
|
90
383
|
query,
|
|
91
384
|
...options,
|
|
@@ -21,7 +21,9 @@ Types:
|
|
|
21
21
|
- <code><a href="./src/resources/webhooks/webhooks.ts">ResponseFailedWebhookEvent</a></code>
|
|
22
22
|
- <code><a href="./src/resources/webhooks/webhooks.ts">ResponseIncompleteWebhookEvent</a></code>
|
|
23
23
|
- <code><a href="./src/resources/webhooks/webhooks.ts">SafetyAlertCreatedWebhookEvent</a></code>
|
|
24
|
+
- <code><a href="./src/resources/webhooks/webhooks.ts">SafetyDeactivationIssuedWebhookEvent</a></code>
|
|
24
25
|
- <code><a href="./src/resources/webhooks/webhooks.ts">SafetyOrgAlertCreatedWebhookEvent</a></code>
|
|
26
|
+
- <code><a href="./src/resources/webhooks/webhooks.ts">SafetyWarningIssuedWebhookEvent</a></code>
|
|
25
27
|
- <code><a href="./src/resources/webhooks/webhooks.ts">UnwrapWebhookEvent</a></code>
|
|
26
28
|
- <code><a href="./src/resources/webhooks/webhooks.ts">WebhookEndpoint</a></code>
|
|
27
29
|
- <code><a href="./src/resources/webhooks/webhooks.ts">WebhookEndpointList</a></code>
|
|
@@ -11,6 +11,113 @@ import { CursorPage, type CursorPageParams, PagePromise } from '../../core/pagin
|
|
|
11
11
|
import { RequestOptions } from '../../internal/request-options';
|
|
12
12
|
import { path } from '../../internal/utils/path';
|
|
13
13
|
|
|
14
|
+
// Recognizable options across SDK runtime versions. Keep this independent of
|
|
15
|
+
// private RequestOptions fields so older handwritten runtimes still compile.
|
|
16
|
+
const normalizeRequestOptionsForQueryKeys = new Set([
|
|
17
|
+
'method',
|
|
18
|
+
'path',
|
|
19
|
+
'query',
|
|
20
|
+
'body',
|
|
21
|
+
'headers',
|
|
22
|
+
'maxRetries',
|
|
23
|
+
'stream',
|
|
24
|
+
'timeout',
|
|
25
|
+
'httpAgent',
|
|
26
|
+
'fetchOptions',
|
|
27
|
+
'signal',
|
|
28
|
+
'idempotencyKey',
|
|
29
|
+
'defaultBaseURL',
|
|
30
|
+
'__metadata',
|
|
31
|
+
'__binaryRequest',
|
|
32
|
+
'__binaryResponse',
|
|
33
|
+
'__streamClass',
|
|
34
|
+
'__security',
|
|
35
|
+
'__synthesizeEventData',
|
|
36
|
+
]);
|
|
37
|
+
|
|
38
|
+
function normalizeRequestOptionsForQuery(
|
|
39
|
+
value: unknown,
|
|
40
|
+
queryKeys: ReadonlyArray<string>,
|
|
41
|
+
options: RequestOptions | undefined,
|
|
42
|
+
):
|
|
43
|
+
| ({
|
|
44
|
+
[K in 'headers' | 'maxRetries' | 'timeout' | 'signal' | 'idempotencyKey' | 'query']?: RequestOptions[K];
|
|
45
|
+
} & {
|
|
46
|
+
[
|
|
47
|
+
K in
|
|
48
|
+
| 'method'
|
|
49
|
+
| 'path'
|
|
50
|
+
| 'body'
|
|
51
|
+
| 'stream'
|
|
52
|
+
| 'httpAgent'
|
|
53
|
+
| 'fetchOptions'
|
|
54
|
+
| 'defaultBaseURL'
|
|
55
|
+
| '__metadata'
|
|
56
|
+
| '__binaryRequest'
|
|
57
|
+
| '__binaryResponse'
|
|
58
|
+
| '__streamClass'
|
|
59
|
+
| '__security'
|
|
60
|
+
| '__synthesizeEventData'
|
|
61
|
+
]?: never;
|
|
62
|
+
})
|
|
63
|
+
| undefined {
|
|
64
|
+
if (typeof value !== 'object' || value === null) return undefined;
|
|
65
|
+
// Optional never fields can still be explicitly undefined unless consumers
|
|
66
|
+
// enable exactOptionalPropertyTypes. Snapshot data without invoking getters.
|
|
67
|
+
const entries = Object.entries(Object.getOwnPropertyDescriptors(value)).filter(
|
|
68
|
+
([, descriptor]) => descriptor.enumerable && (!('value' in descriptor) || descriptor.value !== undefined),
|
|
69
|
+
);
|
|
70
|
+
const keys = entries.map(([key]) => key);
|
|
71
|
+
const requestOnly = keys.some(
|
|
72
|
+
(key) => normalizeRequestOptionsForQueryKeys.has(key) && !queryKeys.includes(key),
|
|
73
|
+
);
|
|
74
|
+
if (!requestOnly) return undefined;
|
|
75
|
+
// Declared query fields, including stream, must use the query argument.
|
|
76
|
+
// Mixing them with request-only options is ambiguous and could change the return type.
|
|
77
|
+
if (
|
|
78
|
+
options !== undefined ||
|
|
79
|
+
keys.some((key) => !normalizeRequestOptionsForQueryKeys.has(key) || queryKeys.includes(key))
|
|
80
|
+
) {
|
|
81
|
+
throw new TypeError('Query parameters and request options must be passed as separate arguments.');
|
|
82
|
+
}
|
|
83
|
+
// The query position must not gain authority to change the request destination
|
|
84
|
+
// or transport. Those overrides require the explicit request options argument.
|
|
85
|
+
if (
|
|
86
|
+
keys.some(
|
|
87
|
+
(key) => !['headers', 'maxRetries', 'timeout', 'signal', 'idempotencyKey', 'query'].includes(key),
|
|
88
|
+
)
|
|
89
|
+
) {
|
|
90
|
+
throw new TypeError('Pass transport overrides in the explicit request options argument.');
|
|
91
|
+
}
|
|
92
|
+
// Copy only the validated fields. Spreading value would reintroduce undefined
|
|
93
|
+
// transport overrides, and deleting them would mutate the caller's object.
|
|
94
|
+
return Object.fromEntries(
|
|
95
|
+
entries.map(([key, descriptor]) => {
|
|
96
|
+
if ('value' in descriptor) return [key, descriptor.value];
|
|
97
|
+
return [key, descriptor.get ? Reflect.apply(descriptor.get, value, []) : undefined];
|
|
98
|
+
}),
|
|
99
|
+
) as {
|
|
100
|
+
[K in 'headers' | 'maxRetries' | 'timeout' | 'signal' | 'idempotencyKey' | 'query']?: RequestOptions[K];
|
|
101
|
+
} & {
|
|
102
|
+
[
|
|
103
|
+
K in
|
|
104
|
+
| 'method'
|
|
105
|
+
| 'path'
|
|
106
|
+
| 'body'
|
|
107
|
+
| 'stream'
|
|
108
|
+
| 'httpAgent'
|
|
109
|
+
| 'fetchOptions'
|
|
110
|
+
| 'defaultBaseURL'
|
|
111
|
+
| '__metadata'
|
|
112
|
+
| '__binaryRequest'
|
|
113
|
+
| '__binaryResponse'
|
|
114
|
+
| '__streamClass'
|
|
115
|
+
| '__security'
|
|
116
|
+
| '__synthesizeEventData'
|
|
117
|
+
]?: never;
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
|
|
14
121
|
export class Webhooks extends APIResource {
|
|
15
122
|
eventTypes: EventTypesAPI.EventTypes = new EventTypesAPI.EventTypes(this._client);
|
|
16
123
|
|
|
@@ -80,9 +187,101 @@ export class Webhooks extends APIResource {
|
|
|
80
187
|
* ```
|
|
81
188
|
*/
|
|
82
189
|
list(
|
|
83
|
-
query
|
|
190
|
+
query?:
|
|
191
|
+
| (WebhookListParams &
|
|
192
|
+
(
|
|
193
|
+
| {
|
|
194
|
+
[
|
|
195
|
+
K in
|
|
196
|
+
| 'method'
|
|
197
|
+
| 'path'
|
|
198
|
+
| 'query'
|
|
199
|
+
| 'body'
|
|
200
|
+
| 'headers'
|
|
201
|
+
| 'maxRetries'
|
|
202
|
+
| 'stream'
|
|
203
|
+
| 'timeout'
|
|
204
|
+
| 'httpAgent'
|
|
205
|
+
| 'fetchOptions'
|
|
206
|
+
| 'signal'
|
|
207
|
+
| 'idempotencyKey'
|
|
208
|
+
| 'defaultBaseURL'
|
|
209
|
+
| '__metadata'
|
|
210
|
+
| '__binaryRequest'
|
|
211
|
+
| '__binaryResponse'
|
|
212
|
+
| '__streamClass'
|
|
213
|
+
| '__security'
|
|
214
|
+
| '__synthesizeEventData'
|
|
215
|
+
]?: never;
|
|
216
|
+
}
|
|
217
|
+
| null
|
|
218
|
+
| undefined
|
|
219
|
+
))
|
|
220
|
+
| null
|
|
221
|
+
| undefined,
|
|
222
|
+
options?: RequestOptions,
|
|
223
|
+
): PagePromise<WebhookEndpointsPage, WebhookEndpoint>;
|
|
224
|
+
list(
|
|
225
|
+
options?: {
|
|
226
|
+
[K in 'headers' | 'maxRetries' | 'timeout' | 'signal' | 'idempotencyKey' | 'query']?: RequestOptions[K];
|
|
227
|
+
} & {
|
|
228
|
+
[
|
|
229
|
+
K in
|
|
230
|
+
| 'method'
|
|
231
|
+
| 'path'
|
|
232
|
+
| 'body'
|
|
233
|
+
| 'stream'
|
|
234
|
+
| 'httpAgent'
|
|
235
|
+
| 'fetchOptions'
|
|
236
|
+
| 'defaultBaseURL'
|
|
237
|
+
| '__metadata'
|
|
238
|
+
| '__binaryRequest'
|
|
239
|
+
| '__binaryResponse'
|
|
240
|
+
| '__streamClass'
|
|
241
|
+
| '__security'
|
|
242
|
+
| '__synthesizeEventData'
|
|
243
|
+
]?: never;
|
|
244
|
+
},
|
|
245
|
+
): PagePromise<WebhookEndpointsPage, WebhookEndpoint>;
|
|
246
|
+
list(
|
|
247
|
+
query:
|
|
248
|
+
| WebhookListParams
|
|
249
|
+
| ({
|
|
250
|
+
[
|
|
251
|
+
K in 'headers' | 'maxRetries' | 'timeout' | 'signal' | 'idempotencyKey' | 'query'
|
|
252
|
+
]?: RequestOptions[K];
|
|
253
|
+
} & {
|
|
254
|
+
[
|
|
255
|
+
K in
|
|
256
|
+
| 'method'
|
|
257
|
+
| 'path'
|
|
258
|
+
| 'body'
|
|
259
|
+
| 'stream'
|
|
260
|
+
| 'httpAgent'
|
|
261
|
+
| 'fetchOptions'
|
|
262
|
+
| 'defaultBaseURL'
|
|
263
|
+
| '__metadata'
|
|
264
|
+
| '__binaryRequest'
|
|
265
|
+
| '__binaryResponse'
|
|
266
|
+
| '__streamClass'
|
|
267
|
+
| '__security'
|
|
268
|
+
| '__synthesizeEventData'
|
|
269
|
+
]?: never;
|
|
270
|
+
})
|
|
271
|
+
| null
|
|
272
|
+
| undefined = {},
|
|
84
273
|
options?: RequestOptions,
|
|
85
274
|
): PagePromise<WebhookEndpointsPage, WebhookEndpoint> {
|
|
275
|
+
const normalizeRequestOptionsForQueryOptions = normalizeRequestOptionsForQuery(
|
|
276
|
+
query,
|
|
277
|
+
['after', 'limit'],
|
|
278
|
+
options,
|
|
279
|
+
);
|
|
280
|
+
if (normalizeRequestOptionsForQueryOptions !== undefined) {
|
|
281
|
+
options = normalizeRequestOptionsForQueryOptions;
|
|
282
|
+
query = {};
|
|
283
|
+
}
|
|
284
|
+
query = query as WebhookListParams | null | undefined;
|
|
86
285
|
return this._client.getAPIList('/webhook_endpoints', CursorPage<WebhookEndpoint>, {
|
|
87
286
|
query,
|
|
88
287
|
...options,
|
|
@@ -717,6 +916,14 @@ export namespace LiveCallIncomingWebhookEvent {
|
|
|
717
916
|
* untrusted call metadata.
|
|
718
917
|
*/
|
|
719
918
|
sip_headers: Array<Data.SipHeader>;
|
|
919
|
+
|
|
920
|
+
/**
|
|
921
|
+
* Media protection selected on the SIP leg during SDP negotiation. `srtp`
|
|
922
|
+
* indicates SRTP; `rtp` indicates unencrypted RTP. Omitted when unknown. This does
|
|
923
|
+
* not describe SIP signaling security or confirm that media has flowed. Clients
|
|
924
|
+
* should handle unrecognized values as unknown.
|
|
925
|
+
*/
|
|
926
|
+
sip_media_security?: 'rtp' | 'srtp' | (string & {});
|
|
720
927
|
}
|
|
721
928
|
|
|
722
929
|
export namespace Data {
|
|
@@ -791,6 +998,14 @@ export namespace LiveTransportIncomingWebhookEvent {
|
|
|
791
998
|
* The incoming transport type. Always `sip`.
|
|
792
999
|
*/
|
|
793
1000
|
type: 'sip';
|
|
1001
|
+
|
|
1002
|
+
/**
|
|
1003
|
+
* Media protection selected on the SIP leg during SDP negotiation. `srtp`
|
|
1004
|
+
* indicates SRTP; `rtp` indicates unencrypted RTP. Omitted when unknown. This does
|
|
1005
|
+
* not describe SIP signaling security or confirm that media has flowed. Clients
|
|
1006
|
+
* should handle unrecognized values as unknown.
|
|
1007
|
+
*/
|
|
1008
|
+
sip_media_security?: 'rtp' | 'srtp' | (string & {});
|
|
794
1009
|
}
|
|
795
1010
|
|
|
796
1011
|
export namespace Data {
|
|
@@ -861,6 +1076,14 @@ export namespace RealtimeCallIncomingWebhookEvent {
|
|
|
861
1076
|
* untrusted call metadata.
|
|
862
1077
|
*/
|
|
863
1078
|
sip_headers: Array<Data.SipHeader>;
|
|
1079
|
+
|
|
1080
|
+
/**
|
|
1081
|
+
* Media protection selected on the SIP leg during SDP negotiation. `srtp`
|
|
1082
|
+
* indicates SRTP; `rtp` indicates unencrypted RTP. Omitted when unknown. This does
|
|
1083
|
+
* not describe SIP signaling security or confirm that media has flowed. Clients
|
|
1084
|
+
* should handle unrecognized values as unknown.
|
|
1085
|
+
*/
|
|
1086
|
+
sip_media_security?: 'rtp' | 'srtp' | (string & {});
|
|
864
1087
|
}
|
|
865
1088
|
|
|
866
1089
|
export namespace Data {
|
|
@@ -1085,6 +1308,42 @@ export namespace SafetyAlertCreatedWebhookEvent {
|
|
|
1085
1308
|
}
|
|
1086
1309
|
}
|
|
1087
1310
|
|
|
1311
|
+
/**
|
|
1312
|
+
* Sent when a deactivation is issued for a safety identifier in your organization.
|
|
1313
|
+
*/
|
|
1314
|
+
export interface SafetyDeactivationIssuedWebhookEvent {
|
|
1315
|
+
/**
|
|
1316
|
+
* The unique ID of the webhook event.
|
|
1317
|
+
*/
|
|
1318
|
+
id: string;
|
|
1319
|
+
|
|
1320
|
+
/**
|
|
1321
|
+
* The Unix timestamp in seconds when the event was created.
|
|
1322
|
+
*/
|
|
1323
|
+
created_at: number;
|
|
1324
|
+
|
|
1325
|
+
data: SafetyDeactivationIssuedWebhookEvent.Data;
|
|
1326
|
+
|
|
1327
|
+
/**
|
|
1328
|
+
* Always `event`.
|
|
1329
|
+
*/
|
|
1330
|
+
object: 'event';
|
|
1331
|
+
|
|
1332
|
+
/**
|
|
1333
|
+
* Always `safety.deactivation_issued`.
|
|
1334
|
+
*/
|
|
1335
|
+
type: 'safety.deactivation_issued';
|
|
1336
|
+
}
|
|
1337
|
+
|
|
1338
|
+
export namespace SafetyDeactivationIssuedWebhookEvent {
|
|
1339
|
+
export interface Data {
|
|
1340
|
+
/**
|
|
1341
|
+
* The safety case ID to pass to `GET /v1/safety/cases/{id}`.
|
|
1342
|
+
*/
|
|
1343
|
+
id: string;
|
|
1344
|
+
}
|
|
1345
|
+
}
|
|
1346
|
+
|
|
1088
1347
|
/**
|
|
1089
1348
|
* Sent when an approved safety alert is available for an enterprise workspace.
|
|
1090
1349
|
*/
|
|
@@ -1121,6 +1380,42 @@ export namespace SafetyOrgAlertCreatedWebhookEvent {
|
|
|
1121
1380
|
}
|
|
1122
1381
|
}
|
|
1123
1382
|
|
|
1383
|
+
/**
|
|
1384
|
+
* Sent when a warning is issued for a safety identifier in your organization.
|
|
1385
|
+
*/
|
|
1386
|
+
export interface SafetyWarningIssuedWebhookEvent {
|
|
1387
|
+
/**
|
|
1388
|
+
* The unique ID of the webhook event.
|
|
1389
|
+
*/
|
|
1390
|
+
id: string;
|
|
1391
|
+
|
|
1392
|
+
/**
|
|
1393
|
+
* The Unix timestamp in seconds when the event was created.
|
|
1394
|
+
*/
|
|
1395
|
+
created_at: number;
|
|
1396
|
+
|
|
1397
|
+
data: SafetyWarningIssuedWebhookEvent.Data;
|
|
1398
|
+
|
|
1399
|
+
/**
|
|
1400
|
+
* Always `event`.
|
|
1401
|
+
*/
|
|
1402
|
+
object: 'event';
|
|
1403
|
+
|
|
1404
|
+
/**
|
|
1405
|
+
* Always `safety.warning_issued`.
|
|
1406
|
+
*/
|
|
1407
|
+
type: 'safety.warning_issued';
|
|
1408
|
+
}
|
|
1409
|
+
|
|
1410
|
+
export namespace SafetyWarningIssuedWebhookEvent {
|
|
1411
|
+
export interface Data {
|
|
1412
|
+
/**
|
|
1413
|
+
* The safety case ID to pass to `GET /v1/safety/cases/{id}`.
|
|
1414
|
+
*/
|
|
1415
|
+
id: string;
|
|
1416
|
+
}
|
|
1417
|
+
}
|
|
1418
|
+
|
|
1124
1419
|
/**
|
|
1125
1420
|
* Sent when a batch API request has been cancelled.
|
|
1126
1421
|
*/
|
|
@@ -1143,7 +1438,9 @@ export type UnwrapWebhookEvent =
|
|
|
1143
1438
|
| ResponseFailedWebhookEvent
|
|
1144
1439
|
| ResponseIncompleteWebhookEvent
|
|
1145
1440
|
| SafetyAlertCreatedWebhookEvent
|
|
1146
|
-
|
|
|
1441
|
+
| SafetyDeactivationIssuedWebhookEvent
|
|
1442
|
+
| SafetyOrgAlertCreatedWebhookEvent
|
|
1443
|
+
| SafetyWarningIssuedWebhookEvent;
|
|
1147
1444
|
|
|
1148
1445
|
export interface WebhookEndpoint {
|
|
1149
1446
|
/**
|
|
@@ -1439,7 +1736,9 @@ export declare namespace Webhooks {
|
|
|
1439
1736
|
type ResponseFailedWebhookEvent as ResponseFailedWebhookEvent,
|
|
1440
1737
|
type ResponseIncompleteWebhookEvent as ResponseIncompleteWebhookEvent,
|
|
1441
1738
|
type SafetyAlertCreatedWebhookEvent as SafetyAlertCreatedWebhookEvent,
|
|
1739
|
+
type SafetyDeactivationIssuedWebhookEvent as SafetyDeactivationIssuedWebhookEvent,
|
|
1442
1740
|
type SafetyOrgAlertCreatedWebhookEvent as SafetyOrgAlertCreatedWebhookEvent,
|
|
1741
|
+
type SafetyWarningIssuedWebhookEvent as SafetyWarningIssuedWebhookEvent,
|
|
1443
1742
|
type UnwrapWebhookEvent as UnwrapWebhookEvent,
|
|
1444
1743
|
type WebhookEndpoint as WebhookEndpoint,
|
|
1445
1744
|
type WebhookEndpointList as WebhookEndpointList,
|
package/src/version.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/** Version of the installed OpenAI SDK package. */
|
|
2
|
-
export const VERSION = '7.
|
|
2
|
+
export const VERSION = '7.20.0'; // x-release-please-version
|