Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion agent-context/context/skills/mintlify/reference/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ JSON report fields:
- `mint login` — Authenticate your Mintlify account.
- `mint logout` — Log out of your account.
- `mint status` — Show current authentication status (CLI version, email, org, subdomain).
- `mint signup [flags]` — Create a new Mintlify account from an interactive terminal. Flags: `--firstName`, `--lastName`, `--company`, `--email`; omit any to enter it interactively. Waits until you click the emailed verification link before it logs you in. When an agent runs it, or stdin isn't a TTY, it only prints https://mintlify.com/auth.md and creates no account; agents use `mint deploy` and `mint claim` instead.
- `mint signup` — Create a new Mintlify account from an interactive terminal. Opens the signup page in the browser, then logs in and prompts for a project like `mint login`. No flags. When an agent runs it, or stdin isn't a TTY, it only prints https://mintlify.com/auth.md and creates no account; agents use `mint deploy` and `mint claim` instead.
- `mint add-domain <domain> [--basePath <path>]` — Add a custom domain to the current project. Requires `mint login`. Pass `--basePath` to serve the documentation from a subpath such as `/docs`.

## Analytics
Expand Down
2 changes: 1 addition & 1 deletion cli/agent-signup.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

An AI agent can create and deploy a Mintlify site without first signing up for an account. You can then claim the site an agent creates for you from your own Mintlify account.

Use this site creation and signup flow when you want an agent to work on a site autonomously or when you want to demo a live site before creating an account. If you already have an account or are ready to sign up by email, use the [agent setup workflow](/quickstart) instead.
Use this site creation and signup flow when you want an agent to work on a site autonomously or when you want to demo a live site before creating an account. If you already have an account or are ready to sign up, use the [agent setup workflow](/quickstart) instead.

## Deploy a site

Expand Down Expand Up @@ -43,7 +43,7 @@

1. Provisions the site, or reuses the site from an earlier `mint deploy` in the same directory.
2. Trusts the repository and its default branch to deploy the site.
3. Writes `.github/workflows/mintlify.yml` at the repository root.

Check warning on line 46 in cli/agent-signup.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/agent-signup.mdx#L46

Use 'GitHub' instead of 'github'.

Commit and push the workflow file to the default branch. Each later push to that branch runs `mint deploy` in GitHub Actions, which pushes the checked-out commit to the site.

Expand Down
29 changes: 2 additions & 27 deletions cli/commands.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -50,40 +50,15 @@
Create a new Mintlify account from an interactive terminal.

```bash
mint signup [flags]
mint signup
```

| Flag | Description |
| --- | --- |
| `--firstName` | Your first name. |
| `--lastName` | Your last name. |
| `--company` | Your company name. |
| `--email` | Email address for the account. |

Run the command without flags to enter your details interactively. The CLI prompts for any value you do not pass as a flag.

After you submit your details, Mintlify sends a verification link to your email. The command waits until you click the link, then creates your account, signs you in, and stores your credentials. When it finishes, open the [dashboard](https://app.mintlify.com) to connect your repository and start building.
The command opens your browser to the Mintlify signup page. If your browser doesn't open, copy the URL the CLI prints. After you create your account in the browser, the CLI signs you in, stores your credentials, and asks you to choose a project, like [`mint login`](#mint-login).

<Note>
`mint signup` does not return until you click the verification link, which can take several minutes.

When an AI agent runs `mint signup`, or the command runs without an interactive terminal, it prints the [agent signup guide](https://mintlify.com/auth.md) instead of creating an account. Agents create sites without an account through [Agent signup](/cli/agent-signup).
</Note>

### Examples

```bash
# Sign up interactively
mint signup

# Sign up with all details provided
mint signup \
--firstName Jane \
--lastName Doe \
--company Acme \
--email jane@acme.com
```

---

## `mint deploy`
Expand All @@ -100,10 +75,10 @@
| `--org-name` | Organization display name. |
| `--directory` | Documentation directory for the site. Defaults to the current directory. |
| `--new` | Create another site instead of reusing the site for this directory. |
| `--email` | Also print a claim link, prefilled with this Mintlify account email. Can't be combined with `--github` or `--push`. |

Check warning on line 78 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L78

In general, use active voice instead of passive voice ('be combined').
| `--github` | Trust the current GitHub repository to deploy the site and write `.github/workflows/mintlify.yml`. |

Check warning on line 79 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L79

Use 'GitHub' instead of 'github'.
| `--force` | With `--github`, overwrite an existing workflow file that has different contents. |
| `--knowledge-base` | Create a [knowledge base](/base/index), which you edit in the Mintlify editor, instead of a site. Can't be combined with `--github`. Replaces the deprecated `--base` flag. |

Check warning on line 81 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L81

In general, use active voice instead of passive voice ('be combined').
| `--push` | With `--knowledge-base`, rebase the clone in the given directory onto `main` and push it to the knowledge base. For example, `--push ./my-knowledge-base`. |

Run the command again from the same directory to get a fresh write token for the same site. In GitHub Actions, `mint deploy` pushes the checked-out commit to a site that trusts the repository. The workflow needs the `id-token: write` permission.
Expand Down Expand Up @@ -140,7 +115,7 @@
| `--code` | Code from an older claim link that showed one. Finishes that claim. |
| `--directory` | Documentation directory used for `mint deploy`. Defaults to the current directory. |

Run `mint claim` to get a claim link. The site owner opens it, signs in with any account, and clicks **Confirm**; the site moves into a new organization in their account. `--email` and `--code` can't be combined.

Check warning on line 118 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L118

Use semicolons judiciously.

Check warning on line 118 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L118

In general, use active voice instead of passive voice ('be combined').

### Examples

Expand Down Expand Up @@ -216,7 +191,7 @@

Add the `TXT` records first, then add the `CNAME` once the verification records validate. See [Custom domain](/customize/custom-domain) for full DNS setup instructions, apex domain requirements, and TLS provisioning details.

If the command fails with `Domain is already in use by another deployment in your organization` or `Domain is already claimed by another organization`, the domain is bound to another Mintlify project. See [Add domain fails with "Domain is already claimed by another organization"](/help-center/domain-already-claimed-by-another-organization) to release it and re-add it.

Check warning on line 194 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L194

In general, use active voice instead of passive voice ('is bound').

<Note>
If some `TXT` records are still generating when the command exits, check the [Custom domain setup](https://app.mintlify.com/settings/project/custom-domain) page in your dashboard for the remaining values.
Expand Down Expand Up @@ -263,7 +238,7 @@

### `mint analytics stats`

Display top-line KPIs for a date range: views, visitors, searches, feedback, and assistant usage. The output reports human and agent traffic separately.

Check warning on line 241 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L241

Did you really mean 'KPIs'?

```bash
mint analytics stats [flags]
Expand Down Expand Up @@ -393,7 +368,7 @@

| Agent | Project file | User account file (`--global`) |
| --- | --- | --- |
| Claude Code | `.mcp.json` | `~/.claude.json` |

Check warning on line 371 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L371

Use 'Claude' instead of 'claude'.
| Codex | `.codex/config.toml` | `~/.codex/config.toml`, or `config.toml` in `CODEX_HOME` when set |
| Cursor | `.cursor/mcp.json` | `~/.cursor/mcp.json` |

Expand All @@ -405,7 +380,7 @@
claude mcp add --scope user --transport http mintlify https://mcp.mintlify.com
```

Setup keeps your existing configuration and skips an agent that already has a matching `mintlify` entry. If a `mintlify` entry has a different configuration, or a configuration file can't be parsed, setup stops before it installs skills. Rename or remove the conflicting entry, then run the command again.

Check warning on line 383 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L383

In general, use active voice instead of passive voice ('be parsed').

Setup only looks for an entry named `mintlify`. If an agent already connects to the admin MCP under another name, such as `mintlify-admin`, setup adds a second entry. Remove one of them so the agent doesn't connect to the admin MCP twice.

Expand Down Expand Up @@ -511,9 +486,9 @@

Links without a leading `/`, such as `quickstart` or `../quickstart`, resolve from the directory of the page that contains them, the same way a browser resolves them. To link from the root of your site, start the path with `/`.

Root-relative links that keep the `.mdx` extension, such as `/quickstart.mdx`, report as broken because Mintlify serves pages without the extension. Remove the extension, or add a [redirect](/create/redirects) from the `.mdx` path to the page. Relative links such as `./quickstart.mdx` in Markdown links and `href` values are fine because Mintlify removes the extension, but reference-style link definitions such as `[id]: ./quickstart.mdx` keep it and report as broken.

Check warning on line 489 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L489

Use 'MDX' instead of 'mdx'.

For links without a leading `/` and anchor links (`#`) inside a snippet, the command checks each page that renders the snippet. The command reports one of these links only if it is broken on at least one of those pages. With `--check-anchors`, headings inside a snippet count as anchors on the pages that render it.

Check warning on line 491 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L491

In general, use active voice instead of passive voice ('is broken').

| Flag | Description |
| --- | --- |
Expand All @@ -524,7 +499,7 @@
| `--check-snippets` | Also check that snippet import paths resolve to existing files. |
| `--links-to` | List every internal link that points to a page instead of checking for broken links. |

Pass `--files` to limit the check to specific pages. This is useful for validating a single page you just edited or scoping checks to a directory in CI. When `--files` is set with `--check-external`, only external URLs on the selected pages are fetched.

Check warning on line 502 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L502

In general, use active voice instead of passive voice ('are fetched').

```bash
# Check a specific page
Expand Down Expand Up @@ -599,7 +574,7 @@
| `missing-file` | `content` | Reports imported files that don't exist. Needs the build. |
| `import-error` | `content` | Reports imports in pages and snippets that don't resolve. Needs the build. |
| `missing-nav-page` | `nav` | Reports pages in your navigation that have no file. Needs the build. |
| `package-import` | `config` | Reports npm package imports that are undeclared or conflict. Needs the build. |

Check warning on line 577 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L577

In general, use active voice instead of passive voice ('are undeclared').
| `url-collision` | `config` | Reports generated pages whose names differ only by case from another name, so they get a new URL. See [GraphQL setup](/api-playground/graphql-setup). Needs the build. |
| `build-failed` | `config` | Reports a strict build failure that no other rule explains. Needs the build. |
| `openapi-spec` | `openapi` | Reports OpenAPI specifications in `docs.json` or `mint.json` that don't parse or validate, with overlays applied. |
Expand All @@ -624,7 +599,7 @@
Commit or stash your changes before you run `--fix`, so you can review its edits.
</Tip>

With `--format json`, progress output is hidden and other console output goes to stderr, so you can parse stdout directly. The report has these fields:

Check warning on line 602 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L602

In general, use active voice instead of passive voice ('is hidden').

- `passed`: `true` when no rule reported an error.
- `summary`: `errors` and `warnings` counts, plus `byRule` with a count for each rule ID.
Expand Down Expand Up @@ -684,9 +659,9 @@
| `--surface` | Try a surface (`brand` or `neutral`) without editing `docs.json`. |
| `--appearance` | Try an appearance (`light` or `dark`) without editing `docs.json`. |
| `--output` | Where to write the PNG. Defaults to a temporary file. |
| `--no-open` | Don't open the image after rendering. The command also skips opening it when the `CI` environment variable is set. |

Check warning on line 662 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L662

In general, use active voice instead of passive voice ('is set').

The command prints warnings when the title is too long to fit on two lines, when no logo is configured or the logo fails to load, when the font fails to load, and when text has low contrast on a `brand` surface. Warnings don't change the exit code. The command exits with code `1` if `docs.json` is invalid or the page doesn't exist.

Check warning on line 664 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L664

In general, use active voice instead of passive voice ('is configured').

```bash
# Render one page and open it
Expand Down Expand Up @@ -795,13 +770,13 @@
mint format
```

Run the command from the root of your docs project. It walks every subdirectory, skipping paths matched by `.gitignore` and any Mintlify ignore rules. Files that already match the canonical output are left untouched.

Check warning on line 773 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L773

In general, use active voice instead of passive voice ('are left').

<Tip>
Running `mint format` can result in many changes depending on the size of your project. To avoid merge conflicts and introducing changes to other in progress work, first resolve all important pending branches. Then create a new branch for formatting changes and run `mint format` on that branch.
</Tip>

When it finishes, the command prints how many MDX files were reformatted and how many failed to parse. If any file fails, the command exits with code `1` and prints the file path and error, so you can run it in CI to enforce consistent formatting. See [Install in CI](/cli/install#install-in-ci) for an example pipeline.

Check warning on line 779 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L779

In general, use active voice instead of passive voice ('were reformatted').

---

Expand All @@ -820,7 +795,7 @@
| `--agent` | Start a coding agent in the current directory and have it run the migration. Accepts `claude`, `codex`, `cursor`, or `gemini`. Combine with `--from` to include a platform guide. |
| `--claude` | Alias for `--agent claude`. |

Without flags, the command prints an overview of the migration workflow followed by the available topics and source platforms. The instructions are written for coding agents, so you can paste them into your agent or let your agent run `mint migrate` itself.

Check warning on line 798 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L798

In general, use active voice instead of passive voice ('are written').

With `--agent`, the CLI launches the specified agent's command-line tool with a prompt to run `mint migrate` and follow the instructions it prints. You must already have the agent's CLI installed. If the Mintlify CLI can't find the agent CLI, `mint migrate` exits with an error that includes the install command.

Expand Down Expand Up @@ -914,7 +889,7 @@

## Telemetry

The CLI collects usage telemetry to help improve Mintlify. Telemetry data includes the command name, CLI version, operating system, architecture, and Node.js version. It also records whether the CLI runs in a CI environment, whether it runs in an interactive terminal, whether this is the first time the CLI has run on your machine, and whether you are signed in. If the CLI detects an AI coding agent running it, telemetry also includes the agent's name. Each event also includes a session identifier that groups events from the same working session. The CLI stores it in `~/.config/mintlify/telemetry-session.json` and replaces it after 30 minutes of inactivity. If you are signed in, telemetry events also include your account email address. Signed-out usage stays anonymous, and signing out removes your stored email. Mintlify does **not** collect project content or file paths.

Check warning on line 892 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L892

In general, use active voice instead of passive voice ('are signed').

Check warning on line 892 in cli/commands.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

cli/commands.mdx#L892

In general, use active voice instead of passive voice ('are signed').

By default, the CLI collects telemetry data. You can opt out at any time using the `--telemetry` flag:

Expand Down
2 changes: 1 addition & 1 deletion snippets/agent-setup-workflow.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ If the user asks you to set up Mintlify, a documentation site, or a local Mintli
1. Run `node --version` and confirm it reports Node.js v20.17.0 or newer, preferring an LTS release. The CLI doesn't run on Node.js 25. Note whether it is v22.20 or newer, which step 9 requires.
2. Run `mint --version`. If the command is unavailable, install the CLI with `npm i -g mint` or `pnpm add -g mint`. If the command succeeds, run `mint update`. Then run `mint instructions new-site` for current setup guidance, and `mint instructions` to list topics for later tasks.
3. Run `mint status` before starting authentication. If it already shows an organization, keep the existing session and do not create another account.
4. Run `mint login` if the user has an account. Otherwise, don't create an account now. You can publish without one using `mint deploy` in step 10, and the user creates their account when they claim the site. Don't run `mint signup` for the user: when an agent runs it, it prints the [agent signup guide](https://mintlify.com/auth.md) and exits without sending a verification email. If the user wants their own GitHub repository connected from the start, send them to web onboarding at [mintlify.com/start](https://mintlify.com/start).
4. Run `mint login` if the user has an account. Otherwise, don't create an account now. You can publish without one using `mint deploy` in step 10, and the user creates their account when they claim the site. Don't run `mint signup` for the user: when an agent runs it, it prints the [agent signup guide](https://mintlify.com/auth.md) and creates no account. If the user wants their own GitHub repository connected from the start, send them to web onboarding at [mintlify.com/start](https://mintlify.com/start).
5. After `mint login`, run `mint status` again. Confirm that it reports their email, organization, and subdomain. If the organization exists but no subdomain appears, ask the user to finish selecting or connecting a GitHub repository in the onboarding browser tab, then retry.
6. If the user has an existing documentation repository, clone or open it. Preserve its content. If the user's documentation is on another platform, such as GitBook, ReadMe, or Docusaurus, run `mint migrate --from <platform>` and follow the workflow it prints. Run `mint migrate` without flags to list supported platforms. Don't run `mint migrate --agent`, which starts another coding agent. For a new local project, scaffold into a new, empty directory with either `mint new <directory> --name <name> --theme <theme>` or `mint new <directory> --name <name> --template <template-name>`. Without an interactive terminal, `mint new` creates nothing unless you pass `--name` and either `--theme` or `--template`. Ask which theme or template they want if they have not specified one. Do not use `--force` on a directory containing user files.
7. Run `mint dev --no-open` from the directory containing `docs.json` as a background process. Confirm the local URL loads, report it to the user, and stop the process when it is no longer needed.
Expand Down
Loading