Documentation Index
Fetch the complete documentation index at: https://mintlify.com/nicobailon/pi-mcp-adapter/llms.txt
Use this file to discover all available pages before exploring further.
Overview
The/mcp-auth command manages OAuth authentication for MCP servers. It displays setup instructions and token status for servers configured with auth: "oauth".
Command Signature
Arguments
The name of the MCP server to authenticate (must match a key in
mcpServers config).Usage
Authentication Flow
Pi MCP Adapter uses file-based token storage for OAuth. Tokens are obtained externally and stored in the expected location.Steps
-
Run the command:
- Follow server-specific instructions: The command displays the OAuth setup process for the server (usually involves visiting a URL, authorizing the app, and obtaining a token).
-
Store the token:
Save the token to the file path specified by the server. Typically:
-
Reconnect the server:
Token File Format
Most MCP servers expect tokens in this format:Server Configuration
To enable OAuth for a server, setauth: "oauth" in your mcp.json:
Token Storage Location
Tokens are stored in:Checking Token Status
Run/mcp-auth <server> to see:
- Whether a token file exists
- Token expiration status (if applicable)
- Setup instructions if no token is found
Limitations
Current Limitations
- No browser flow - No automatic redirect or token exchange
- No token refresh - Expired tokens must be manually renewed
- Manual token files - You must create and update token files yourself
Bearer Token Alternative
If a server supports static bearer tokens instead of OAuth, use thebearerToken or bearerTokenEnv fields instead:
Examples
GitHub MCP Server
-
Configure the server:
-
Run the auth command:
- Follow the instructions to obtain a GitHub personal access token
-
Save the token:
-
Reconnect:
Slack MCP Server
-
Configure the server:
-
Run the auth command:
- Obtain token from Slack’s OAuth flow
-
Save the token:
-
Reconnect:
Error Messages
Server Not Found
Invalid Server Name
mcp.json configuration.
Not an OAuth Server
If the server doesn’t haveauth: "oauth" configured, the command may still display generic instructions, but authentication won’t be used.
Related
- /mcp Command - Manage MCP servers
- Server Options - Configure authentication
- OAuth Token Format - Token file structure