Back to Skills

clerk-backend-api

Clerk Backend REST API explorer and executor. Browse tags, inspect endpoint schemas, and execute authenticated requests. Use when listing users, managing organizations, or calling any Clerk API endpoint.

40stars2forksUpdated 5/6/2026

Security Assessment

High Risk(40/100)

Detected risks:

Remote Code Execution([SKILL.md] curl -s https://raw.githubusercontent.com/clerk/openapi-specs/main/bapi/${version_name} | bash)
Sensitive File Access([SKILL.md] .env)
Security Score40/100

About clerk-backend-api

The `clerk-backend-api` skill provides a robust interface for interacting with Clerk's Backend REST API, enabling users to browse API tags, inspect endpoint schemas, and execute authenticated requests. It is specifically designed to streamline backend operations for managing users, organizations, and other resources within the Clerk ecosystem. By centralizing API interactions, it helps developers reduce manual API calls and ensures that requests are executed with proper authentication and scope validation, which is critical for secure backend operations.

Key features of this skill include fast-path templates for common operations such as creating organizations, inviting members, and updating user metadata. It provides explicit safeguards for write operations, including mandatory checks for `CLERK_SECRET_KEY` and `CLERK_BAPI_SCOPES`, as well as irreversible action warnings for DELETE requests. The skill supports both direct Bash command execution and SDK usage for Next.js or TypeScript projects, allowing developers to integrate these operations into their applications seamlessly. Metadata operations are handled with clear guidance on public, private, and unsafe metadata types, ensuring proper usage and access control.

This skill is ideal for backend developers, system administrators, and DevOps engineers who need to manage Clerk users and organizations efficiently. Typical use cases include automating organization setup, inviting and managing members, updating user attributes or metadata, and performing administrative tasks that require secure, authenticated API access. Its design emphasizes both safety and flexibility, making it suitable for teams working on internal tools, SaaS platforms, or any application that integrates deeply with Clerk's backend services.

FAQ

What is required to use the `clerk-backend-api` skill?

You need a valid `CLERK_SECRET_KEY` with the appropriate permissions. For write operations, ensure your `CLERK_BAPI_SCOPES` include the necessary write permissions or use the `--admin` flag to bypass scope restrictions.

Which programming environments are compatible with this skill?

The skill supports direct Bash execution for CLI usage, and SDK usage for Next.js and TypeScript projects via `@clerk/nextjs` or `@clerk/backend`.

How does the skill handle irreversible actions?

For DELETE requests, the skill issues explicit warnings listing all data that will be permanently destroyed and requires user confirmation before proceeding.

What types of metadata can be updated using this skill?

Three types of metadata are supported: Public metadata (readable by client and server), Private metadata (server-only), and Unsafe metadata. Users must select the appropriate type based on access requirements and use case.

Can this skill be used for read-only operations?

Yes, you can browse API endpoints, inspect schemas, and execute GET requests without requiring write permissions. Write safeguards only apply to POST, PATCH, PUT, or DELETE operations.

All Files

7 files
SKILL.md15.8 KB
View
evals/evals.json4.6 KB
View
scripts/api-specs-context.sh0.9 KB
View
scripts/execute-request.sh2.3 KB
View
scripts/extract-tags.js0.4 KB
View
scripts/extract-endpoint-detail.sh5.1 KB
View
scripts/extract-tag-endpoints.sh5.8 KB
View

Install clerk-backend-api

Download and extract the skill files to your .claude/skills/ directory.

Quick Setup:

  1. Copy the skill folder to .claude/skills/
  2. Claude will automatically detect and use the skill

Repository

clerk/skills