Configuration File
mint-tsdocs uses cosmiconfig to load configuration. It searches for configuration in the following locations (in order):mint-tsdocs.config.json(recommended).mint-tsdocsrc.mint-tsdocsrc.jsonmintlifyTsdocsfield inpackage.json
JSON Schema
Add the$schema field for IDE autocomplete and validation:
Core Options
entryPoint
Type:string (required)
Path to the main TypeScript declaration file (.d.ts) that serves as the entry point for your API.
- Checks
typesfield in package.json - Checks
typingsfield in package.json - Searches common paths:
./lib/index.d.ts,./dist/index.d.ts,./build/index.d.ts
- Must point to a compiled .d.ts file (not .ts source)
- Run TypeScript compiler before generating docs
- Path is relative to project root
outputFolder
Type:string
Default: ./docs/reference
Directory where generated MDX documentation files will be written.
- Directory will be created if it doesn’t exist
- Existing files will be overwritten
- Path is relative to project root
docsJson
Type:string
Default: Auto-detected or ./docs/docs.json
Path to Mintlify’s docs.json navigation file.
./docs/docs.json./docs.json./documentation/docs.json
- Navigation entries will be automatically added to this file
- File must exist and be valid JSON
- Set to
falseto skip navigation updates
Navigation Options
tabName
Type:string
Default: "API Reference"
Name of the tab in Mintlify navigation where API docs will appear.
groupName
Type:string
Default: "API"
Name of the group within the tab where API items will be organized.
README Options
convertReadme
Type:boolean
Default: false
Whether to convert the project’s README.md to MDX and include it in the documentation.
- Searches for README.md in project root
- Converts markdown to Mintlify-compatible MDX
- Adds to navigation with specified title
readmeTitle
Type:string
Default: "README"
Title for the converted README page in navigation (only used if convertReadme: true).
Template Options
templates
Type:object
Configuration for Liquid template customization.
templates.userTemplateDir
Type:string
Path to directory containing custom Liquid templates.
layout.liquid- Base layout wrapperclass.liquid- Class documentationinterface.liquid- Interface documentationmethod.liquid- Method documentationproperty.liquid- Property documentationconstructor.liquid- Constructor documentationfunction.liquid- Function documentationenum.liquid- Enum documentationtype-alias.liquid- Type alias documentationnamespace.liquid- Namespace documentation
templates.cache
Type:boolean
Default: true
Whether to cache compiled templates for better performance.
- Recommended:
truefor production,falsefor template development - Clear cache by deleting
node_modules/.cache/mint-tsdocs/
templates.strict
Type:boolean
Default: true
Whether to enable strict mode in Liquid template engine.
- Throws errors on undefined variables
- Throws errors on invalid filters
- Helps catch template bugs during development
- Silently ignores undefined variables
- Silently ignores invalid filters
- May hide template errors
Message Reporting Options
apiExtractor.messages
Type:object
Configuration for controlling how different types of diagnostic messages are reported during API extraction.
messages.compilerMessageReporting
Type:Record<string, MessageReportingItem>
Configuration for TypeScript compiler diagnostic messages.
- TypeScript error codes (e.g.,
TS2551,TS2322) - Use
defaultto set default behavior for all messages
messages.extractorMessageReporting
Type:Record<string, MessageReportingItem>
Configuration for API Extractor diagnostic messages.
ae-missing-release-tag- Missing@public,@beta,@alpha, or@internaltagae-undocumented- Missing documentation commentae-forgotten-export- Exported type references unexported declaration
messages.tsdocMessageReporting
Type:Record<string, MessageReportingItem>
Configuration for TSDoc parser diagnostic messages.
tsdoc-param-tag-missing-hyphen-@paramtag missing hyphentsdoc-undefined-tag- Unrecognized TSDoc tagtsdoc-param-tag-with-invalid-name- Invalid parameter name in@param
MessageReportingItem
Configuration for how a specific message should be reported. Properties:logLevel
Type:'error' | 'warning' | 'none'
How to report this message type:
error- Report as an error (fails the build)warning- Report as a warning (doesn’t fail the build)none- Suppress the message entirely
addToApiReportFile
Type:boolean
Default: false
Whether to include this message in the API report file (.api.md).
Example:
API Extractor Options
apiExtractor
Type:object
Configuration for API Extractor integration.
apiExtractor.configPath
Type:string
Default: Auto-generated in .tsdocs/api-extractor.json
Path to custom API Extractor configuration file.
- If specified, mint-tsdocs will use your custom config
- If not specified, config is auto-generated from other settings
- Custom config gives you full control over API Extractor
apiExtractor.bundledPackages
Type:string[]
Default: []
List of package names to treat as bundled (include their declarations in the documentation).
- Document internal packages alongside main package
- Include types from dependencies in your documentation
apiExtractor.compiler
Type:object
TypeScript compiler configuration for API Extractor.
compiler.tsconfigFilePath
Type:string
Default: Auto-detected
Path to tsconfig.json file.
./tsconfig.json./tsconfig.build.json./tsconfig.prod.json
compiler.skipLibCheck
Type:boolean
Default: true
Whether to skip type checking of declaration files.
true for faster builds
apiExtractor.docModel
Type:object
Configuration for API Extractor’s documentation model output.
docModel.enabled
Type:boolean
Default: true
Whether to generate .api.json files.
true for mint-tsdocs to work
docModel.projectFolderUrl
Type:string
Base URL for source code links in generated documentation.
apiExtractor.apiReport
Type:object
Configuration for API report file generation (optional). API reports show a text summary of your public API surface and can be committed to track API changes over time.
apiReport.enabled
Type:boolean
Default: false
Whether to generate API report files (.api.md).
apiReport.reportFileName
Type:string
Default: "<unscopedPackageName>.api.md"
Name pattern for the API report file.
<unscopedPackageName>- Package name without@scope/<packageName>- Full package name
apiReport.reportFolder
Type:string
Default: "<projectFolder>/temp/"
Folder where the API report file will be written.
<projectFolder>- Project root directory
apiReport.reportTempFolder
Type:string
Default: "<projectFolder>/temp/"
Temporary folder used during API report generation.
apiExtractor.dtsRollup
Type:object
Configuration for .d.ts rollup generation (optional). Rollups combine multiple .d.ts files into a single file, optionally trimmed by release level.
dtsRollup.enabled
Type:boolean
Default: false
Whether to generate rolled-up .d.ts declaration files.
dtsRollup.publicTrimmedFilePath
Type:string
Path for the public-trimmed .d.ts rollup file. Includes only declarations marked with @public.
<unscopedPackageName>- Package name without@scope/<packageName>- Full package name<projectFolder>- Project root directory
dtsRollup.betaTrimmedFilePath
Type:string
Path for the beta-trimmed .d.ts rollup file. Includes declarations marked with @public and @beta.
dtsRollup.alphaTrimmedFilePath
Type:string
Path for the alpha-trimmed .d.ts rollup file. Includes declarations marked with @public, @beta, and @alpha.
dtsRollup.untrimmedFilePath
Type:string
Path for the untrimmed .d.ts rollup file. Includes all declarations regardless of release level (including @internal).
Complete Example
Validation
mint-tsdocs validates your configuration on startup. Common validation errors:| Error | Fix |
|---|---|
entryPoint is required | Add "entryPoint": "./lib/index.d.ts" |
entryPoint file not found | Run bun run build to generate .d.ts files |
Invalid docsJson path | Check path or create docs.json file |
Invalid template directory | Run mint-tsdocs customize -t ./templates |
Environment-Specific Configs
Use different configs for different environments: Development:Migration from api-documenter
If migrating from@microsoft/api-documenter:
-
Keep your api-extractor.json:
-
Or let mint-tsdocs generate it:
See Also
- Cheat Sheet - Quick command reference
- CLI Reference - Complete CLI documentation
- tsdoc.json Reference - TSDoc configuration file reference
- API Extractor Docs - API Extractor configuration
- TSDoc Specification - TSDoc tag reference

