Skip to main content
commandsSource-backedReview first Safety Privacy

Mintlify Documentation Generator for Claude

Generate beautiful, searchable documentation using Mintlify with AI-powered content generation, API reference automation, and MDX components

by JSONbored·added 2025-10-16·
HarnessClaude Code
Invocation:/mintlify-docs [options] <documentation_scope>
Review first review before installing

Open the source and read safety notes before installing.

Citation facts

Source-backed facts for citing this resource, derived directly from the registry — also available as plain text for AI assistants.

Source URLs
https://mintlify.com/docs, https://github.com/JSONbored/awesome-claude/blob/main/content/commands/mintlify-docs.mdx
Safety notes
Review generated changes and commands before applying them; slash commands can ask the agent to read, write, edit, or run tools in the current project., Limit scope to the intended files and run in a trusted checkout when the command analyzes code, tests, security findings, or generated output.
Privacy notes
Prompts, source files, logs, errors, dependency metadata, and generated reports may be sent to the configured AI model during command execution., Redact secrets, customer data, private repository details, and proprietary code before sharing command output outside the workspace.
Author
JSONbored
Claim status
unclaimed
Last verified
2025-10-16

Decision playbook

Review trust signals before you adopt

Signals are present but mixed. Use the checklist below to confirm the source and operational safety for your environment.

Compare context
Selected

0

Current score

78

Baseline

Delta

No baseline selected

No major trust-signal divergence detected in the current selection.

Source and provenance checks

Complete

Confirm ownership and provenance before trusting install instructions.

  • Source link availableRequired

    Open the canonical repository and verify ownership.

    Done
  • Source provenance statusRequired

    Marked as source-backed.

    Done
  • Metadata reviewed

    Registry metadata indicates a reviewed listing.

    Done

Safety and privacy checks

Complete

Validate risk disclosures before installation or API wiring.

  • Safety notes presentRequired

    Review the listed safety guidance before running commands.

    Done
  • Privacy notes presentRequired

    Review data handling notes before connecting accounts or secrets.

    Done
  • Trust level risk gateRequired

    Trust level does not block evaluation.

    Done

Package and install checks

Needs review

Check package metadata and artifact integrity signals.

  • Install payload available

    Install or copy payload is available for review.

    Done
  • Package verification flag

    No package verification flag provided.

    Pending
  • Checksum metadata

    No checksum provided for downloaded artifact.

    Pending

Compare-driven decision checks

Needs review

Use compare context to validate trade-offs before adoption.

  • Compare tray has multiple entries

    Add at least one more entry to compare trust differences.

    Pending
  • Baseline comparison available

    No baseline peer selected yet.

    Pending
  • Diverging trust signals identified

    No major trust-signal divergence found.

    Pending

Setup at a glance

CLI install

Copy-ready — paste the snippet to get started.

Install command

Provided

Config snippet

Not provided

Copy snippet

Provided

Prerequisites

None

Platforms

1 listed

Difficulty

100/100

Adoption plan

Balanced adoption plan

Current risk score 16/100. Use staged verification before broader rollout.

Risk 16

Pre-adoption checks

Validate source and review signals before any execution.

  • Confirm source provenanceRequired

    Source URL/provenance metadata is present.

    Done
  • Confirm metadata review state

    Listing has review metadata.

    Done
  • Verify install payload

    Install/config payload exists and can be inspected.

    Done

Security checks

Confirm safety, privacy, and package integrity signals.

  • Review safety notesRequired

    Safety notes are present.

    Done
  • Review privacy notesRequired

    Privacy notes are present.

    Done
  • Verify package integrity metadata

    No package verification/checksum metadata.

    Pending

Rollout

Adopt in controlled steps based on the selected plan.

  • Run in isolated sandbox firstRequired

    Use a constrained sandbox and observe behavior across multiple tasks.

    Pending
  • Roll out graduallyRequired

    Roll out to a small cohort before wider usage.

    Pending
  • Set monitoring and fallback

    Define rollback path and monitor errors after adoption.

    Pending

Evidence readiness

Evidence readiness matrix · balanced

Required evidence gates are covered (5/6 signals complete).

Risk 15

Source provenance

Present

Source repository/provenance is listed.

Required in this preset

Metadata review

Present

Review metadata is present.

Required in this preset

Safety notes

Present

Safety notes are present.

Required in this preset

Privacy notes

Present

Privacy notes are present.

Optional in this preset

Package integrity

Missing

Package integrity metadata is missing.

Optional in this preset

Install payload

Present

Install payload is available.

Required in this preset

Required evidence gates are covered for this preset.

Decision timeline

Decision timeline · balanced

5/6 steps complete with no blocking gaps for this preset.

Risk 14

triage

Confirm source provenanceRequired

Source/provenance metadata is available.

Done

triage

Check metadata review statusRequired

Review metadata is available.

Done

verify

Review safety notesRequired

Safety notes are available.

Done

verify

Review privacy notes

Privacy notes are available.

Done

verify

Validate package integrity metadata

Package integrity metadata is missing.

Pending

rollout

Verify install payload and commandsRequired

Install payload is available.

Done

No required blockers for this timeline preset.

Safety & privacy surface

Safety & privacy surface

2 safety and 2 privacy notes across 4 risk areas. Review closely: credentials & tokens, permissions & scopes, third-party handling.

4 areas
  • SafetyExecution & processesReview generated changes and commands before applying them; slash commands can ask the agent to read, write, edit, or run tools in the current project.
  • SafetyPermissions & scopesLimit scope to the intended files and run in a trusted checkout when the command analyzes code, tests, security findings, or generated output.
  • PrivacyThird-party handlingPrompts, source files, logs, errors, dependency metadata, and generated reports may be sent to the configured AI model during command execution.
  • PrivacyCredentials & tokensRedact secrets, customer data, private repository details, and proprietary code before sharing command output outside the workspace.

Safety notes

  • Review generated changes and commands before applying them; slash commands can ask the agent to read, write, edit, or run tools in the current project.
  • Limit scope to the intended files and run in a trusted checkout when the command analyzes code, tests, security findings, or generated output.

Privacy notes

  • Prompts, source files, logs, errors, dependency metadata, and generated reports may be sent to the configured AI model during command execution.
  • Redact secrets, customer data, private repository details, and proprietary code before sharing command output outside the workspace.

Schema details

Install type
cli
Reading time
8 min
Difficulty score
100
Troubleshooting
Yes
Breaking changes
No
Runtime and command metadata
Command syntax
/mintlify-docs [options] <documentation_scope>
Script body
The `/mintlify-docs` command generates comprehensive, production-ready documentation using Mintlify with AI-powered content creation, API reference automation, and interactive MDX components.

## Usage

```
/mintlify-docs [options] <documentation_scope>
```

## Options

### Documentation Types
- `--quickstart` - Generate quickstart guide
- `--api-reference` - Generate API reference from code
- `--tutorial` - Generate step-by-step tutorial
- `--guide` - Generate conceptual guide
- `--changelog` - Generate changelog from git history

### Source Analysis
- `--from-code=<path>` - Generate docs from source code
- `--from-openapi=<path>` - Generate API docs from OpenAPI spec
- `--from-types=<path>` - Generate docs from TypeScript types
- `--from-jsdoc` - Extract JSDoc comments

### Output Format
- `--mdx` - Generate MDX with components (default)
- `--markdown` - Generate plain Markdown
- `--with-examples` - Include code examples
- `--with-snippets` - Include interactive snippets

### Features
- `--search` - Configure search integration
- `--navigation` - Generate navigation structure
- `--analytics` - Add analytics tracking
- `--versioning` - Enable version management

## Examples

### API Reference from TypeScript

**Command:**
```
/mintlify-docs --api-reference --from-types=src/api/users.ts --with-examples
```

**Input Code:**
```typescript
// src/api/users.ts
/**
 * User management API client
 * @module UserAPI
 */

export interface User {
  /** Unique user identifier */
  id: string;
  /** User's email address */
  email: string;
  /** Display name */
  name: string;
  /** User role */
  role: 'admin' | 'user' | 'guest';
  /** Account creation timestamp */
  createdAt: Date;
}

export interface CreateUserInput {
  email: string;
  name: string;
  password: string;
}

/**
 * Retrieves a user by ID
 * @param userId - The user's unique identifier
 * @returns Promise resolving to the user object
 * @throws {NotFoundError} If user doesn't exist
 * @throws {AuthorizationError} If caller lacks permission
 * @example
 * ```typescript
 * const user = await getUser('user_123');
 * console.log(user.name);
 * ```
 */
export async function getUser(userId: string): Promise<User> {
  const response = await fetch(`/api/users/${userId}`);
  if (!response.ok) throw new Error('Failed to fetch user');
  return response.json();
}

/**
 * Creates a new user
 * @param input - User creation data
 * @returns Promise resolving to the created user
 * @throws {ValidationError} If input is invalid
 * @throws {ConflictError} If email already exists
 * @example
 * ```typescript
 * const newUser = await createUser({
 *   email: 'user@example.com',
 *   name: 'John Doe',
 *   password: 'secure-password'
 * });
 * ```
 */
export async function createUser(input: CreateUserInput): Promise<User> {
  const response = await fetch('/api/users', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify(input),
  });
  if (!response.ok) throw new Error('Failed to create user');
  return response.json();
}
```

**Generated Documentation:**
```mdx
---
title: 'User API'
description: 'Manage user accounts and profiles'
icon: 'users'
---

# User Management API

The User API provides endpoints for managing user accounts, authentication, and profiles.

## User Object

The User object represents a user account in your application.

<ResponseField name="id" type="string" required>
  Unique user identifier
</ResponseField>

<ResponseField name="email" type="string" required>
  User's email address
</ResponseField>

<ResponseField name="name" type="string" required>
  Display name
</ResponseField>

<ResponseField name="role" type="'admin' | 'user' | 'guest'" required>
  User role determining access permissions
</ResponseField>

<ResponseField name="createdAt" type="Date" required>
  Account creation timestamp
</ResponseField>

<CodeGroup>

```typescript User Object
interface User {
  id: string;
  email: string;
  name: string;
  role: 'admin' | 'user' | 'guest';
  createdAt: Date;
}
```

```json Example
{
  "id": "user_123",
  "email": "user@example.com",
  "name": "John Doe",
  "role": "user",
  "createdAt": "2025-10-16T12:00:00Z"
}
```

</CodeGroup>

## Get User

<div className="api-method">
  <div className="api-method-label">GET</div>
  <div className="api-method-path">/api/users/:userId</div>
</div>

Retrieves a user by their unique identifier.

### Path Parameters

<ParamField path="userId" type="string" required>
  The user's unique identifier
</ParamField>

### Response

<ResponseField name="user" type="User">
  The requested user object
</ResponseField>

### Error Codes

<ResponseField name="404" type="NotFoundError">
  User with the specified ID doesn't exist
</ResponseField>

<ResponseField name="403" type="AuthorizationError">
  Caller lacks permission to access this user
</ResponseField>

<CodeGroup>

```typescript TypeScript SDK
import { getUser } from '@/api/users';

const user = await getUser('user_123');
console.log(user.name); // "John Doe"
```

```javascript JavaScript
const response = await fetch('/api/users/user_123');
const user = await response.json();
```

```python Python
import requests

response = requests.get('https://api.example.com/users/user_123')
user = response.json()
```

```bash cURL
curl https://api.example.com/users/user_123 \
  -H "Authorization: Bearer YOUR_TOKEN"
```

</CodeGroup>

<ResponseExample>

```json 200 Success
{
  "id": "user_123",
  "email": "user@example.com",
  "name": "John Doe",
  "role": "user",
  "createdAt": "2025-10-16T12:00:00Z"
}
```

```json 404 Not Found
{
  "error": "User not found",
  "code": "USER_NOT_FOUND"
}
```

```json 403 Forbidden
{
  "error": "Insufficient permissions",
  "code": "FORBIDDEN"
}
```

</ResponseExample>

## Create User

<div className="api-method">
  <div className="api-method-label">POST</div>
  <div className="api-method-path">/api/users</div>
</div>

Creates a new user account.

### Request Body

<ParamField body="email" type="string" required>
  User's email address (must be unique)
</ParamField>

<ParamField body="name" type="string" required>
  Display name
</ParamField>

<ParamField body="password" type="string" required>
  Account password (min 8 characters)
</ParamField>

### Response

<ResponseField name="user" type="User">
  The created user object
</ResponseField>

### Error Codes

<ResponseField name="400" type="ValidationError">
  Input validation failed
</ResponseField>

<ResponseField name="409" type="ConflictError">
  Email address already exists
</ResponseField>

<CodeGroup>

```typescript TypeScript SDK
import { createUser } from '@/api/users';

const newUser = await createUser({
  email: 'user@example.com',
  name: 'John Doe',
  password: 'secure-password'
});
```

```javascript JavaScript
const response = await fetch('/api/users', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({
    email: 'user@example.com',
    name: 'John Doe',
    password: 'secure-password'
  })
});
const user = await response.json();
```

</CodeGroup>

<Tip>
  Passwords are automatically hashed using Argon2 before storage. Never log or expose raw passwords.
</Tip>
```

### Quickstart Guide Generation

**Command:**
```
/mintlify-docs --quickstart --from-code=src/ "Getting started with our authentication system"
```

**Generated Documentation:**
```mdx
---
title: 'Quickstart'
description: 'Get started with authentication in 5 minutes'
icon: 'rocket'
---

# Getting Started

This guide will help you integrate authentication into your application in under 5 minutes.

<Steps>

<Step title="Install the SDK">
  Install the authentication package using your preferred package manager:

  <CodeGroup>

  ```bash npm
  npm install @yourapp/auth
  ```

  ```bash pnpm
  pnpm add @yourapp/auth
  ```

  ```bash yarn
  yarn add @yourapp/auth
  ```

  </CodeGroup>
</Step>

<Step title="Configure Environment Variables">
  Add your API credentials to your `.env` file:

  ```bash .env
  AUTH_SECRET=your-secret-key
  AUTH_URL=https://api.yourapp.com
  GITHUB_CLIENT_ID=your-github-client-id
  GITHUB_CLIENT_SECRET=your-github-client-secret
  ```

  <Warning>
    Never commit your `.env` file to version control. Add it to `.gitignore`.
  </Warning>
</Step>

<Step title="Initialize the Client">
  Create an authentication client instance:

  ```typescript lib/auth.ts
  import { createAuthClient } from '@yourapp/auth';

  export const auth = createAuthClient({
    secret: process.env.AUTH_SECRET!,
    baseUrl: process.env.AUTH_URL!,
    providers: {
      github: {
        clientId: process.env.GITHUB_CLIENT_ID!,
        clientSecret: process.env.GITHUB_CLIENT_SECRET!,
      },
    },
  });
  ```
</Step>

<Step title="Add Authentication to Your App">
  Wrap your application with the authentication provider:

  ```typescript app/layout.tsx
  import { AuthProvider } from '@yourapp/auth/react';
  import { auth } from '@/lib/auth';

  export default function RootLayout({ children }) {
    return (
      <html>
        <body>
          <AuthProvider client={auth}>
            {children}
          </AuthProvider>
        </body>
      </html>
    );
  }
  ```
</Step>

<Step title="Use Authentication Hooks">
  Access authentication state in your components:

  ```typescript components/profile.tsx
  'use client';

  import { useAuth } from '@yourapp/auth/react';

  export function UserProfile() {
    const { user, signIn, signOut } = useAuth();

    if (!user) {
      return (
        <button onClick={() => signIn('github')}>
          Sign in with GitHub
        </button>
      );
    }

    return (
      <div>
        <p>Welcome, {user.name}!</p>
        <button onClick={signOut}>Sign out</button>
      </div>
    );
  }
  ```
</Step>

</Steps>

## Next Steps

<CardGroup cols={2}>

<Card title="API Reference" icon="code" href="/api-reference">
  Explore the complete API documentation
</Card>

<Card title="Authentication Guide" icon="shield" href="/guides/authentication">
  Learn about advanced authentication patterns
</Card>

<Card title="Security Best Practices" icon="lock" href="/guides/security">
  Implement security best practices
</Card>

<Card title="Examples" icon="lightbulb" href="/examples">
  View example implementations
</Card>

</CardGroup>
```

### OpenAPI to Documentation

**Command:**
```
/mintlify-docs --api-reference --from-openapi=openapi.yaml
```

**Generated mint.json Configuration:**
```json
{
  "$schema": "https://mintlify.com/schema.json",
  "name": "Your API Documentation",
  "logo": {
    "dark": "/logo/dark.svg",
    "light": "/logo/light.svg"
  },
  "favicon": "/favicon.svg",
  "colors": {
    "primary": "#0D9373",
    "light": "#07C983",
    "dark": "#0D9373",
    "anchors": {
      "from": "#0D9373",
      "to": "#07C983"
    }
  },
  "topbarLinks": [
    {
      "name": "Support",
      "url": "mailto:support@example.com"
    }
  ],
  "topbarCtaButton": {
    "name": "Dashboard",
    "url": "https://dashboard.example.com"
  },
  "tabs": [
    {
      "name": "API Reference",
      "url": "api-reference"
    },
    {
      "name": "Guides",
      "url": "guides"
    }
  ],
  "anchors": [
    {
      "name": "Documentation",
      "icon": "book-open-cover",
      "url": "https://docs.example.com"
    },
    {
      "name": "Community",
      "icon": "discord",
      "url": "https://discord.gg/example"
    },
    {
      "name": "GitHub",
      "icon": "github",
      "url": "https://github.com/example/repo"
    }
  ],
  "navigation": [
    {
      "group": "Get Started",
      "pages": [
        "introduction",
        "quickstart",
        "development"
      ]
    },
    {
      "group": "API Reference",
      "pages": [
        "api-reference/authentication",
        "api-reference/users",
        "api-reference/organizations"
      ]
    }
  ],
  "footerSocials": {
    "twitter": "https://twitter.com/example",
    "github": "https://github.com/example",
    "linkedin": "https://www.linkedin.com/company/example"
  },
  "analytics": {
    "posthog": {
      "apiKey": "phc_xxx"
    }
  },
  "api": {
    "baseUrl": "https://api.example.com",
    "auth": {
      "method": "bearer"
    }
  }
}
```

## Interactive Components

### Custom MDX Components
```mdx
<Accordion title="How does authentication work?">
  Our authentication system uses JWT tokens with automatic refresh. Sessions last 7 days by default.
</Accordion>

<Info>
  All API requests must include a valid Bearer token in the Authorization header.
</Info>

<Warning>
  Never expose your API secret key in client-side code.
</Warning>

<Tip>
  Use environment variables to manage different API keys for development and production.
</Tip>

<Check>
  Your API credentials are correctly configured!
</Check>
```

## Best Practices

1. **Clear Structure**: Organize documentation with logical navigation
2. **Code Examples**: Include examples in multiple languages
3. **Error Documentation**: Document all possible error codes and responses
4. **Interactive Elements**: Use Mintlify components for better UX
5. **Version Management**: Maintain docs for multiple API versions
6. **Search Optimization**: Use descriptive titles and descriptions
7. **Regular Updates**: Keep documentation in sync with code changes
Full copyable content
/mintlify-docs [options] <documentation_scope>

About this resource

The /mintlify-docs command generates comprehensive, production-ready documentation using Mintlify with AI-powered content creation, API reference automation, and interactive MDX components.

Usage

/mintlify-docs [options] <documentation_scope>

Options

Documentation Types

  • --quickstart - Generate quickstart guide
  • --api-reference - Generate API reference from code
  • --tutorial - Generate step-by-step tutorial
  • --guide - Generate conceptual guide
  • --changelog - Generate changelog from git history

Source Analysis

  • --from-code=<path> - Generate docs from source code
  • --from-openapi=<path> - Generate API docs from OpenAPI spec
  • --from-types=<path> - Generate docs from TypeScript types
  • --from-jsdoc - Extract JSDoc comments

Output Format

  • --mdx - Generate MDX with components (default)
  • --markdown - Generate plain Markdown
  • --with-examples - Include code examples
  • --with-snippets - Include interactive snippets

Features

  • --search - Configure search integration
  • --navigation - Generate navigation structure
  • --analytics - Add analytics tracking
  • --versioning - Enable version management

Examples

API Reference from TypeScript

Command:

/mintlify-docs --api-reference --from-types=src/api/users.ts --with-examples

Input Code:

// src/api/users.ts
/**
 * User management API client
 * @module UserAPI
 */

export interface User {
  /** Unique user identifier */
  id: string;
  /** User's email address */
  email: string;
  /** Display name */
  name: string;
  /** User role */
  role: "admin" | "user" | "guest";
  /** Account creation timestamp */
  createdAt: Date;
}

export interface CreateUserInput {
  email: string;
  name: string;
  password: string;
}

/**
 * Retrieves a user by ID
 * @param userId - The user's unique identifier
 * @returns Promise resolving to the user object
 * @throws {NotFoundError} If user doesn't exist
 * @throws {AuthorizationError} If caller lacks permission
 * @example
 * ```typescript
 * const user = await getUser('user_123');
 * console.log(user.name);
 * ```
 */
export async function getUser(userId: string): Promise<User> {
  const response = await fetch(`/api/users/${userId}`);
  if (!response.ok) throw new Error("Failed to fetch user");
  return response.json();
}

/**
 * Creates a new user
 * @param input - User creation data
 * @returns Promise resolving to the created user
 * @throws {ValidationError} If input is invalid
 * @throws {ConflictError} If email already exists
 * @example
 * ```typescript
 * const newUser = await createUser({
 *   email: 'user@example.com',
 *   name: 'John Doe',
 *   password: 'secure-password'
 * });
 * ```
 */
export async function createUser(input: CreateUserInput): Promise<User> {
  const response = await fetch("/api/users", {
    method: "POST",
    headers: { "Content-Type": "application/json" },
    body: JSON.stringify(input),
  });
  if (!response.ok) throw new Error("Failed to create user");
  return response.json();
}

Generated Documentation:

---
title: "User API"
description: "Manage user accounts and profiles"
icon: "users"
---

# User Management API

The User API provides endpoints for managing user accounts, authentication, and profiles.

## User Object

The User object represents a user account in your application.

<ResponseField name="id" type="string" required>
  Unique user identifier
</ResponseField>

<ResponseField name="email" type="string" required>
  User's email address
</ResponseField>

<ResponseField name="name" type="string" required>
  Display name
</ResponseField>

<ResponseField name="role" type="'admin' | 'user' | 'guest'" required>
  User role determining access permissions
</ResponseField>

<ResponseField name="createdAt" type="Date" required>
  Account creation timestamp
</ResponseField>

<CodeGroup>

```typescript User Object
interface User {
  id: string;
  email: string;
  name: string;
  role: "admin" | "user" | "guest";
  createdAt: Date;
}
```
{
  "id": "user_123",
  "email": "user@example.com",
  "name": "John Doe",
  "role": "user",
  "createdAt": "2025-10-16T12:00:00Z"
}

Get User

GET /api/users/:userId

Retrieves a user by their unique identifier.

Path Parameters

The user's unique identifier

Response

The requested user object

Error Codes

User with the specified ID doesn't exist Caller lacks permission to access this user
import { getUser } from "@/api/users";

const user = await getUser("user_123");
console.log(user.name); // "John Doe"
const response = await fetch("/api/users/user_123");
const user = await response.json();
import requests

response = requests.get('https://api.example.com/users/user_123')
user = response.json()
curl https://api.example.com/users/user_123 \
  -H "Authorization: Bearer YOUR_TOKEN"
{
  "id": "user_123",
  "email": "user@example.com",
  "name": "John Doe",
  "role": "user",
  "createdAt": "2025-10-16T12:00:00Z"
}
{
  "error": "User not found",
  "code": "USER_NOT_FOUND"
}
{
  "error": "Insufficient permissions",
  "code": "FORBIDDEN"
}

Create User

POST /api/users

Creates a new user account.

Request Body

User's email address (must be unique) Display name Account password (min 8 characters)

Response

The created user object

Error Codes

Input validation failed Email address already exists
import { createUser } from "@/api/users";

const newUser = await createUser({
  email: "user@example.com",
  name: "John Doe",
  password: "secure-password",
});
const response = await fetch("/api/users", {
  method: "POST",
  headers: { "Content-Type": "application/json" },
  body: JSON.stringify({
    email: "user@example.com",
    name: "John Doe",
    password: "secure-password",
  }),
});
const user = await response.json();
Passwords are automatically hashed using Argon2 before storage. Never log or expose raw passwords. ```

Quickstart Guide Generation

Command:

/mintlify-docs --quickstart --from-code=src/ "Getting started with our authentication system"

Generated Documentation:

---
title: "Quickstart"
description: "Get started with authentication in 5 minutes"
icon: "rocket"
---

# Getting Started

This guide will help you integrate authentication into your application in under 5 minutes.

<Steps>

<Step title="Install the SDK">
  Install the authentication package using your preferred package manager:

  <CodeGroup>

```bash npm
npm install @yourapp/auth
```
pnpm add @yourapp/auth
yarn add @yourapp/auth
Add your API credentials to your `.env` file:
AUTH_SECRET=your-secret-key
AUTH_URL=https://api.yourapp.com
GITHUB_CLIENT_ID=your-github-client-id
GITHUB_CLIENT_SECRET=your-github-client-secret
Never commit your `.env` file to version control. Add it to `.gitignore`. Create an authentication client instance:
import { createAuthClient } from "@yourapp/auth";

export const auth = createAuthClient({
  secret: process.env.AUTH_SECRET!,
  baseUrl: process.env.AUTH_URL!,
  providers: {
    github: {
      clientId: process.env.GITHUB_CLIENT_ID!,
      clientSecret: process.env.GITHUB_CLIENT_SECRET!,
    },
  },
});
Wrap your application with the authentication provider:
import { AuthProvider } from '@yourapp/auth/react';
import { auth } from '@/lib/auth';

export default function RootLayout({ children }) {
  return (
    <html>
      <body>
        <AuthProvider client={auth}>
          {children}
        </AuthProvider>
      </body>
    </html>
  );
}
Access authentication state in your components:
'use client';

import { useAuth } from '@yourapp/auth/react';

export function UserProfile() {
  const { user, signIn, signOut } = useAuth();

  if (!user) {
    return (
      <button onClick={() => signIn('github')}>
        Sign in with GitHub
      </button>
    );
  }

  return (
    <div>
      <p>Welcome, {user.name}!</p>
      <button onClick={signOut}>Sign out</button>
    </div>
  );
}

Next Steps

Explore the complete API documentation Learn about advanced authentication patterns Implement security best practices View example implementations ```

OpenAPI to Documentation

Command:

/mintlify-docs --api-reference --from-openapi=openapi.yaml

Generated mint.json Configuration:

{
  "$schema": "https://mintlify.com/schema.json",
  "name": "Your API Documentation",
  "logo": {
    "dark": "/logo/dark.svg",
    "light": "/logo/light.svg"
  },
  "favicon": "/favicon.svg",
  "colors": {
    "primary": "#0D9373",
    "light": "#07C983",
    "dark": "#0D9373",
    "anchors": {
      "from": "#0D9373",
      "to": "#07C983"
    }
  },
  "topbarLinks": [
    {
      "name": "Support",
      "url": "mailto:support@example.com"
    }
  ],
  "topbarCtaButton": {
    "name": "Dashboard",
    "url": "https://dashboard.example.com"
  },
  "tabs": [
    {
      "name": "API Reference",
      "url": "api-reference"
    },
    {
      "name": "Guides",
      "url": "guides"
    }
  ],
  "anchors": [
    {
      "name": "Documentation",
      "icon": "book-open-cover",
      "url": "https://docs.example.com"
    },
    {
      "name": "Community",
      "icon": "discord",
      "url": "https://discord.gg/example"
    },
    {
      "name": "GitHub",
      "icon": "github",
      "url": "https://github.com/example/repo"
    }
  ],
  "navigation": [
    {
      "group": "Get Started",
      "pages": ["introduction", "quickstart", "development"]
    },
    {
      "group": "API Reference",
      "pages": [
        "api-reference/authentication",
        "api-reference/users",
        "api-reference/organizations"
      ]
    }
  ],
  "footerSocials": {
    "twitter": "https://twitter.com/example",
    "github": "https://github.com/example",
    "linkedin": "https://www.linkedin.com/company/example"
  },
  "analytics": {
    "posthog": {
      "apiKey": "phc_xxx"
    }
  },
  "api": {
    "baseUrl": "https://api.example.com",
    "auth": {
      "method": "bearer"
    }
  }
}

Interactive Components

Custom MDX Components

<Accordion title="How does authentication work?">
  Our authentication system uses JWT tokens with automatic refresh. Sessions
  last 7 days by default.
</Accordion>

<Info>
  All API requests must include a valid Bearer token in the Authorization
  header.
</Info>

<Warning>Never expose your API secret key in client-side code.</Warning>

<Tip>
  Use environment variables to manage different API keys for development and
  production.
</Tip>

<Check>Your API credentials are correctly configured!</Check>

Best Practices

  1. Clear Structure: Organize documentation with logical navigation
  2. Code Examples: Include examples in multiple languages
  3. Error Documentation: Document all possible error codes and responses
  4. Interactive Elements: Use Mintlify components for better UX
  5. Version Management: Maintain docs for multiple API versions
  6. Search Optimization: Use descriptive titles and descriptions
  7. Regular Updates: Keep documentation in sync with code changes

Source citations

Add this badge to your README

Show that Mintlify Documentation Generator for Claude is listed on HeyClaude. Paste this Markdown into your README — it renders the badge and links back to this page.

Listed on HeyClaude
[![Listed on HeyClaude](https://heyclau.de/badge/commands/mintlify-docs.svg)](https://heyclau.de/entry/commands/mintlify-docs)

How it compares

Mintlify Documentation Generator for Claude side by side with 3 alternatives on trust, install, platform support, and disclosed safety notes — all from reviewed registry metadata.

Field

Generate beautiful, searchable documentation using Mintlify with AI-powered content generation, API reference automation, and MDX components

Open dossier

User-created Claude Code custom slash command recipe for drafting project documentation from source files, existing docs, and repository conventions.

Open dossier

Generate .cursorrules files for AI-native development with project-specific patterns, coding standards, and intelligent context awareness

Open dossier

Intelligent code explanation with visual diagrams, step-by-step breakdowns, and interactive examples

Open dossier
Next steps
Trust
Review statusReviewedMaintainer reviewedReviewedMaintainer reviewedReviewedMaintainer reviewedReviewedMaintainer reviewed
Package trustPackage not verifiedPackage not verifiedPackage not verifiedPackage not verified
Source provenanceSource-backedSource-backedSource-backedSource-backed
Submitter
Install riskReview firstReview firstReview firstReview first
Notes Safety Privacy Safety Privacy Safety Privacy Safety Privacy
BrandCursor logoCursor
Categorycommandscommandscommandscommands
Sourcesource-backedsource-backedsource-backedsource-backed
AuthorJSONboredJSONboredJSONboredJSONbored
Added2025-10-162025-09-162025-10-162025-09-16
Platforms
Claude Code
Claude Code
CursorClaude Code
Claude Code
Source repo
Safety notesReview generated changes and commands before applying them; slash commands can ask the agent to read, write, edit, or run tools in the current project. Limit scope to the intended files and run in a trusted checkout when the command analyzes code, tests, security findings, or generated output.Generated documentation is a draft; verify examples, flags, endpoints, and behavior against the actual source before publishing. Do not let the command invent supported options, output formats, API fields, or guarantees that are not present in the code or official docs. If you add dynamic shell injection or allowed tools to the command file, scope those permissions narrowly because the command can run local commands.Review generated changes and commands before applying them; slash commands can ask the agent to read, write, edit, or run tools in the current project. Limit scope to the intended files and run in a trusted checkout when the command analyzes code, tests, security findings, or generated output.Review generated changes and commands before applying them; slash commands can ask the agent to read, write, edit, or run tools in the current project. Limit scope to the intended files and run in a trusted checkout when the command analyzes code, tests, security findings, or generated output.
Privacy notesPrompts, source files, logs, errors, dependency metadata, and generated reports may be sent to the configured AI model during command execution. Redact secrets, customer data, private repository details, and proprietary code before sharing command output outside the workspace.The target source files, existing docs, examples, error messages, and command arguments may be sent into the model context. Do not include private API keys, customer records, unreleased roadmap details, or production logs in generated examples.Prompts, source files, logs, errors, dependency metadata, and generated reports may be sent to the configured AI model during command execution. Redact secrets, customer data, private repository details, and proprietary code before sharing command output outside the workspace.Prompts, source files, logs, errors, dependency metadata, and generated reports may be sent to the configured AI model during command execution. Redact secrets, customer data, private repository details, and proprietary code before sharing command output outside the workspace.
Prerequisites— none listed— none listed— none listed— none listed
Install
/mintlify-docs [options] <documentation_scope>
/docs src/api/users.ts
/cursor-rules [options] <project_type>
/explain [options] <code_or_file>
Config
Citations
ClaimUnclaimedUnclaimedUnclaimedUnclaimed
Open 4 picks in the interactive comparison tool

Signals

Loading live community signals…

More like this, weekly

A short, calm digest of reviewed Claude resources. Unsubscribe any time.