AGENTS.md give Codex persistent context about your documentation standards, components, and style guide.
Use Codex with Mintlify
Codex readsAGENTS.md files from your repository to understand project-specific rules and conventions before it starts working. You can place an AGENTS.md at the root of your docs repo to give Codex context about Mintlify components, your writing standards, and how your documentation is structured.
Codex discovers AGENTS.md files at multiple levels:
- Global instructions in
~/.codex/AGENTS.mdapply to all your projects. - Project instructions in your repo root (or any subdirectory) apply to work done in that scope.
AGENTS.md at the root of your docs repo and commit it so all contributors benefit from the same context. See AGENTS.md in the Codex documentation for complete details.
Example AGENTS.md
This file gives Codex context about Mintlify components and technical writing standards. Customize it for your documentation:- Writing standards: Update language guidelines to match your style guide.
- Component patterns: Add project-specific components or modify existing examples.
- Code examples: Replace generic examples with real API calls and responses for your product.
- Style and tone preferences: Adjust terminology, formatting, and other rules.
AGENTS.md at the root of your docs repo.
AGENTS.md
Working with Codex
Once yourAGENTS.md is in place, Codex picks it up automatically when you start a session in your docs repo.
Example prompts
Writing new content:Enhance with MCP server
Connect the Mintlify MCP server to Codex to give it access to search the Mintlify documentation while helping you write. When you connect the MCP server, Codex can look up component usage and configuration options without you leaving the terminal. Add the MCP server to your global Codex config at~/.codex/config.toml: