Clerk

Clerk Platform API

The Clerk REST Platform API, for programmatic management of resources of a workspace. > [!note] > This API is currently in private beta. If you'd like access…

Identity & security#openapi

Fork copies the collection into your workspace, without the publisher's secrets, so you can add your own key and send requests. Star saves it to your starred APIs (Account › Marketplace) and helps others find it.

Overview

The Clerk REST Platform API, for programmatic management of resources of a workspace.

> [!note]
> This API is currently in private beta. If you'd like access for your workspace, please fill out and submit our request form.

Endpoints 72

Applications

  • GETList applications/platform/applications?include_secret_keys=false&paginated=false&limit=500&starting_after=string&ending_before=stringList applications, newest first. Without paginated, the response is an array of up to limit applications and does not say whether more exist. To walk every…
  • POSTCreate an application/platform/applicationsCreate a new application.
  • GETGet an application/platform/applications/:applicationID?include_secret_keys=falseGet application details.
  • DELETEDelete an application/platform/applications/:applicationIDDelete an application.
  • PATCHUpdate an application/platform/applications/:applicationIDUpdate an application.
  • POSTUpload application logo/platform/applications/:applicationID/logoSet or replace an application's logo by uploading an image file.
  • DELETEDelete application logo/platform/applications/:applicationID/logoDelete an application's logo.
  • POSTUpload application favicon/platform/applications/:applicationID/faviconSet or replace an application's favicon by uploading an image file.
  • DELETEDelete application favicon/platform/applications/:applicationID/faviconDelete an application's favicon.
  • POSTRotate application secret keys/platform/applications/:applicationID/rotate_secret_keysRotate the secret keys for an application's instances.
  • POSTRotate instance secret key/platform/applications/:applicationID/instances/:envOrInsID/rotate_secret_keysRotate the secret key for a single application instance.
  • GETGet instance usage/platform/applications/:applicationID/instances/:envOrInsID/usage?start=2024-01-01&end=2024-01-01Get usage totals for an application instance across meters such as MAU, MAO, SMS, custom domains, and enterprise connections. The envOrInsID parameter can be…
  • POSTCreate instance/platform/applications/:applicationID/instancesCreates a production instance for the given application. Optionally clones configuration from an existing development instance.
  • POSTClaim an accountless application/platform/accountless_applications/claimClaim an accountless application by assigning it to the authenticated principal's workspace. The application is identified by a single-use claim token that…

Principal

  • GETGet the authenticated principal/platform/meDescribe the credential that authenticated this request: its auth strategy, subject (workspace), actor, and granted scopes. Requires no scopes and has no side…

Domains

  • PATCHUpdate application domain/platform/applications/:applicationID/domainUpdate the production domain for an application.
  • GETList application domains/platform/applications/:applicationID/domainsList all domains for an application's production instance.
  • POSTCreate application domain/platform/applications/:applicationID/domainsCreate a provider domain for an application's production instance.
  • GETGet application domain/platform/applications/:applicationID/domains/:domainIDOrNameGet domain information for an application.
  • DELETEDelete application domain/platform/applications/:applicationID/domains/:domainIDOrNameDelete a provider domain from an application's production instance. Only provider domains can be deleted. The primary domain cannot be deleted.
  • GETGet application domain status/platform/applications/:applicationID/domains/:domainIDOrName/statusGet the status of a domain for an application.
  • POSTTrigger DNS check/platform/applications/:applicationID/domains/:domainIDOrName/dns_checkTriggers a DNS check for a domain and returns the current domain status. This endpoint ensures that at most one DNS check job is in-flight at any time. If a…
  • GETList domains/platform/domains?name=string&include_development=true&limit=10&starting_after=string&ending_before=stringList production instance domains for applications in the authenticated workspace. Results are sorted by domain creation time in descending order (most recent…
  • GETGet domain/platform/domains/:domainIDOrNameRetrieve a single domain by ID or name for the authenticated workspace.

Domain Intents

  • GETList domain intents/platform/domain_intents?name=string&status=pending&limit=10&starting_after=string&ending_before=stringList all domain intents created by the authenticated workspace. Returns intents sorted by creation date in descending order (most recent first).
  • POSTCreate a domain intent/platform/domain_intentsCreate a pending domain intent and receive DNS records for the domain name.
  • GETGet a domain intent/platform/domain_intents/:domainIntentIDRetrieve a domain intent by ID.
  • DELETECancel a domain intent/platform/domain_intents/:domainIntentIDCancel a pending domain intent.

Application Transfers

  • GETList application transfers/platform/application_transfers?status=pending&limit=10&starting_after=string&ending_before=stringList all transfer requests created by the authenticated workspace. Returns transfers sorted by creation date in descending order (most recent first). Use the…
  • POSTCreate an application transfer/platform/applications/:applicationID/transfersCreate a new transfer request for an application. This initiates the process of transferring ownership of the application to another workspace. Only one…
  • GETGet an application transfer/platform/applications/:applicationID/transfers/:transferIDRetrieve details of an application transfer by its ID.
  • DELETECancel an application transfer/platform/applications/:applicationID/transfers/:transferIDCancel an existing application transfer. Only transfers in 'pending' status can be canceled.

Users

  • GETList instance users/platform/applications/:applicationID/instances/:envOrInsID/users?query=string&order_by=-created_at&limit=10&offset=0&pagination=offset&starting_after=stringList all users for an application instance. The envOrInsID parameter can be either an environment type (e.g., "development", "production") or an instance ID.…
  • POSTCreate an instance user/platform/applications/:applicationID/instances/:envOrInsID/usersCreates a user within an application instance. The envOrInsID parameter can be either an environment type (e.g., "development", "production") or an instance…
  • DELETEDelete a user/platform/applications/:applicationID/instances/:envOrInsID/users/:userIDDelete a user within an application instance. Returns the deleted user object. Deleting a user that does not exist (or has already been deleted) returns 404.…
  • PATCHUpdate an instance user/platform/applications/:applicationID/instances/:envOrInsID/users/:userIDUpdates identity and client trust settings using Backend API validation and user.updated events. Only first_name, last_name, username, external_id, locale,…
  • PATCHUpdate user metadata/platform/applications/:applicationID/instances/:envOrInsID/users/:userID/metadataDeep-merge the supplied public, private and unsafe metadata into a user in the selected instance. Existing nested objects merge recursively, removing…
  • POSTUpdate a user profile image/platform/applications/:applicationID/instances/:envOrInsID/users/:userID/profile_imageSets or replaces the profile image for a user within an application instance. The envOrInsID parameter can be either an environment type (e.g., "development",…
  • DELETEDelete a user profile image/platform/applications/:applicationID/instances/:envOrInsID/users/:userID/profile_imageDeletes the profile image for a user within an application instance. The envOrInsID parameter can be either an environment type (e.g., "development",…
  • POSTBan a user/platform/applications/:applicationID/instances/:envOrInsID/users/:userID/banMarks a user as banned within an application instance. This terminates their active sessions (marks them as revoked), revokes their OAuth grants, and prevents…
  • POSTUnban a user/platform/applications/:applicationID/instances/:envOrInsID/users/:userID/unbanRemoves the ban from a user within an application instance. This allows them to sign in again. Requires the users:manage scope.

Instance Organizations

  • GETList a user's organization memberships/platform/applications/:applicationID/instances/:envOrInsID/users/:userID/organization_memberships?limit=10&offset=0Returns the Backend API membership objects, including roles, permissions, nested organizations, public user data, and organization and membership private…
  • GETList members of an organization in an application instance/platform/applications/:applicationID/instances/:envOrInsID/organizations/:organizationID/memberships?order_by=string&user_id=string&email_address=string&phone_number=string&username=string&web3_wallet=string&role=string&query=string&email_address_query=string&phone_number_query=string&username_query=string&name_query=string&last_active_at_before=1700690400000&last_active_at_after=1700690400000&created_at_before=1730160000000&created_at_after=1730160000000&limit=10&offset=0Lists memberships with roles, permissions, organization and public user data. Supports Backend API membership filters and pagination, and returns the same…
  • GETList organizations in an application instance/platform/applications/:applicationID/instances/:envOrInsID/organizations?include_members_count=true&include_missing_member_with_elevated_permissions=true&query=string&user_id=string&organization_id=string&order_by=-created_at&limit=10&offset=0&name=string&slug=string&created_at_before=string&created_at_after=string&filter_by=stringList or search organizations belonging to an application instance, rather than Clerk workspaces. Supports the Backend API organization-list filters and…

JWT Templates

  • GETList JWT templates/platform/applications/:applicationID/instances/:envOrInsID/jwt_templatesList all JWT templates for an application instance. Requires the jwt_templates:read scope.
  • POSTCreate a JWT template/platform/applications/:applicationID/instances/:envOrInsID/jwt_templatesCreate a new JWT template for an application instance. Requires the jwt_templates:manage scope.
  • GETGet a JWT template/platform/applications/:applicationID/instances/:envOrInsID/jwt_templates/:templateIDRetrieve a specific JWT template for an application instance. Requires the jwt_templates:read scope.
  • DELETEDelete a JWT template/platform/applications/:applicationID/instances/:envOrInsID/jwt_templates/:templateIDDelete a JWT template from an application instance. Requires the jwt_templates:manage scope.
  • PATCHUpdate a JWT template/platform/applications/:applicationID/instances/:envOrInsID/jwt_templates/:templateIDUpdate an existing JWT template for an application instance. Requires the jwt_templates:manage scope.

Redirect URLs

  • GETList redirect URLs/platform/applications/:applicationID/instances/:envOrInsID/redirect_urls?limit=10&offset=0List all redirect URLs for an application instance. The envOrInsID parameter can be either an environment type (e.g., "development", "production") or an…
  • POSTCreate a redirect URL/platform/applications/:applicationID/instances/:envOrInsID/redirect_urlsCreate a redirect URL for an application instance. The envOrInsID parameter can be either an environment type (e.g., "development", "production") or an…
  • GETGet a redirect URL/platform/applications/:applicationID/instances/:envOrInsID/redirect_urls/:redirectURLIDRetrieve a redirect URL for an application instance. The envOrInsID parameter can be either an environment type (e.g., "development", "production") or an…
  • DELETEDelete a redirect URL/platform/applications/:applicationID/instances/:envOrInsID/redirect_urls/:redirectURLIDDelete a redirect URL from an application instance. The envOrInsID parameter can be either an environment type (e.g., "development", "production") or an…

Native Applications

  • GETGet native settings/platform/applications/:applicationID/instances/:envOrInsID/native_settingsRetrieve Native API settings for an application instance. The envOrInsID parameter can be either an environment type (for example, development or production)…
  • PATCHUpdate native settings/platform/applications/:applicationID/instances/:envOrInsID/native_settingsUpdate Native API settings for an application instance. The envOrInsID parameter can be either an environment type (for example, development or production) or…
  • GETList Android native applications/platform/applications/:applicationID/instances/:envOrInsID/native_applications/androidList the Android applications registered with an application instance. The envOrInsID parameter can be either an environment type (for example, development or…
  • POSTCreate an Android native application/platform/applications/:applicationID/instances/:envOrInsID/native_applications/androidRegister an Android application with an application instance. The envOrInsID parameter can be either an environment type (for example, development or…
  • GETList iOS native applications/platform/applications/:applicationID/instances/:envOrInsID/native_applications/iosList the iOS applications registered with an application instance. The envOrInsID parameter can be either an environment type (for example, development or…
  • POSTCreate an iOS native application/platform/applications/:applicationID/instances/:envOrInsID/native_applications/iosRegister an iOS application with an application instance. The envOrInsID parameter can be either an environment type (for example, development or production)…

OAuth

  • GETList OAuth resources/platform/applications/:applicationID/instances/:envOrInsID/oauth_resources?limit=10&offset=0&oauth_application_id=string&mcp_server=trueList the OAuth protected resources registered on an application instance, including MCP servers. The envOrInsID parameter can be either an environment type…
  • POSTCreate an OAuth resource/platform/applications/:applicationID/instances/:envOrInsID/oauth_resourcesRegister an OAuth protected resource on an application instance. To register an MCP server, pass its canonical URL as uri and set mcp_server to true.…
  • GETGet an OAuth resource/platform/applications/:applicationID/instances/:envOrInsID/oauth_resources/:oauthResourceIDRetrieve one OAuth protected resource registered on an application instance. The envOrInsID parameter can be either an environment type (e.g., "development",…
  • DELETEDelete an OAuth resource/platform/applications/:applicationID/instances/:envOrInsID/oauth_resources/:oauthResourceIDDelete an OAuth protected resource. Deleting a resource removes it from every OAuth application's token exchange targets. Audience URIs reserved by an OAuth…
  • PATCHUpdate an OAuth resource/platform/applications/:applicationID/instances/:envOrInsID/oauth_resources/:oauthResourceIDUpdate the name, scopes, or MCP server marker of an OAuth protected resource. The URI is create-only; delete and recreate the resource to change it. The…
  • GETGet OAuth application settings/platform/applications/:applicationID/instances/:envOrInsID/oauth_application_settingsRetrieve the instance-wide OAuth authorization server settings, such as audience claims, PKCE, and client registration policy. The envOrInsID parameter can be…
  • PATCHUpdate OAuth application settings/platform/applications/:applicationID/instances/:envOrInsID/oauth_application_settingsUpdate the instance-wide OAuth authorization server settings. Only supplied fields change. An MCP server needs aud_claim_enabled so tokens carry its URL as…

Config

  • GETGet instance config/platform/applications/:applicationID/instances/:envOrInsID/config?keys=stringGet the configuration for an application instance. The envOrInsID parameter can be either an environment type (e.g., "development", "production") or an…
  • PUTReplace instance config/platform/applications/:applicationID/instances/:envOrInsID/config?dry_run=false&destructive=falseReplace the full configuration for an application instance. Unlike PATCH, PUT requires all config keys to be included in the request body. If any keys are…
  • PATCHUpdate instance config/platform/applications/:applicationID/instances/:envOrInsID/config?dry_run=false&destructive=false&keys=stringUpdate the configuration for an application instance. The envOrInsID parameter can be either an environment type (e.g., "development", "production") or an…
  • GETGet instance config schema/platform/applications/:applicationID/instances/:envOrInsID/config/schema?keys=stringGet the JSON Schema for the instance configuration. The envOrInsID parameter can be either an environment type (e.g., "development", "production") or an…

Application Logs

  • GETList grouped application logs/platform/applications/:applicationID/instances/:envOrInsID/logs?user_id=string&identifier=string&type=string&actor=string&subject=string&trace_id=string&session_id=string&client_id=string&impersonator_user_id=string&ip_address=string&filter_match=all&event_time_after=0&event_time_before=0&limit=10&starting_after=string&group_type=sign_in&status=completedReturns groups and standalone events, newest first. Groups sort by their start time. Event filters retain groups and restrict their event previews;…
  • GETList events in an application log group/platform/applications/:applicationID/instances/:envOrInsID/logs/groups/:groupID/events?user_id=string&identifier=string&type=string&actor=string&subject=string&trace_id=string&session_id=string&client_id=string&impersonator_user_id=string&ip_address=string&filter_match=all&event_time_after=0&event_time_before=0&limit=10&starting_after=string&started_at=0Returns matching events oldest first. Pass the group started_at and events_cursor as starting_after, retaining the original event filters. List cursors cannot…

API details

Base URL
https://api.clerk.com/v1
Authentication
A bearer token in the Authorization header
Operations
72 operations on 45 pathsGET 31POST 20DELETE 11PATCH 9PUT 1
Main resources
Applications 14Domains 9Users 9OAuth 7Native Applications 6JWT Templates 5Application Transfers 4Config 4Domain Intents 4Redirect URLs 4
Response formats
application/json
Description format
OpenAPI 3.0.3, API version BETA

How to test the Clerk Platform API in Swastik Codes

  1. Open the APISelect “Fork & run in Swastik Codes” on this page. Sign in or create a free account if asked.
  2. Fork it into your workspaceChoose a workspace. You get your own copy of the Clerk Platform API collection, without the publisher's secrets.
  3. Add your credentialsThis API uses A bearer token in the Authorization header. Add yours in the collection's variables or an environment; the requests already reference it.
  4. Send a requestPick an endpoint, for example “List applications” (GET /platform/applications?include_secret_keys=false&paginated=false&limit=500&starting_after=string&ending_before=string), and press Send. Check the response, add tests and run the whole collection with the runner.

Frequently asked questions

What is the Clerk Platform API?

The Clerk REST Platform API, for programmatic management of resources of a workspace. > [!note] > This API is currently in private beta. If you'd like access… It is listed under Identity & security and has 72 endpoints.

Who publishes the Clerk Platform API?

It is listed from Clerk's public API description (an OpenAPI document), not published by Clerk on Swastik Codes. Anyone who controls clerk.com can claim the profile by adding a DNS TXT record.

What is the base URL of the Clerk Platform API?

Requests go to https://api.clerk.com/v1. Endpoint paths are added to this base URL.

How do I authenticate with the Clerk Platform API?

With A bearer token in the Authorization header.

How many endpoints does the Clerk Platform API have?

72 operations on 45 paths (31 GET, 20 POST, 11 DELETE, 9 PATCH, 1 PUT). The largest groups are Applications, Domains, Users, OAuth.

Is forking the Clerk Platform API free?

Yes. Forking copies the collection into your workspace for free. It has been starred 0 times and forked 0 times.

Suggest an API

Tell us which public API is missing. We check it, then add it here with its endpoints when it has an OpenAPI (Swagger) description.