From f631bba9620550ed5b9d294731ebcbefd0a46f21 Mon Sep 17 00:00:00 2001 From: Clerk Bot Date: Thu, 11 Jun 2026 17:16:26 +0000 Subject: [PATCH] chore: Update OpenAPI Specs --- bapi/2021-02-05.yml | 82 ++++++++++++++++++++++++++++++++++++++++----- bapi/2024-10-01.yml | 82 ++++++++++++++++++++++++++++++++++++++++----- bapi/2025-04-10.yml | 82 ++++++++++++++++++++++++++++++++++++++++----- bapi/2025-11-10.yml | 82 ++++++++++++++++++++++++++++++++++++++++----- bapi/2026-05-12.yml | 81 ++++++++++++++++++++++++++++++++++---------- fapi/2025-04-10.yml | 5 ++- fapi/2025-11-10.yml | 5 ++- fapi/2026-05-12.yml | 4 +-- 8 files changed, 369 insertions(+), 54 deletions(-) diff --git a/bapi/2021-02-05.yml b/bapi/2021-02-05.yml index 69ecf34..b15a7af 100644 --- a/bapi/2021-02-05.yml +++ b/bapi/2021-02-05.yml @@ -2418,21 +2418,29 @@ paths: You must provide the backup codes in plain format or the corresponding bcrypt digest. public_metadata: type: object - description: Metadata saved on the user, that is visible to both your Frontend and Backend APIs + description: |- + Metadata saved on the user, that is visible to both your Frontend and Backend APIs. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true private_metadata: type: object - description: Metadata saved on the user, that is only visible to your Backend API + description: |- + Metadata saved on the user, that is only visible to your Backend API. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true unsafe_metadata: type: object description: |- Metadata saved on the user, that can be updated from both the Frontend and Backend APIs. Note: Since this data can be modified from the frontend, it is not guaranteed to be safe. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true delete_self_enabled: type: boolean description: If true, the user can delete themselves with the Frontend API. @@ -2776,12 +2784,12 @@ paths: Replace a user's metadata attributes with the provided values. Unlike `PATCH /v1/users/{user_id}/metadata` (merge semantics), this endpoint - replaces the supplied metadata columns entirely — the prior contents of each - supplied column are discarded. Columns omitted from the request body are + replaces the supplied metadata fields entirely — the prior contents of each + supplied field are discarded. Fields omitted from the request body are left unchanged. Prefer the `PATCH` endpoint for partial updates. Use `PUT` only when you - explicitly intend to overwrite a metadata column wholesale. + explicitly intend to overwrite a metadata field wholesale. tags: - Users parameters: @@ -5166,14 +5174,20 @@ paths: properties: public_metadata: type: object - description: Metadata saved on the organization, that is visible to both your frontend and backend. + description: |- + Metadata saved on the organization, that is visible to both your frontend and backend. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/organizations/{organization_id}`. Use `PATCH /v1/organizations/{organization_id}/metadata` to merge updates into existing metadata, or `PUT /v1/organizations/{organization_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true private_metadata: type: object - description: Metadata saved on the organization that is only visible to your backend. + description: |- + Metadata saved on the organization that is only visible to your backend. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/organizations/{organization_id}`. Use `PATCH /v1/organizations/{organization_id}/metadata` to merge updates into existing metadata, or `PUT /v1/organizations/{organization_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true name: type: string description: |- @@ -5208,7 +5222,7 @@ paths: '400': $ref: '#/components/responses/ClerkErrors' '402': - $ref: '#/components/responses/ResourceNotFound' + $ref: '#/components/responses/PaymentRequired' '403': $ref: '#/components/responses/AuthorizationInvalid' '404': @@ -5292,6 +5306,58 @@ paths: $ref: '#/components/responses/ResourceNotFound' '422': $ref: '#/components/responses/UnprocessableEntity' + put: + operationId: ReplaceOrganizationMetadata + x-speakeasy-group: organizations + x-speakeasy-name-override: replaceMetadata + summary: Replace metadata for an organization + description: |- + Replace an organization's metadata attributes with the provided values. + Unlike `PATCH /v1/organizations/{organization_id}/metadata` (merge semantics), this + endpoint replaces the supplied metadata fields entirely — the prior contents of each + supplied field are discarded. Fields omitted from the request body are left unchanged. + Prefer the `PATCH` endpoint for partial updates. Use `PUT` only when you explicitly + intend to overwrite a metadata field wholesale. + tags: + - Organizations + parameters: + - name: organization_id + in: path + description: The ID of the organization whose metadata will be replaced + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + public_metadata: + type: object + description: |- + Metadata saved on the organization, that is visible to both your frontend and backend. + The existing value will be replaced entirely with the new object. + additionalProperties: true + private_metadata: + type: object + description: |- + Metadata saved on the organization that is only visible to your backend. + The existing value will be replaced entirely with the new object. + additionalProperties: true + responses: + '200': + $ref: '#/components/responses/Organization' + '400': + $ref: '#/components/responses/ClerkErrors' + '401': + $ref: '#/components/responses/AuthenticationInvalid' + '404': + $ref: '#/components/responses/ResourceNotFound' + '422': + $ref: '#/components/responses/UnprocessableEntity' /organizations/{organization_id}/logo: put: operationId: UploadOrganizationLogo diff --git a/bapi/2024-10-01.yml b/bapi/2024-10-01.yml index 9edf12c..e8ded84 100644 --- a/bapi/2024-10-01.yml +++ b/bapi/2024-10-01.yml @@ -2418,21 +2418,29 @@ paths: You must provide the backup codes in plain format or the corresponding bcrypt digest. public_metadata: type: object - description: Metadata saved on the user, that is visible to both your Frontend and Backend APIs + description: |- + Metadata saved on the user, that is visible to both your Frontend and Backend APIs. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true private_metadata: type: object - description: Metadata saved on the user, that is only visible to your Backend API + description: |- + Metadata saved on the user, that is only visible to your Backend API. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true unsafe_metadata: type: object description: |- Metadata saved on the user, that can be updated from both the Frontend and Backend APIs. Note: Since this data can be modified from the frontend, it is not guaranteed to be safe. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true delete_self_enabled: type: boolean description: If true, the user can delete themselves with the Frontend API. @@ -2776,12 +2784,12 @@ paths: Replace a user's metadata attributes with the provided values. Unlike `PATCH /v1/users/{user_id}/metadata` (merge semantics), this endpoint - replaces the supplied metadata columns entirely — the prior contents of each - supplied column are discarded. Columns omitted from the request body are + replaces the supplied metadata fields entirely — the prior contents of each + supplied field are discarded. Fields omitted from the request body are left unchanged. Prefer the `PATCH` endpoint for partial updates. Use `PUT` only when you - explicitly intend to overwrite a metadata column wholesale. + explicitly intend to overwrite a metadata field wholesale. tags: - Users parameters: @@ -5166,14 +5174,20 @@ paths: properties: public_metadata: type: object - description: Metadata saved on the organization, that is visible to both your frontend and backend. + description: |- + Metadata saved on the organization, that is visible to both your frontend and backend. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/organizations/{organization_id}`. Use `PATCH /v1/organizations/{organization_id}/metadata` to merge updates into existing metadata, or `PUT /v1/organizations/{organization_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true private_metadata: type: object - description: Metadata saved on the organization that is only visible to your backend. + description: |- + Metadata saved on the organization that is only visible to your backend. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/organizations/{organization_id}`. Use `PATCH /v1/organizations/{organization_id}/metadata` to merge updates into existing metadata, or `PUT /v1/organizations/{organization_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true name: type: string description: |- @@ -5208,7 +5222,7 @@ paths: '400': $ref: '#/components/responses/ClerkErrors' '402': - $ref: '#/components/responses/ResourceNotFound' + $ref: '#/components/responses/PaymentRequired' '403': $ref: '#/components/responses/AuthorizationInvalid' '404': @@ -5292,6 +5306,58 @@ paths: $ref: '#/components/responses/ResourceNotFound' '422': $ref: '#/components/responses/UnprocessableEntity' + put: + operationId: ReplaceOrganizationMetadata + x-speakeasy-group: organizations + x-speakeasy-name-override: replaceMetadata + summary: Replace metadata for an organization + description: |- + Replace an organization's metadata attributes with the provided values. + Unlike `PATCH /v1/organizations/{organization_id}/metadata` (merge semantics), this + endpoint replaces the supplied metadata fields entirely — the prior contents of each + supplied field are discarded. Fields omitted from the request body are left unchanged. + Prefer the `PATCH` endpoint for partial updates. Use `PUT` only when you explicitly + intend to overwrite a metadata field wholesale. + tags: + - Organizations + parameters: + - name: organization_id + in: path + description: The ID of the organization whose metadata will be replaced + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + public_metadata: + type: object + description: |- + Metadata saved on the organization, that is visible to both your frontend and backend. + The existing value will be replaced entirely with the new object. + additionalProperties: true + private_metadata: + type: object + description: |- + Metadata saved on the organization that is only visible to your backend. + The existing value will be replaced entirely with the new object. + additionalProperties: true + responses: + '200': + $ref: '#/components/responses/Organization' + '400': + $ref: '#/components/responses/ClerkErrors' + '401': + $ref: '#/components/responses/AuthenticationInvalid' + '404': + $ref: '#/components/responses/ResourceNotFound' + '422': + $ref: '#/components/responses/UnprocessableEntity' /organizations/{organization_id}/logo: put: operationId: UploadOrganizationLogo diff --git a/bapi/2025-04-10.yml b/bapi/2025-04-10.yml index 67a8d52..6952979 100644 --- a/bapi/2025-04-10.yml +++ b/bapi/2025-04-10.yml @@ -2376,21 +2376,29 @@ paths: You must provide the backup codes in plain format or the corresponding bcrypt digest. public_metadata: type: object - description: Metadata saved on the user, that is visible to both your Frontend and Backend APIs + description: |- + Metadata saved on the user, that is visible to both your Frontend and Backend APIs. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true private_metadata: type: object - description: Metadata saved on the user, that is only visible to your Backend API + description: |- + Metadata saved on the user, that is only visible to your Backend API. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true unsafe_metadata: type: object description: |- Metadata saved on the user, that can be updated from both the Frontend and Backend APIs. Note: Since this data can be modified from the frontend, it is not guaranteed to be safe. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true delete_self_enabled: type: boolean description: If true, the user can delete themselves with the Frontend API. @@ -2734,12 +2742,12 @@ paths: Replace a user's metadata attributes with the provided values. Unlike `PATCH /v1/users/{user_id}/metadata` (merge semantics), this endpoint - replaces the supplied metadata columns entirely — the prior contents of each - supplied column are discarded. Columns omitted from the request body are + replaces the supplied metadata fields entirely — the prior contents of each + supplied field are discarded. Fields omitted from the request body are left unchanged. Prefer the `PATCH` endpoint for partial updates. Use `PUT` only when you - explicitly intend to overwrite a metadata column wholesale. + explicitly intend to overwrite a metadata field wholesale. tags: - Users parameters: @@ -5159,14 +5167,20 @@ paths: properties: public_metadata: type: object - description: Metadata saved on the organization, that is visible to both your frontend and backend. + description: |- + Metadata saved on the organization, that is visible to both your frontend and backend. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/organizations/{organization_id}`. Use `PATCH /v1/organizations/{organization_id}/metadata` to merge updates into existing metadata, or `PUT /v1/organizations/{organization_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true private_metadata: type: object - description: Metadata saved on the organization that is only visible to your backend. + description: |- + Metadata saved on the organization that is only visible to your backend. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/organizations/{organization_id}`. Use `PATCH /v1/organizations/{organization_id}/metadata` to merge updates into existing metadata, or `PUT /v1/organizations/{organization_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true name: type: string description: |- @@ -5201,7 +5215,7 @@ paths: '400': $ref: '#/components/responses/ClerkErrors' '402': - $ref: '#/components/responses/ResourceNotFound' + $ref: '#/components/responses/PaymentRequired' '403': $ref: '#/components/responses/AuthorizationInvalid' '404': @@ -5285,6 +5299,58 @@ paths: $ref: '#/components/responses/ResourceNotFound' '422': $ref: '#/components/responses/UnprocessableEntity' + put: + operationId: ReplaceOrganizationMetadata + x-speakeasy-group: organizations + x-speakeasy-name-override: replaceMetadata + summary: Replace metadata for an organization + description: |- + Replace an organization's metadata attributes with the provided values. + Unlike `PATCH /v1/organizations/{organization_id}/metadata` (merge semantics), this + endpoint replaces the supplied metadata fields entirely — the prior contents of each + supplied field are discarded. Fields omitted from the request body are left unchanged. + Prefer the `PATCH` endpoint for partial updates. Use `PUT` only when you explicitly + intend to overwrite a metadata field wholesale. + tags: + - Organizations + parameters: + - name: organization_id + in: path + description: The ID of the organization whose metadata will be replaced + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + public_metadata: + type: object + description: |- + Metadata saved on the organization, that is visible to both your frontend and backend. + The existing value will be replaced entirely with the new object. + additionalProperties: true + private_metadata: + type: object + description: |- + Metadata saved on the organization that is only visible to your backend. + The existing value will be replaced entirely with the new object. + additionalProperties: true + responses: + '200': + $ref: '#/components/responses/Organization' + '400': + $ref: '#/components/responses/ClerkErrors' + '401': + $ref: '#/components/responses/AuthenticationInvalid' + '404': + $ref: '#/components/responses/ResourceNotFound' + '422': + $ref: '#/components/responses/UnprocessableEntity' /organizations/{organization_id}/logo: put: operationId: UploadOrganizationLogo diff --git a/bapi/2025-11-10.yml b/bapi/2025-11-10.yml index 77c11d2..960a665 100644 --- a/bapi/2025-11-10.yml +++ b/bapi/2025-11-10.yml @@ -2382,21 +2382,29 @@ paths: You must provide the backup codes in plain format or the corresponding bcrypt digest. public_metadata: type: object - description: Metadata saved on the user, that is visible to both your Frontend and Backend APIs + description: |- + Metadata saved on the user, that is visible to both your Frontend and Backend APIs. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true private_metadata: type: object - description: Metadata saved on the user, that is only visible to your Backend API + description: |- + Metadata saved on the user, that is only visible to your Backend API. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true unsafe_metadata: type: object description: |- Metadata saved on the user, that can be updated from both the Frontend and Backend APIs. Note: Since this data can be modified from the frontend, it is not guaranteed to be safe. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/users/{user_id}`. Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true delete_self_enabled: type: boolean description: If true, the user can delete themselves with the Frontend API. @@ -2740,12 +2748,12 @@ paths: Replace a user's metadata attributes with the provided values. Unlike `PATCH /v1/users/{user_id}/metadata` (merge semantics), this endpoint - replaces the supplied metadata columns entirely — the prior contents of each - supplied column are discarded. Columns omitted from the request body are + replaces the supplied metadata fields entirely — the prior contents of each + supplied field are discarded. Fields omitted from the request body are left unchanged. Prefer the `PATCH` endpoint for partial updates. Use `PUT` only when you - explicitly intend to overwrite a metadata column wholesale. + explicitly intend to overwrite a metadata field wholesale. tags: - Users parameters: @@ -5233,14 +5241,20 @@ paths: properties: public_metadata: type: object - description: Metadata saved on the organization, that is visible to both your frontend and backend. + description: |- + Metadata saved on the organization, that is visible to both your frontend and backend. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/organizations/{organization_id}`. Use `PATCH /v1/organizations/{organization_id}/metadata` to merge updates into existing metadata, or `PUT /v1/organizations/{organization_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true private_metadata: type: object - description: Metadata saved on the organization that is only visible to your backend. + description: |- + Metadata saved on the organization that is only visible to your backend. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/organizations/{organization_id}`. Use `PATCH /v1/organizations/{organization_id}/metadata` to merge updates into existing metadata, or `PUT /v1/organizations/{organization_id}/metadata` to replace a metadata field entirely. additionalProperties: true nullable: true + deprecated: true name: type: string description: |- @@ -5275,7 +5289,7 @@ paths: '400': $ref: '#/components/responses/ClerkErrors' '402': - $ref: '#/components/responses/ResourceNotFound' + $ref: '#/components/responses/PaymentRequired' '403': $ref: '#/components/responses/AuthorizationInvalid' '404': @@ -5359,6 +5373,58 @@ paths: $ref: '#/components/responses/ResourceNotFound' '422': $ref: '#/components/responses/UnprocessableEntity' + put: + operationId: ReplaceOrganizationMetadata + x-speakeasy-group: organizations + x-speakeasy-name-override: replaceMetadata + summary: Replace metadata for an organization + description: |- + Replace an organization's metadata attributes with the provided values. + Unlike `PATCH /v1/organizations/{organization_id}/metadata` (merge semantics), this + endpoint replaces the supplied metadata fields entirely — the prior contents of each + supplied field are discarded. Fields omitted from the request body are left unchanged. + Prefer the `PATCH` endpoint for partial updates. Use `PUT` only when you explicitly + intend to overwrite a metadata field wholesale. + tags: + - Organizations + parameters: + - name: organization_id + in: path + description: The ID of the organization whose metadata will be replaced + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + public_metadata: + type: object + description: |- + Metadata saved on the organization, that is visible to both your frontend and backend. + The existing value will be replaced entirely with the new object. + additionalProperties: true + private_metadata: + type: object + description: |- + Metadata saved on the organization that is only visible to your backend. + The existing value will be replaced entirely with the new object. + additionalProperties: true + responses: + '200': + $ref: '#/components/responses/Organization' + '400': + $ref: '#/components/responses/ClerkErrors' + '401': + $ref: '#/components/responses/AuthenticationInvalid' + '404': + $ref: '#/components/responses/ResourceNotFound' + '422': + $ref: '#/components/responses/UnprocessableEntity' /organizations/{organization_id}/logo: put: operationId: UploadOrganizationLogo diff --git a/bapi/2026-05-12.yml b/bapi/2026-05-12.yml index 50228b8..099895c 100644 --- a/bapi/2026-05-12.yml +++ b/bapi/2026-05-12.yml @@ -18,7 +18,7 @@ info: Each version is identified by its release date, e.g. `2025-04-10`. For more information, please see [Clerk API Versions](https://clerk.com/docs/versioning/available-versions). Please see https://clerk.com/docs for more information. - version: '2025-11-10' + version: '2026-05-12' termsOfService: https://clerk.com/terms license: name: MIT @@ -2268,7 +2268,7 @@ paths: You can remove a user's username by setting the username attribute to null or the blank string "". As of API version 2026-05-12, this endpoint no longer accepts `public_metadata`, `private_metadata`, or `unsafe_metadata`. - Use `PATCH /v1/users/{user_id}/metadata` to update metadata fields with merge semantics. + Use `PATCH /v1/users/{user_id}/metadata` to merge updates into existing metadata, or `PUT /v1/users/{user_id}/metadata` to replace a metadata field entirely. tags: - Users parameters: @@ -2711,12 +2711,12 @@ paths: Replace a user's metadata attributes with the provided values. Unlike `PATCH /v1/users/{user_id}/metadata` (merge semantics), this endpoint - replaces the supplied metadata columns entirely — the prior contents of each - supplied column are discarded. Columns omitted from the request body are + replaces the supplied metadata fields entirely — the prior contents of each + supplied field are discarded. Fields omitted from the request body are left unchanged. Prefer the `PATCH` endpoint for partial updates. Use `PUT` only when you - explicitly intend to overwrite a metadata column wholesale. + explicitly intend to overwrite a metadata field wholesale. tags: - Users parameters: @@ -5184,7 +5184,11 @@ paths: x-speakeasy-group: organizations x-speakeasy-name-override: update summary: Update an organization - description: Updates an existing organization + description: |- + Updates an existing organization. + + As of API version 2026-05-12, this endpoint no longer accepts `public_metadata` or `private_metadata`. + Use `PATCH /v1/organizations/{organization_id}/metadata` to merge updates into existing metadata, or `PUT /v1/organizations/{organization_id}/metadata` to replace a metadata field entirely. tags: - Organizations parameters: @@ -5202,16 +5206,6 @@ paths: type: object additionalProperties: false properties: - public_metadata: - type: object - description: Metadata saved on the organization, that is visible to both your frontend and backend. - additionalProperties: true - nullable: true - private_metadata: - type: object - description: Metadata saved on the organization that is only visible to your backend. - additionalProperties: true - nullable: true name: type: string description: |- @@ -5246,7 +5240,7 @@ paths: '400': $ref: '#/components/responses/ClerkErrors' '402': - $ref: '#/components/responses/ResourceNotFound' + $ref: '#/components/responses/PaymentRequired' '403': $ref: '#/components/responses/AuthorizationInvalid' '404': @@ -5330,6 +5324,58 @@ paths: $ref: '#/components/responses/ResourceNotFound' '422': $ref: '#/components/responses/UnprocessableEntity' + put: + operationId: ReplaceOrganizationMetadata + x-speakeasy-group: organizations + x-speakeasy-name-override: replaceMetadata + summary: Replace metadata for an organization + description: |- + Replace an organization's metadata attributes with the provided values. + Unlike `PATCH /v1/organizations/{organization_id}/metadata` (merge semantics), this + endpoint replaces the supplied metadata fields entirely — the prior contents of each + supplied field are discarded. Fields omitted from the request body are left unchanged. + Prefer the `PATCH` endpoint for partial updates. Use `PUT` only when you explicitly + intend to overwrite a metadata field wholesale. + tags: + - Organizations + parameters: + - name: organization_id + in: path + description: The ID of the organization whose metadata will be replaced + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + type: object + additionalProperties: false + properties: + public_metadata: + type: object + description: |- + Metadata saved on the organization, that is visible to both your frontend and backend. + The existing value will be replaced entirely with the new object. + additionalProperties: true + private_metadata: + type: object + description: |- + Metadata saved on the organization that is only visible to your backend. + The existing value will be replaced entirely with the new object. + additionalProperties: true + responses: + '200': + $ref: '#/components/responses/Organization' + '400': + $ref: '#/components/responses/ClerkErrors' + '401': + $ref: '#/components/responses/AuthenticationInvalid' + '404': + $ref: '#/components/responses/ResourceNotFound' + '422': + $ref: '#/components/responses/UnprocessableEntity' /organizations/{organization_id}/logo: put: operationId: UploadOrganizationLogo @@ -18833,7 +18879,6 @@ components: type: integer default: 0 minimum: 0 -x-unreleased: true x-speakeasy-retries: strategy: backoff backoff: diff --git a/fapi/2025-04-10.yml b/fapi/2025-04-10.yml index c023f75..29679d9 100644 --- a/fapi/2025-04-10.yml +++ b/fapi/2025-04-10.yml @@ -3806,7 +3806,10 @@ paths: unsafe_metadata: nullable: true type: string - description: A stringified JSON containing the unsafe metadata of the current user. + description: |- + A stringified JSON containing the unsafe metadata of the current user. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/me`. Use `PATCH /v1/me/metadata` to update `unsafe_metadata`. + deprecated: true responses: '200': $ref: '#/components/responses/Client.ClientWrappedUser' diff --git a/fapi/2025-11-10.yml b/fapi/2025-11-10.yml index 1854988..66800a6 100644 --- a/fapi/2025-11-10.yml +++ b/fapi/2025-11-10.yml @@ -3885,7 +3885,10 @@ paths: unsafe_metadata: nullable: true type: string - description: A stringified JSON containing the unsafe metadata of the current user. + description: |- + A stringified JSON containing the unsafe metadata of the current user. + Deprecated: As of API version 2026-05-12, this field is rejected on `PATCH /v1/me`. Use `PATCH /v1/me/metadata` to update `unsafe_metadata`. + deprecated: true responses: '200': $ref: '#/components/responses/Client.ClientWrappedUser' diff --git a/fapi/2026-05-12.yml b/fapi/2026-05-12.yml index a865eec..9dae0df 100644 --- a/fapi/2026-05-12.yml +++ b/fapi/2026-05-12.yml @@ -5875,7 +5875,8 @@ paths: $ref: '#/components/responses/ClerkErrors' '422': $ref: '#/components/responses/ClerkErrors' - /v1/organizations/{organization_id}/domains/attempt_ownership_verification: {} + /v1/organizations/{organization_id}/domains/bulk: {} + /v1/organizations/{organization_id}/domains/attempt_ownership_verification/bulk: {} /v1/organizations/{organization_id}/domains/{domain_id}: get: summary: Get Organization Domain @@ -14260,7 +14261,6 @@ components: required: false schema: type: boolean -x-unreleased: true x-tagGroups: - name: Environment tags: