This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
This is the documentation repository for Cosmos EVM, built with Mintlify. The repository contains comprehensive documentation for the Cosmos EVM implementation, including API references, integration guides, smart contract documentation, and precompile specifications.
# Start live-reload preview server
npx mint dev
# Check for broken internal links (run before committing)
npx mint broken-links
# Validate OpenAPI specifications
npx mint openapi-check docs/api-reference/ethereum-json-rpc/openapi.yaml
# Clean build artifacts
npm run clean
# Full reset (clean + reinstall)
npm run reset# Generate interactive RPC documentation pages
node scripts/generate-evm-rpc-docs.js
# Generate OpenAPI specification from methods documentation
node scripts/generate-evm-rpc-openapi.js
# Refresh release notes from cosmos/evm changelog
./scripts/refresh-release-notes.sh
# Parse changelog to Mintlify format
node scripts/parse-evm-changelog.js# Run all precompile tests
./tests/run-tests.sh
# Test individual precompiles
cd tests && npm testThe documentation follows a hierarchical structure configured in docs.json:
-
docs/documentation/ - Main documentation content
concepts/- Core concepts (accounts, gas, transactions, IBC)cosmos-sdk/- SDK modules and protocol detailssmart-contracts/- Precompiles and predeployed contractsintegration/- Integration guides and migration docsgetting-started/- Quick start guides and tooling
-
docs/api-reference/ - API documentation
ethereum-json-rpc/- RPC methods, OpenAPI spec, and explorer
-
docs/changelog/ - Release notes auto-synced from cosmos/evm
-
Mintlify Framework: Documentation uses Mintlify v4.2.7 with custom MDX components and interactive features. Configuration in
docs.jsoncontrols navigation, theming, and search. -
Script Automation: Scripts in
/scriptshandle:- Parsing cosmos/evm changelog to generate release notes
- Creating interactive RPC documentation from methods.mdx
- Generating OpenAPI specifications for API testing
-
Precompile Testing: Comprehensive test suite in
/testsvalidates all precompile contracts against documentation, tracking implementation completeness and gas costs. -
Component Library: Custom JSX components in
/snippetsprovide:- EIP compatibility tables
- RPC method viewers
- Icon libraries
- Reusable UI elements
When updating documentation:
- Edit MDX files in appropriate section under
docs/ - Run
npx mint devto preview changes locally - Validate with
npx mint broken-linksbefore committing - For RPC changes: regenerate docs with
node scripts/generate-evm-rpc-docs.js - For release notes: use
./scripts/refresh-release-notes.shto sync from upstream
- GitHub Actions: Automated changelog sync workflow
- Cosmos EVM Repository: Release notes pulled from github.com/cosmos/evm
- Precompile Addresses: Fixed addresses documented in tests/README.md
- Network Endpoints: Configure in tests/config.js for testing
- All documentation files use MDX format with Mintlify-specific components
- Navigation structure must be updated in
docs.jsonwhen adding new pages - Interactive RPC documentation is generated from the source
methods.mdxfile - Test findings in
tests/README.mdtrack documentation accuracy against implementation - Use relative imports for snippets and components (e.g.,
/snippets/icons.mdx)