# Unkey Docs ## Docs - [Using Cursor with Unkey](https://unkey.com/docs/ai-code-gen/cursor.md): Leverage Cursor's AI capabilities to build applications with Unkey's APIs - [AI Code Gen with Unkey](https://unkey.com/docs/ai-code-gen/overview.md): Use AI-powered code generation tools with Unkey's APIs and services - [Unkey MCP (Model Context Protocol)](https://unkey.com/docs/ai-code-gen/unkey-mcp.md): Connect AI tools to Unkey's APIs using Model Context Protocol - [Using Windsurf with Unkey](https://unkey.com/docs/ai-code-gen/windsurf.md): Build applications with Windsurf's AI-powered development environment and Unkey's APIs - [Overview](https://unkey.com/docs/analytics/overview.md): Unkey tracks everything for you - [Quickstarts](https://unkey.com/docs/analytics/quickstarts.md): Power your own dashboard, reports or usage-based billing - [Get Verifications](https://unkey.com/docs/api-reference/analytics/get_verifications.md) - [Create an API](https://unkey.com/docs/api-reference/apis/create.md) - [Delete an API](https://unkey.com/docs/api-reference/apis/delete.md): Permanently delete an API and revoke all keys associated with it - [Delete all keys of an API](https://unkey.com/docs/api-reference/apis/delete-keys.md) - [Retrieve an API](https://unkey.com/docs/api-reference/apis/get.md) - [List keys for an API](https://unkey.com/docs/api-reference/apis/list-keys.md) - [Authentication](https://unkey.com/docs/api-reference/authentication.md): Securely authenticating with the Unkey API - [Overview](https://unkey.com/docs/api-reference/errors-v2/overview.md): Understanding Unkey's structured error system - [err:unkey:application:assertion_failed](https://unkey.com/docs/api-reference/errors-v2/unkey/application/assertion_failed.md): A runtime assertion or invariant check failed - [err:unkey:application:invalid_input](https://unkey.com/docs/api-reference/errors-v2/unkey/application/invalid_input.md): Client provided input that failed validation - [err:unkey:application:protected_resource](https://unkey.com/docs/api-reference/errors-v2/unkey/application/protected_resource.md): Attempt to modify a protected resource - [err:unkey:application:service_unavailable](https://unkey.com/docs/api-reference/errors-v2/unkey/application/service_unavailable.md): A service is temporarily unavailable - [err:unkey:application:unexpected_error](https://unkey.com/docs/api-reference/errors-v2/unkey/application/unexpected_error.md): An unhandled or unexpected error occurred - [err:unkey:authentication:key_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/authentication/key_not_found.md): The authentication key was not found - [err:unkey:authentication:malformed](https://unkey.com/docs/api-reference/errors-v2/unkey/authentication/malformed.md): Authentication credentials were incorrectly formatted - [err:unkey:authentication:missing](https://unkey.com/docs/api-reference/errors-v2/unkey/authentication/missing.md): Authentication credentials were not provided in the request - [err:unkey:authorization:forbidden](https://unkey.com/docs/api-reference/errors-v2/unkey/authorization/forbidden.md): The operation is not allowed - [err:unkey:authorization:insufficient_permissions](https://unkey.com/docs/api-reference/errors-v2/unkey/authorization/insufficient_permissions.md): The authenticated entity lacks sufficient permissions for the requested operation - [err:unkey:authorization:key_disabled](https://unkey.com/docs/api-reference/errors-v2/unkey/authorization/key_disabled.md): The authentication key is disabled - [err:unkey:authorization:workspace_disabled](https://unkey.com/docs/api-reference/errors-v2/unkey/authorization/workspace_disabled.md): The associated workspace is disabled - [err:unkey:data:api_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/data/api_not_found.md): The requested API was not found - [err:unkey:data:audit_log_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/data/audit_log_not_found.md): The requested audit log was not found - [err:unkey:data:identity_already_exists](https://unkey.com/docs/api-reference/errors-v2/unkey/data/identity_already_exists.md): The requested identity already exists - [err:unkey:data:identity_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/data/identity_not_found.md): The requested identity was not found - [err:unkey:data:key_auth_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/data/key_auth_not_found.md): The requested key authentication was not found - [err:unkey:data:key_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/data/key_not_found.md): The requested key was not found - [err:unkey:data:permission_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/data/permission_not_found.md): The requested permission was not found - [err:unkey:data:ratelimit_namespace_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/data/ratelimit_namespace_not_found.md): The requested rate limit namespace was not found - [err:unkey:data:ratelimit_override_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/data/ratelimit_override_not_found.md): The requested rate limit override was not found - [err:unkey:data:role_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/data/role_not_found.md): The requested role was not found - [err:unkey:data:workspace_not_found](https://unkey.com/docs/api-reference/errors-v2/unkey/data/workspace_not_found.md): The requested workspace was not found - [INSUFFICIENT_PERMISSIONS](https://unkey.com/docs/api-reference/errors/code/BAD_REQUEST.md) - [CONFLICT](https://unkey.com/docs/api-reference/errors/code/CONFLICT.md) - [DELETE_PROTECTED](https://unkey.com/docs/api-reference/errors/code/DELETE_PROTECTED.md) - [DISABLED](https://unkey.com/docs/api-reference/errors/code/DISABLED.md) - [EXPIRED](https://unkey.com/docs/api-reference/errors/code/EXPIRED.md) - [FORBIDDEN](https://unkey.com/docs/api-reference/errors/code/FORBIDDEN.md) - [INSUFFICIENT_PERMISSIONS](https://unkey.com/docs/api-reference/errors/code/INSUFFICIENT_PERMISSIONS.md) - [INTERNAL_SERVER_ERROR](https://unkey.com/docs/api-reference/errors/code/INTERNAL_SERVER_ERROR.md) - [NOT_FOUND](https://unkey.com/docs/api-reference/errors/code/NOT_FOUND.md) - [TOO_MANY_REQUESTS](https://unkey.com/docs/api-reference/errors/code/TOO_MANY_REQUESTS.md) - [UNAUTHORIZED](https://unkey.com/docs/api-reference/errors/code/UNAUTHORIZED.md) - [Introduction](https://unkey.com/docs/api-reference/errors/introduction.md): Machine and human readable error codes - [Create an identity](https://unkey.com/docs/api-reference/identities/create-identity.md) - [Delete an identity](https://unkey.com/docs/api-reference/identities/delete-identity.md) - [Get an identity](https://unkey.com/docs/api-reference/identities/get-identity.md) - [List identities](https://unkey.com/docs/api-reference/identities/list-identities.md) - [Update an identity](https://unkey.com/docs/api-reference/identities/update-identity.md) - [Add Permissions](https://unkey.com/docs/api-reference/keys/add-permissions.md): Add one or more permissions to a key. - [Add Roles](https://unkey.com/docs/api-reference/keys/add-roles.md): Add one or more roles to a key. - [Create a key](https://unkey.com/docs/api-reference/keys/create.md) - [Delete a key](https://unkey.com/docs/api-reference/keys/delete.md): Deleted keys are no longer valid and will not be able to be used to authenticate requests. - [Retrieve a key by ID](https://unkey.com/docs/api-reference/keys/get.md) - [Remove Permissions](https://unkey.com/docs/api-reference/keys/remove-permissions.md): Remove one or more permissions from a key. - [Remove Roles](https://unkey.com/docs/api-reference/keys/remove-roles.md): Remove one or more roles from a key. - [Set Permissions](https://unkey.com/docs/api-reference/keys/set-permissions.md): Overwrite the permissions of a key with a new set of permissions. - [Set Roles](https://unkey.com/docs/api-reference/keys/set-roles.md): Overwrite the roles of a key with a new set of roles. - [Update a key](https://unkey.com/docs/api-reference/keys/update.md): Updates the configuration of an existing key. Omit fields to leave unchanged. - [Update a key's remaining limit](https://unkey.com/docs/api-reference/keys/update-remaining.md) - [Verify a key](https://unkey.com/docs/api-reference/keys/verify.md) - [Returns data about a key](https://unkey.com/docs/api-reference/keys/whoami.md) - [Migrate key to Unkey](https://unkey.com/docs/api-reference/migrations/create-keys.md) - [Overview](https://unkey.com/docs/api-reference/overview.md): General information about the API. - [Create A Permission](https://unkey.com/docs/api-reference/permissions/create-permission.md) - [Create A Role](https://unkey.com/docs/api-reference/permissions/create-role.md) - [Delete A Permission](https://unkey.com/docs/api-reference/permissions/delete-permission.md) - [Delete A Role](https://unkey.com/docs/api-reference/permissions/delete-role.md) - [Get Permission](https://unkey.com/docs/api-reference/permissions/get-permission.md) - [Get Role](https://unkey.com/docs/api-reference/permissions/get-role.md) - [List Permissions](https://unkey.com/docs/api-reference/permissions/list-permissions.md) - [List Roles](https://unkey.com/docs/api-reference/permissions/list-roles.md) - [Delete Override](https://unkey.com/docs/api-reference/ratelimits/delete-override.md): Delete an override from the system. - [Get Override](https://unkey.com/docs/api-reference/ratelimits/get-override.md): Retrieve the configured override by `namespaceId` or `namespaceName`. - [Ratelimit](https://unkey.com/docs/api-reference/ratelimits/limit.md): Ratelimit an action based on an identifier. - [List Overrides](https://unkey.com/docs/api-reference/ratelimits/list-overrides.md): Retrieve a list of configured overrides by `namespaceId` or `namespaceName`. - [Set Override](https://unkey.com/docs/api-reference/ratelimits/set-override.md) - [Analytics](https://unkey.com/docs/apis/features/analytics.md): Per key and per API analytics - [Example](https://unkey.com/docs/apis/features/authorization/example.md): RBAC in the almost-real world - [Overview](https://unkey.com/docs/apis/features/authorization/introduction.md): Access Control with Roles and Permissions - [Roles and Permissions](https://unkey.com/docs/apis/features/authorization/roles-and-permissions.md) - [Verifying](https://unkey.com/docs/apis/features/authorization/verifying.md): Verifying permissions through the API - [Disabling Keys](https://unkey.com/docs/apis/features/enabled.md): Enable or disable a key. Disabled keys will not validate. - [Environments](https://unkey.com/docs/apis/features/environments.md): Separate your keys into live and test environments. - [Modes](https://unkey.com/docs/apis/features/ratelimiting/modes.md): Latency or consistency? Choose the right mode for your usecase. - [Overview](https://unkey.com/docs/apis/features/ratelimiting/overview.md): How rate limiting works in unkey - [Refill](https://unkey.com/docs/apis/features/refill.md): Refill remaining key verifications on a set interval - [Usage limited keys](https://unkey.com/docs/apis/features/remaining.md): Limiting the usage of keys - [Key Revocation](https://unkey.com/docs/apis/features/revocation.md): Keys can be revoked at any time, from the API or the dashboard. - [Temporary Keys](https://unkey.com/docs/apis/features/temp-keys.md): How to create temporary API Keys in Unkey - [IP Whitelisting](https://unkey.com/docs/apis/features/whitelist.md): Unkey offers IP whitelisting to restrict requests to a specific set of IP addresses. - [Overview](https://unkey.com/docs/apis/introduction.md): Protect your public APIs - [Overview](https://unkey.com/docs/audit-log/introduction.md): Audit logs for your workspace, allowing you to see the history of all the resource requests made inside your workspace. - [Event Types](https://unkey.com/docs/audit-log/types.md): Available audit log event types - [Overview](https://unkey.com/docs/concepts/identities/overview.md): Identities are a representations of a user, an org or a machine in your application. - [Ratelimits](https://unkey.com/docs/concepts/identities/ratelimits.md): Identities can be used to share ratelimits across multiple keys - [Welcome to Unkey](https://unkey.com/docs/introduction.md): API management redefined - [create_key](https://unkey.com/docs/libraries/ex/functions/create_key.md): Create an api key for your users - [delete_key](https://unkey.com/docs/libraries/ex/functions/delete_key.md): delete a key - [update_key](https://unkey.com/docs/libraries/ex/functions/update_key.md): Updates the configuration of a key - [update_remaining](https://unkey.com/docs/libraries/ex/functions/update_remaining.md): Updates the `remaining` value of a key - [verify_key](https://unkey.com/docs/libraries/ex/functions/verify_key.md): Verify a key - [Overview](https://unkey.com/docs/libraries/ex/overview.md): Elixir client for unkey - [Overview](https://unkey.com/docs/libraries/go/overview.md): Go SDK for Unkey - [Overview](https://unkey.com/docs/libraries/nuxt/overview.md): Nuxt module for unkey - [Async](https://unkey.com/docs/libraries/py/async.md): Using unkey.py synchronous or asynchronous - [Overview](https://unkey.com/docs/libraries/py/overview.md): Developer-friendly & type-safe Python SDK for Unkey's API. - [Apis](https://unkey.com/docs/libraries/py/services/apis.md) - [Identities](https://unkey.com/docs/libraries/py/services/identities.md) - [Keys](https://unkey.com/docs/libraries/py/services/keys.md) - [Migrations](https://unkey.com/docs/libraries/py/services/migrations.md) - [Permissions](https://unkey.com/docs/libraries/py/services/permissions.md) - [Ratelimits](https://unkey.com/docs/libraries/py/services/ratelimits.md) - [Overview](https://unkey.com/docs/libraries/rs/overview.md): Rust client for unkey - [Get API](https://unkey.com/docs/libraries/springboot-java/api/get.md): Retrieve information about an API - [List Keys](https://unkey.com/docs/libraries/springboot-java/api/list.md): List API keys - [Create](https://unkey.com/docs/libraries/springboot-java/functions/create.md): Create an api key for your users - [revoke](https://unkey.com/docs/libraries/springboot-java/functions/revoke.md): Revoke an api key - [Update](https://unkey.com/docs/libraries/springboot-java/functions/update.md): Update an api key - [Verify](https://unkey.com/docs/libraries/springboot-java/functions/verify.md): Verify an api key - [Overview](https://unkey.com/docs/libraries/springboot-java/overview.md): Spring Boot client for unkey - [@unkey/cache](https://unkey.com/docs/libraries/ts/cache/overview.md): Cache middleware with types - [@unkey/hono](https://unkey.com/docs/libraries/ts/hono.md): Hono.js middleware for authenticating API keys - [@unkey/nextjs](https://unkey.com/docs/libraries/ts/nextjs.md): Next.js SDK for Unkey - [Delete Override](https://unkey.com/docs/libraries/ts/ratelimit/override/delete-override.md): Deletes an override - [Get Override](https://unkey.com/docs/libraries/ts/ratelimit/override/get-override.md): Gets a ratelimit override - [List Overrides](https://unkey.com/docs/libraries/ts/ratelimit/override/list-overrides.md): Lists all overrides - [Overview](https://unkey.com/docs/libraries/ts/ratelimit/override/overview.md): Ratelimit overrides - [Set Override](https://unkey.com/docs/libraries/ts/ratelimit/override/set-override.md): Sets an override for a ratelimit - [Ratelimit](https://unkey.com/docs/libraries/ts/ratelimit/ratelimit.md): Serverless ratelimiting - [Get Verifications](https://unkey.com/docs/libraries/ts/sdk/analytics/get.md): Retrieve usage data from unkey to power your dashboards, reports or usage-based billing. - [Create](https://unkey.com/docs/libraries/ts/sdk/apis/create.md): Create a new API - [Delete](https://unkey.com/docs/libraries/ts/sdk/apis/delete.md): Permanently delete an API and revoke all keys associated with it. - [Get](https://unkey.com/docs/libraries/ts/sdk/apis/get.md): Retrieve the configuration of an API - [List Keys](https://unkey.com/docs/libraries/ts/sdk/apis/list-keys.md): Get a list of keys belonging to an API - [Create An Identity](https://unkey.com/docs/libraries/ts/sdk/identities/create-identity.md): Create a new identity in the system. This might not be necessary as newly created keys automatically create an identity if required. - [Delete An Identity](https://unkey.com/docs/libraries/ts/sdk/identities/delete-identity.md): Delete an identity. This will not revoke the keys associated with the identity. - [Get An Identity](https://unkey.com/docs/libraries/ts/sdk/identities/get-identity.md): Retrieve an identity from the Unkey system - [List Identities](https://unkey.com/docs/libraries/ts/sdk/identities/list-identity.md): List all identities associated with your workspace - [Update An Identity](https://unkey.com/docs/libraries/ts/sdk/identities/update-identity.md): Update a current identity in the system. - [Add Permissions](https://unkey.com/docs/libraries/ts/sdk/keys/add-permission.md): Add one or more permissions to a key. - [Add Roles](https://unkey.com/docs/libraries/ts/sdk/keys/add-roles.md): Add one or more roles to a key. - [Create](https://unkey.com/docs/libraries/ts/sdk/keys/create.md): Create an api key for your users - [Delete](https://unkey.com/docs/libraries/ts/sdk/keys/delete.md): Delete an api key for your users - [Get](https://unkey.com/docs/libraries/ts/sdk/keys/get.md): Get the configuration for an api key - [Remove Permissions](https://unkey.com/docs/libraries/ts/sdk/keys/remove-permission.md): Remove one or more permissions from a key. - [Remove Roles](https://unkey.com/docs/libraries/ts/sdk/keys/remove-roles.md): Remove one or more roles from a key. - [Set Permissions](https://unkey.com/docs/libraries/ts/sdk/keys/set-permission.md): Overwrite the permissions of a key with a new set of permissions. - [Set Roles](https://unkey.com/docs/libraries/ts/sdk/keys/set-roles.md): Overwrite the roles of a key with a new set of roles. - [Update](https://unkey.com/docs/libraries/ts/sdk/keys/update.md): Update an api key for your users - [Update Remaining](https://unkey.com/docs/libraries/ts/sdk/keys/update-remaining.md): Update the remaining usage of a key. - [Verify](https://unkey.com/docs/libraries/ts/sdk/keys/verify.md): Verify a key - [Migrate key to Unkey](https://unkey.com/docs/libraries/ts/sdk/migrations/migrate-to-unkey.md): Add existing keys to unkey by specifying the key hash and other settings - [Overview](https://unkey.com/docs/libraries/ts/sdk/overview.md): Typescript client for unkey - [Create A Permission](https://unkey.com/docs/libraries/ts/sdk/permissions/create-permission.md): Create a new permission to use with Unkey. - [Create A Role](https://unkey.com/docs/libraries/ts/sdk/permissions/create-role.md): Create a new role to use with Unkey - [Delete A Permission](https://unkey.com/docs/libraries/ts/sdk/permissions/delete-permission.md): Delete a permission from the Unkey system - [Delete A Role](https://unkey.com/docs/libraries/ts/sdk/permissions/delete-role.md): Delete a role from the Unkey system - [Get A Permission](https://unkey.com/docs/libraries/ts/sdk/permissions/get-permission.md): Retrieve a permission from Unkey - [Get A Role](https://unkey.com/docs/libraries/ts/sdk/permissions/get-role.md): Retrieve a role from Unkey - [Limit](https://unkey.com/docs/libraries/ts/sdk/ratelimits/limit.md): Serverless ratelimiting - [Delete Override](https://unkey.com/docs/libraries/ts/sdk/ratelimits/overrides/delete-override.md): Deletes an override - [Get Override](https://unkey.com/docs/libraries/ts/sdk/ratelimits/overrides/get-override.md): Gets a ratelimit override - [List Overrides](https://unkey.com/docs/libraries/ts/sdk/ratelimits/overrides/list-overrides.md): Lists all overrides - [Set Override](https://unkey.com/docs/libraries/ts/sdk/ratelimits/overrides/set-override.md): Sets an override for a ratelimit - [Overview](https://unkey.com/docs/migrations/introduction.md): Migrate your API to Unkey - [Migrate keys to Unkey](https://unkey.com/docs/migrations/keys.md) - [Bun](https://unkey.com/docs/quickstart/apis/bun.md): Authentication for Bun's http server - [Express](https://unkey.com/docs/quickstart/apis/express.md): Authentication for your Express server - [Hono](https://unkey.com/docs/quickstart/apis/hono.md): API Authentication in Hono - [Next.js](https://unkey.com/docs/quickstart/apis/nextjs.md): API Authentication in Next.js - [Quickstart](https://unkey.com/docs/quickstart/identities/shared-ratelimits.md): Create your first identity and key with Unkey - [Public API Protection](https://unkey.com/docs/quickstart/onboarding/onboarding-api.md): Get started with API keys - [Ratelimiting](https://unkey.com/docs/quickstart/onboarding/onboarding-ratelimiting.md): Get started with standalone ratelimiting - [Bun](https://unkey.com/docs/quickstart/ratelimiting/bun.md): Ratelimiting endpoints with Bun's http server - [Express](https://unkey.com/docs/quickstart/ratelimiting/express.md): Ratelimiting endpoints with Express - [Hono](https://unkey.com/docs/quickstart/ratelimiting/hono.md): Ratelimiting endpoints with Hono - [Next.js](https://unkey.com/docs/quickstart/ratelimiting/nextjs.md): Ratelimiting endpoints with Next.js - [Automated Overrides](https://unkey.com/docs/ratelimiting/automated-overrides.md): Manage dynamic overrides programmatically - [Overview](https://unkey.com/docs/ratelimiting/introduction.md): Ratelimit your serverless functions. - [Consistency vs Latency](https://unkey.com/docs/ratelimiting/modes.md): Optimize for consistency or latency with different ratelimiting modes. - [Custom overrides](https://unkey.com/docs/ratelimiting/overrides.md): Override limits for identifiers without code changes. - [Delete Protection](https://unkey.com/docs/security/delete-protection.md): Prevents an resource from being deleted when enabled. - [GitHub Secret Scanning](https://unkey.com/docs/security/github-scanning.md): How Unkey protects you from leaked root keys - [Overview](https://unkey.com/docs/security/overview.md): How does Unkey work? What security measures are in place? - [Recovering Keys](https://unkey.com/docs/security/recovering-keys.md): Show keys again after they are created - [Root Keys](https://unkey.com/docs/security/root-keys.md): Learn how root keys in the Unkey API work ## Optional - [Blog & Tutorials](https://unkey.com/blog) - [Discord](https://unkey.com/discord) - [GitHub](https://github.com/unkeyed)