diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index 82329db6..bc773ab6 100644 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,19 +1,19 @@ lockVersion: 2.0.0 id: c48cf606-fb42-4a45-9c23-8f0555307828 management: - docChecksum: e595ec329cbb42b8a7ec2bbb83f22d93 + docChecksum: 9e92da774887908fa842069197550069 docVersion: 1.0.0 speakeasyVersion: 1.803.2 generationVersion: 2.950.13 - releaseVersion: 1.3.223 - configChecksum: 2b103dd930f97c9a66c11cab9fb857b9 + releaseVersion: 1.3.224 + configChecksum: a85b04bba7f7ac6e968b2cf7233da674 repoURL: https://github.com/OpenRouterTeam/python-sdk.git installationURL: https://github.com/OpenRouterTeam/python-sdk.git published: true persistentEdits: - generation_id: 5de0a3b6-15d9-4924-a13d-345a5bde0c4f - pristine_commit_hash: fcedc05c41b319620fe01557d5710498daf438c1 - pristine_tree_hash: 5f93a307a91cfb3c70d2e7baa84efe833ef76226 + generation_id: 0b7bf2cf-999a-4f8e-a80c-f2cc15a17ae2 + pristine_commit_hash: 840c28e705a7d19d4cdef33fe0c1cdf1164baaa7 + pristine_tree_hash: 1ae8eef552d49da9de4a22b15fcf8ee0244fa2ff features: python: acceptHeaders: 3.0.0 @@ -1476,8 +1476,8 @@ trackedFiles: pristine_git_object: d7cd749451dea7b5545eae5f039e368cfc825d7d docs/components/batchimagegenerationresponse.mdx: id: 0dec69d57d65 - last_write_checksum: sha1:6bc8e08bb727c0b4fdd0f514b423170be422134d - pristine_git_object: 3d527fb1cefb71789ee3fe0d42442feda3b7a3db + last_write_checksum: sha1:e88330dd820b527bb97b4eea181c15147bc0a9c3 + pristine_git_object: d3e3896eab193c37e9012cd70609bdc89e9b8f79 docs/components/batchinputreference.mdx: id: 5720c0dc0b92 last_write_checksum: sha1:5be09cf46a022cd7f3074189b096d486b271fac9 @@ -10732,8 +10732,8 @@ trackedFiles: pristine_git_object: ad2a66e44c88df66127d11c39c39056b9398e3b5 docs/operations/deletescimgroupmappingrequest.mdx: id: 429d1931c37a - last_write_checksum: sha1:40a709cc60bcb4ecdb776a4a2cf8304cf1ef535d - pristine_git_object: 3d608ed570a288017dbdf820f3e045ca936860e6 + last_write_checksum: sha1:e042b66678a8497bcccb187a80db8d289aa39d80 + pristine_git_object: ee532715449a0b834956844e4857b9381402a07f docs/operations/deletevaultsecretglobals.mdx: id: 445d5e528646 last_write_checksum: sha1:41edb6f0eb6391a4ba48c584132b2bbc5537732d @@ -11284,8 +11284,8 @@ trackedFiles: pristine_git_object: dace01413ab3778f0612d9a5651b5455454661ba docs/operations/keepmembers.mdx: id: 2794baf69c28 - last_write_checksum: sha1:2858843fad79330a9c50fb0c9761c46898dd890f - pristine_git_object: e4e023ff446ddc2ef9a3123e4ae374cb232e5cf3 + last_write_checksum: sha1:0a761d2057b8f9eb65a8a88eb0396c6e1cd3af18 + pristine_git_object: 9b49faaf8ead873c34d57919aa0ec654f1bd1324 docs/operations/keepmembersenum.mdx: id: 6ee61c9ccd20 last_write_checksum: sha1:29e22c0b38d77f4920d0f8e3704cb3ed0ce01ace @@ -12300,8 +12300,8 @@ trackedFiles: pristine_git_object: 2713692f889d5d3fb5450060a18cdb28334ff745 docs/sdks/scim/README.mdx: id: fd6d8a91a053 - last_write_checksum: sha1:b8fa2f34e39af30ae7fe4c4fc497d943bf57cae9 - pristine_git_object: 3f0a3e567b411bd360fd2603d9b9e6b6e40d4787 + last_write_checksum: sha1:d912e224557d116afeeeb1245dc79d5623975e30 + pristine_git_object: 50d5c20cd6676067aa42953625109ec69c777f42 docs/sdks/stt/README.mdx: id: 190b0dc9a5d1 last_write_checksum: sha1:855bbe02b8316c063023eaa71ff87bdae037f684 @@ -12336,8 +12336,8 @@ trackedFiles: pristine_git_object: 3e38f1a929f7d6b1d6de74604aa87e3d8f010544 pyproject.toml: id: 5d07e7d72637 - last_write_checksum: sha1:ad85746c51ac6fc90082fe523d6245f82f3e39ba - pristine_git_object: 13cf95391fbd8ae712012d64906099dad19725be + last_write_checksum: sha1:58f9061ac9d1b35f8c867743d1ea245109ede516 + pristine_git_object: ae837959edc1cef8295d1a1ab74ff96697c6c699 scripts/prepare_readme.py: id: e0c5957a6035 last_write_checksum: sha1:77f44b60b98bc126557ec27391f91dfba764bb54 @@ -12364,8 +12364,8 @@ trackedFiles: pristine_git_object: 86713cfea633e09d33b3d4e65281071fe20e6137 src/openrouter/_version.py: id: d8d15ad6c586 - last_write_checksum: sha1:e122ae6d8e49740373b91b6ab04a2ad6c9a4b134 - pristine_git_object: 6bd5fda0bdea5610e132f6c58a9e6c4648bdde33 + last_write_checksum: sha1:a79f5a9f64b4986a7f4bbef31cd92137207ffe8f + pristine_git_object: 221c1bdb2b3a4226afa5e8995be316bd3dd39887 src/openrouter/alpha.py: id: 306c4d93308d last_write_checksum: sha1:80cc0f39649445431cc2247ed0e0765438467766 @@ -13076,8 +13076,8 @@ trackedFiles: pristine_git_object: 4791493c1ca478484b7e16a95344debb37c0253d src/openrouter/components/batchimagegenerationresponse.py: id: 29fdb428112a - last_write_checksum: sha1:b3c7ec9edc2a01159b00bb14466fe1384cf93e42 - pristine_git_object: 65abbf7dfcd1e89864a07ddb457b849600aecd66 + last_write_checksum: sha1:8334ac7d3e04e820bc56a8b9daaffd01b0193ca3 + pristine_git_object: 09c559ba3042b0e19706d0f3d2490bb94d1a0801 src/openrouter/components/batchinputreference.py: id: 95f4d52590ef last_write_checksum: sha1:f0a971cd8e47bab2190e7a5abe235f443b6faf0b @@ -13112,8 +13112,8 @@ trackedFiles: pristine_git_object: b2bbac635f94d6fe9f4eba2eded41b1990a9d5da src/openrouter/components/batchresult.py: id: 8a496db31329 - last_write_checksum: sha1:36a094eb53ab7a72fdbf57c0bb3896211289d3dc - pristine_git_object: 737b0c426e7befdd31db6e100467f0241a2c92d5 + last_write_checksum: sha1:27b8a8d313a493a3dd7f8239bf06c592fe6db423 + pristine_git_object: c108a9cf7e0b9feef49fa30d7ca8fb8500b14f3d src/openrouter/components/batchresultspageresponse.py: id: 9a03420787ed last_write_checksum: sha1:580bf4a6ff3f1df739c880358abc0d6172b5fd9e @@ -16836,8 +16836,8 @@ trackedFiles: pristine_git_object: 9f8ac142c2b6d3cde88d0bbc420bf5aa65054d79 src/openrouter/operations/deletescimgroupmapping.py: id: 5006e36e243e - last_write_checksum: sha1:587cfc64dccf4aa8dd470d78d2f5e878fe32e617 - pristine_git_object: aa0124d872c4b181f6cb77dfe4772cc528339822 + last_write_checksum: sha1:5d80b78c9223f946aeb6e17aae26af33948b6b65 + pristine_git_object: bada4a4344b1af53386a83a9ddedd28513d04127 src/openrouter/operations/deletevaultsecret.py: id: 1a7a4e95df3d last_write_checksum: sha1:5e63aac783c783de8171d4d4b35d11a77867f151 @@ -17340,8 +17340,8 @@ trackedFiles: pristine_git_object: 9657171612cd81ca38c0dcdec14b49eb9adbb5f9 src/openrouter/scim.py: id: 351afd6b616e - last_write_checksum: sha1:8d1dfe362ca7c5ab91c3a46e7cdf1ac16f4207fb - pristine_git_object: 56788ad9f6329b1f8c1b5f4832af6484b4021e16 + last_write_checksum: sha1:d7ee3432ea7a5a5e6aee18671a4335b7fbe96f9c + pristine_git_object: da36fb6c787c5d7abde82cef765620a3a88b874c src/openrouter/sdk.py: id: ee9846c4c9c5 last_write_checksum: sha1:e2ac234f50cf2fa57417f0be1c9222dc8cfcf947 @@ -22644,6 +22644,6 @@ examples: examplesVersion: 1.0.2 releaseNotes: | ## Python SDK Changes: - * `open_router.stt.list_models()`: **Added** - * `open_router.stt.get_model()`: **Added** - * `open_router.rerank.list_models()`: **Added** + * `open_router.batch.create_batches()`: `response.results[].response.body.union(BatchImageGenerationResponse).id` **Added** + * `open_router.batch.get_batches()`: `response.results[].response.body.union(BatchImageGenerationResponse).id` **Added** + * `open_router.batch.get_results()`: `response.data[].response.body.union(BatchImageGenerationResponse).id` **Added** diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml index 71bd38e4..c414e367 100644 --- a/.speakeasy/gen.yaml +++ b/.speakeasy/gen.yaml @@ -37,7 +37,7 @@ generation: documentation: mintlify preApplyUnionDiscriminators: true python: - version: 1.3.223 + version: 1.3.224 additionalDependencies: dev: pytest: '>=8.3' diff --git a/.speakeasy/out.openapi.yaml b/.speakeasy/out.openapi.yaml index a86e70b6..b12c9f48 100644 --- a/.speakeasy/out.openapi.yaml +++ b/.speakeasy/out.openapi.yaml @@ -5411,6 +5411,10 @@ components: description: 'Unix timestamp (seconds) when the image URLs in `data` stop working. Download the images before then.' example: 1748458800 type: 'integer' + id: + description: 'Generation ID of this request. Look up its cost and details with `GET /api/v1/generation?id=`.' + example: 'gen-batch-1748372400-3f1c9b2e7a5d4c8e0b61' + type: 'string' usage: $ref: '#/components/schemas/ImageGenerationUsage' required: @@ -61851,7 +61855,7 @@ paths: results: '$.data' type: 'offsetLimit' post: - description: 'Create a SCIM group-to-workspace role mapping. Creating a mapping that already exists with the same role succeeds and re-applies the mapping to the group members. Requesting a different role for an existing mapping returns 409. Assigning the `admin` role is dashboard-only and returns 403 for management keys. [Management key](/docs/guides/overview/auth/management-api-keys) required.' + description: 'Create a SCIM group-to-workspace role mapping. Creating a mapping that already exists with the same role succeeds and re-applies the mapping to the group members. Requesting a different role for an existing mapping returns 409. [Management key](/docs/guides/overview/auth/management-api-keys) required.' operationId: 'createScimGroupMapping' requestBody: content: @@ -61936,7 +61940,7 @@ paths: - $ref: "#/components/parameters/AppCategories" /scim/group-mappings/{id}: delete: - description: 'Delete a SCIM group-to-workspace mapping. For an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — preserving members as workspace admins is dashboard-only. Deleting a mapping that has guardrail policies attached returns `403`; remove those policies in the dashboard first. [Management key](/docs/guides/overview/auth/management-api-keys) required.' + description: 'Delete a SCIM group-to-workspace mapping. Deleting a mapping that has guardrail policies attached returns `403` unless the organization has guardrail policy management enabled and the key also has guardrail-update authority, in which case deleting the mapping releases its attached guardrail assignments. [Management key](/docs/guides/overview/auth/management-api-keys) required.' operationId: 'deleteScimGroupMapping' parameters: - in: 'path' @@ -61945,7 +61949,7 @@ paths: schema: format: 'uuid' type: 'string' - - description: 'Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.' + - description: 'Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping''s role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.' in: 'query' name: 'keep_members' required: true @@ -61957,7 +61961,7 @@ paths: type: 'string' x-speakeasy-unknown-values: allow - type: 'boolean' - description: 'Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.' + description: 'Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping''s role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.' example: false responses: '200': @@ -62082,7 +62086,7 @@ paths: - 'SCIM' x-speakeasy-name-override: 'read' patch: - description: 'Update a SCIM group mapping role. Assigning the `admin` role is dashboard-only and returns 403 for management keys. [Management key](/docs/guides/overview/auth/management-api-keys) required.' + description: 'Update a SCIM group mapping role. [Management key](/docs/guides/overview/auth/management-api-keys) required.' operationId: 'updateScimGroupMapping' parameters: - in: 'path' diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 1dc85505..d0221134 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -2,8 +2,8 @@ speakeasyVersion: 1.803.2 sources: OpenRouter API: sourceNamespace: open-router-chat-completions-api - sourceRevisionDigest: sha256:07779c4e389edaf81c38996739348d5ab548fe8bf37ae2aadd734aad7c91acc9 - sourceBlobDigest: sha256:f09bbbf022efa202ad93b975f49977ea295a9c5c6e287d10e304152b5100d262 + sourceRevisionDigest: sha256:4ebc5f72bb4bde1a4c95de59087ce6f0bca2427676002202db033b7861afa147 + sourceBlobDigest: sha256:aa553839bcd3f17ae3f080790fb549f29cecf7fdbc857b6dce6d222d36345bb6 tags: - latest - 1.0.0 @@ -11,10 +11,10 @@ targets: open-router: source: OpenRouter API sourceNamespace: open-router-chat-completions-api - sourceRevisionDigest: sha256:07779c4e389edaf81c38996739348d5ab548fe8bf37ae2aadd734aad7c91acc9 - sourceBlobDigest: sha256:f09bbbf022efa202ad93b975f49977ea295a9c5c6e287d10e304152b5100d262 + sourceRevisionDigest: sha256:4ebc5f72bb4bde1a4c95de59087ce6f0bca2427676002202db033b7861afa147 + sourceBlobDigest: sha256:aa553839bcd3f17ae3f080790fb549f29cecf7fdbc857b6dce6d222d36345bb6 codeSamplesNamespace: open-router-python-code-samples - codeSamplesRevisionDigest: sha256:8368e10ae44dc2d8b8f7ede5b8a24dd34af7932f04b3c5e320d9a0fa5db6af7b + codeSamplesRevisionDigest: sha256:a6cf1ccde23827e7c3c72196d0dcace292a268842c26d6ea323c45e7f76383f6 workflow: workflowVersion: 1.0.0 speakeasyVersion: 1.803.2 diff --git a/RELEASES.md b/RELEASES.md index d2bbbd26..3a7cdef3 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -4999,4 +4999,14 @@ Based on: ### Generated - [python v1.3.223] . ### Releases -- [PyPI v1.3.223] https://pypi.org/project/openrouter/1.3.223 - . \ No newline at end of file +- [PyPI v1.3.223] https://pypi.org/project/openrouter/1.3.223 - . + +## 2026-12-01 18:29:55 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.803.2 (2.950.13) https://github.com/speakeasy-api/speakeasy +### Generated +- [python v1.3.224] . +### Releases +- [PyPI v1.3.224] https://pypi.org/project/openrouter/1.3.224 - . \ No newline at end of file diff --git a/docs/components/batchimagegenerationresponse.mdx b/docs/components/batchimagegenerationresponse.mdx index 3d527fb1..d3e3896e 100644 --- a/docs/components/batchimagegenerationresponse.mdx +++ b/docs/components/batchimagegenerationresponse.mdx @@ -12,4 +12,5 @@ Image generation result of a batch request: image links and when they expire | `created` | *int* | ✔️ | Unix timestamp (seconds) when the image was generated | 1748372400 | | `data` | List[[components.BatchImageGenerationImage](../components/batchimagegenerationimage.mdx)] | ✔️ | N/A | | | `expires_at` | *int* | ✔️ | Unix timestamp (seconds) when the image URLs in `data` stop working. Download the images before then. | 1748458800 | +| `id` | *Optional[str]* | ➖ | Generation ID of this request. Look up its cost and details with `GET /api/v1/generation?id=`. | gen-batch-1748372400-3f1c9b2e7a5d4c8e0b61 | | `usage` | [Optional[components.ImageGenerationUsage]](../components/imagegenerationusage.mdx) | ➖ | Token and cost usage for the image generation request, when available | \{
"completion_tokens": 4175,
"cost": 0.04,
"prompt_tokens": 0,
"total_tokens": 4175
} | \ No newline at end of file diff --git a/docs/operations/deletescimgroupmappingrequest.mdx b/docs/operations/deletescimgroupmappingrequest.mdx index 3d608ed5..ee532715 100644 --- a/docs/operations/deletescimgroupmappingrequest.mdx +++ b/docs/operations/deletescimgroupmappingrequest.mdx @@ -4,10 +4,10 @@ title: "DeleteScimGroupMappingRequest" ## Fields -| Field | Type | Required | Description | Example | -| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `http_referer` | *Optional[str]* | ➖ | The app identifier should be your app's URL and is used as the primary identifier for rankings.
This is used to track API usage per application.
| | -| `x_open_router_title` | *Optional[str]* | ➖ | The app display name allows you to customize how your app appears in OpenRouter's dashboard.
| | -| `x_open_router_categories` | *Optional[str]* | ➖ | Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
| | -| `id` | *str* | ✔️ | N/A | | -| `keep_members` | [operations.KeepMembers](../operations/keepmembers.mdx) | ✔️ | Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required. | false | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `http_referer` | *Optional[str]* | ➖ | The app identifier should be your app's URL and is used as the primary identifier for rankings.
This is used to track API usage per application.
| | +| `x_open_router_title` | *Optional[str]* | ➖ | The app display name allows you to customize how your app appears in OpenRouter's dashboard.
| | +| `x_open_router_categories` | *Optional[str]* | ➖ | Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
| | +| `id` | *str* | ✔️ | N/A | | +| `keep_members` | [operations.KeepMembers](../operations/keepmembers.mdx) | ✔️ | Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping's role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required. | false | \ No newline at end of file diff --git a/docs/operations/keepmembers.mdx b/docs/operations/keepmembers.mdx index e4e023ff..9b49faaf 100644 --- a/docs/operations/keepmembers.mdx +++ b/docs/operations/keepmembers.mdx @@ -2,7 +2,7 @@ title: "KeepMembers" --- -Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required. +Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping's role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required. ## Supported Types diff --git a/docs/sdks/scim/README.mdx b/docs/sdks/scim/README.mdx index 3f0a3e56..50d5c20c 100644 --- a/docs/sdks/scim/README.mdx +++ b/docs/sdks/scim/README.mdx @@ -72,7 +72,7 @@ with OpenRouter( ## create -Create a SCIM group-to-workspace role mapping. Creating a mapping that already exists with the same role succeeds and re-applies the mapping to the group members. Requesting a different role for an existing mapping returns 409. Assigning the `admin` role is dashboard-only and returns 403 for management keys. [Management key](/docs/guides/overview/auth/management-api-keys) required. +Create a SCIM group-to-workspace role mapping. Creating a mapping that already exists with the same role succeeds and re-applies the mapping to the group members. Requesting a different role for an existing mapping returns 409. [Management key](/docs/guides/overview/auth/management-api-keys) required. ### Example Usage @@ -125,7 +125,7 @@ with OpenRouter( ## delete -Delete a SCIM group-to-workspace mapping. For an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — preserving members as workspace admins is dashboard-only. Deleting a mapping that has guardrail policies attached returns `403`; remove those policies in the dashboard first. [Management key](/docs/guides/overview/auth/management-api-keys) required. +Delete a SCIM group-to-workspace mapping. Deleting a mapping that has guardrail policies attached returns `403` unless the organization has guardrail policy management enabled and the key also has guardrail-update authority, in which case deleting the mapping releases its attached guardrail assignments. [Management key](/docs/guides/overview/auth/management-api-keys) required. ### Example Usage @@ -150,14 +150,14 @@ with OpenRouter( ### Parameters -| Parameter | Type | Required | Description | Example | -| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `id` | *str* | ✔️ | N/A | | -| `keep_members` | [operations.KeepMembers](../../operations/keepmembers.mdx) | ✔️ | Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required. | false | -| `http_referer` | *Optional[str]* | ➖ | The app identifier should be your app's URL and is used as the primary identifier for rankings.
This is used to track API usage per application.
| | -| `x_open_router_title` | *Optional[str]* | ➖ | The app display name allows you to customize how your app appears in OpenRouter's dashboard.
| | -| `x_open_router_categories` | *Optional[str]* | ➖ | Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
| | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.mdx) | ➖ | Configuration to override the default retry behavior of the client. | | +| Parameter | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | ✔️ | N/A | | +| `keep_members` | [operations.KeepMembers](../../operations/keepmembers.mdx) | ✔️ | Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping's role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required. | false | +| `http_referer` | *Optional[str]* | ➖ | The app identifier should be your app's URL and is used as the primary identifier for rankings.
This is used to track API usage per application.
| | +| `x_open_router_title` | *Optional[str]* | ➖ | The app display name allows you to customize how your app appears in OpenRouter's dashboard.
| | +| `x_open_router_categories` | *Optional[str]* | ➖ | Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
| | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.mdx) | ➖ | Configuration to override the default retry behavior of the client. | | ### Response @@ -225,7 +225,7 @@ with OpenRouter( ## update -Update a SCIM group mapping role. Assigning the `admin` role is dashboard-only and returns 403 for management keys. [Management key](/docs/guides/overview/auth/management-api-keys) required. +Update a SCIM group mapping role. [Management key](/docs/guides/overview/auth/management-api-keys) required. ### Example Usage diff --git a/pyproject.toml b/pyproject.toml index 13cf9539..ae837959 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "openrouter" -version = "1.3.223" +version = "1.3.224" description = "Official Python Client SDK for OpenRouter." authors = [{ name = "OpenRouter" },] readme = "README-PYPI.md" diff --git a/src/openrouter/_version.py b/src/openrouter/_version.py index 6bd5fda0..221c1bdb 100644 --- a/src/openrouter/_version.py +++ b/src/openrouter/_version.py @@ -3,10 +3,10 @@ import importlib.metadata __title__: str = "openrouter" -__version__: str = "1.3.223" +__version__: str = "1.3.224" __openapi_doc_version__: str = "1.0.0" __gen_version__: str = "2.950.13" -__user_agent__: str = "speakeasy-sdk/python 1.3.223 2.950.13 1.0.0 openrouter" +__user_agent__: str = "speakeasy-sdk/python 1.3.224 2.950.13 1.0.0 openrouter" try: if __package__ is not None: diff --git a/src/openrouter/components/batchimagegenerationresponse.py b/src/openrouter/components/batchimagegenerationresponse.py index 65abbf7d..09c559ba 100644 --- a/src/openrouter/components/batchimagegenerationresponse.py +++ b/src/openrouter/components/batchimagegenerationresponse.py @@ -20,6 +20,8 @@ class BatchImageGenerationResponseTypedDict(TypedDict): data: List[BatchImageGenerationImageTypedDict] expires_at: int r"""Unix timestamp (seconds) when the image URLs in `data` stop working. Download the images before then.""" + id: NotRequired[str] + r"""Generation ID of this request. Look up its cost and details with `GET /api/v1/generation?id=`.""" usage: NotRequired[ImageGenerationUsageTypedDict] r"""Token and cost usage for the image generation request, when available""" @@ -35,12 +37,15 @@ class BatchImageGenerationResponse(BaseModel): expires_at: int r"""Unix timestamp (seconds) when the image URLs in `data` stop working. Download the images before then.""" + id: Optional[str] = None + r"""Generation ID of this request. Look up its cost and details with `GET /api/v1/generation?id=`.""" + usage: Optional[ImageGenerationUsage] = None r"""Token and cost usage for the image generation request, when available""" @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["usage"]) + optional_fields = set(["id", "usage"]) serialized = handler(self) m = {} diff --git a/src/openrouter/components/batchresult.py b/src/openrouter/components/batchresult.py index 737b0c42..c108a9cf 100644 --- a/src/openrouter/components/batchresult.py +++ b/src/openrouter/components/batchresult.py @@ -1417,8 +1417,8 @@ def serialize_model(self, handler): "BodyTypedDict", Union[ BodyAudioSpeechTypedDict, - BatchImageGenerationResponseTypedDict, BodyListTypedDict, + BatchImageGenerationResponseTypedDict, BodyMessageTypedDict, BodyChatCompletionTypedDict, OpenResponsesResultTypedDict, @@ -1430,8 +1430,8 @@ def serialize_model(self, handler): "Body", Union[ BodyAudioSpeech, - BatchImageGenerationResponse, BodyList, + BatchImageGenerationResponse, BodyMessage, BodyChatCompletion, OpenResponsesResult, diff --git a/src/openrouter/operations/deletescimgroupmapping.py b/src/openrouter/operations/deletescimgroupmapping.py index aa0124d8..bada4a43 100644 --- a/src/openrouter/operations/deletescimgroupmapping.py +++ b/src/openrouter/operations/deletescimgroupmapping.py @@ -90,17 +90,17 @@ def serialize_model(self, handler): KeepMembersTypedDict = TypeAliasType( "KeepMembersTypedDict", Union[KeepMembersEnum, bool] ) -r"""Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.""" +r"""Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping's role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.""" KeepMembers = TypeAliasType("KeepMembers", Union[KeepMembersEnum, bool]) -r"""Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.""" +r"""Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping's role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.""" class DeleteScimGroupMappingRequestTypedDict(TypedDict): id: str keep_members: KeepMembersTypedDict - r"""Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.""" + r"""Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping's role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.""" http_referer: NotRequired[str] r"""The app identifier should be your app's URL and is used as the primary identifier for rankings. This is used to track API usage per application. @@ -124,7 +124,7 @@ class DeleteScimGroupMappingRequest(BaseModel): keep_members: Annotated[ KeepMembers, FieldMetadata(query=QueryParamMetadata(style="form", explode=True)) ] - r"""Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.""" + r"""Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping's role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required.""" http_referer: Annotated[ Optional[str], diff --git a/src/openrouter/scim.py b/src/openrouter/scim.py index 56788ad9..da36fb6c 100644 --- a/src/openrouter/scim.py +++ b/src/openrouter/scim.py @@ -370,7 +370,7 @@ def create( ) -> components.CreateScimGroupMappingResponse: r"""Create a SCIM group mapping - Create a SCIM group-to-workspace role mapping. Creating a mapping that already exists with the same role succeeds and re-applies the mapping to the group members. Requesting a different role for an existing mapping returns 409. Assigning the `admin` role is dashboard-only and returns 403 for management keys. [Management key](/docs/guides/overview/auth/management-api-keys) required. + Create a SCIM group-to-workspace role mapping. Creating a mapping that already exists with the same role succeeds and re-applies the mapping to the group members. Requesting a different role for an existing mapping returns 409. [Management key](/docs/guides/overview/auth/management-api-keys) required. :param role: :param scim_group_id: @@ -530,7 +530,7 @@ async def create_async( ) -> components.CreateScimGroupMappingResponse: r"""Create a SCIM group mapping - Create a SCIM group-to-workspace role mapping. Creating a mapping that already exists with the same role succeeds and re-applies the mapping to the group members. Requesting a different role for an existing mapping returns 409. Assigning the `admin` role is dashboard-only and returns 403 for management keys. [Management key](/docs/guides/overview/auth/management-api-keys) required. + Create a SCIM group-to-workspace role mapping. Creating a mapping that already exists with the same role succeeds and re-applies the mapping to the group members. Requesting a different role for an existing mapping returns 409. [Management key](/docs/guides/overview/auth/management-api-keys) required. :param role: :param scim_group_id: @@ -689,10 +689,10 @@ def delete( ) -> components.DeleteScimGroupMappingResponse: r"""Delete a SCIM group mapping - Delete a SCIM group-to-workspace mapping. For an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — preserving members as workspace admins is dashboard-only. Deleting a mapping that has guardrail policies attached returns `403`; remove those policies in the dashboard first. [Management key](/docs/guides/overview/auth/management-api-keys) required. + Delete a SCIM group-to-workspace mapping. Deleting a mapping that has guardrail policies attached returns `403` unless the organization has guardrail policy management enabled and the key also has guardrail-update authority, in which case deleting the mapping releases its attached guardrail assignments. [Management key](/docs/guides/overview/auth/management-api-keys) required. :param id: - :param keep_members: Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required. + :param keep_members: Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping's role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required. :param http_referer: The app identifier should be your app's URL and is used as the primary identifier for rankings. This is used to track API usage per application. @@ -832,10 +832,10 @@ async def delete_async( ) -> components.DeleteScimGroupMappingResponse: r"""Delete a SCIM group mapping - Delete a SCIM group-to-workspace mapping. For an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — preserving members as workspace admins is dashboard-only. Deleting a mapping that has guardrail policies attached returns `403`; remove those policies in the dashboard first. [Management key](/docs/guides/overview/auth/management-api-keys) required. + Delete a SCIM group-to-workspace mapping. Deleting a mapping that has guardrail policies attached returns `403` unless the organization has guardrail policy management enabled and the key also has guardrail-update authority, in which case deleting the mapping releases its attached guardrail assignments. [Management key](/docs/guides/overview/auth/management-api-keys) required. :param id: - :param keep_members: Required. Whether to keep workspace members after deleting the mapping. `false` **removes** the members this mapping granted access to; `true` deletes the mapping while leaving membership intact as manually-managed. Exception: for an `admin` mapping, `keep_members=true` returns `403` and leaves the mapping in place — management keys cannot preserve members as workspace admins, so do not plan an admin mapping rotation around preserving members through this endpoint (use the dashboard instead). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required. + :param keep_members: Required. Whether to keep workspace members after deleting the mapping. `false` **removes** SCIM-managed workspace memberships that no surviving mapping grants (including members of this group and any stale SCIM-managed memberships outside it); `true` deletes the mapping while converting current members of an active mapped group to manually-managed (retaining the lower of their stored role and the deleted mapping's role) if no other mapping grants them access to the workspace (surviving mappings to the same workspace take precedence and keep the member SCIM-managed with their remaining role; orphaned SCIM memberships and members of a soft-deleted group are still revoked). There is deliberately no default — omitting it returns `400` so the destructive path cannot be reached by accident. Mirrors the dashboard, whose `DeleteMappingSchema.keepMembers` is likewise required. :param http_referer: The app identifier should be your app's URL and is used as the primary identifier for rankings. This is used to track API usage per application. @@ -1245,7 +1245,7 @@ def update( ) -> components.UpdateScimGroupMappingResponse: r"""Update a SCIM group mapping - Update a SCIM group mapping role. Assigning the `admin` role is dashboard-only and returns 403 for management keys. [Management key](/docs/guides/overview/auth/management-api-keys) required. + Update a SCIM group mapping role. [Management key](/docs/guides/overview/auth/management-api-keys) required. :param id: :param role: @@ -1397,7 +1397,7 @@ async def update_async( ) -> components.UpdateScimGroupMappingResponse: r"""Update a SCIM group mapping - Update a SCIM group mapping role. Assigning the `admin` role is dashboard-only and returns 403 for management keys. [Management key](/docs/guides/overview/auth/management-api-keys) required. + Update a SCIM group mapping role. [Management key](/docs/guides/overview/auth/management-api-keys) required. :param id: :param role: diff --git a/uv.lock b/uv.lock index 292dfa99..3611de4f 100644 --- a/uv.lock +++ b/uv.lock @@ -231,7 +231,7 @@ wheels = [ [[package]] name = "openrouter" -version = "1.3.223" +version = "1.3.224" source = { editable = "." } dependencies = [ { name = "httpcore" },