OpsTrailsDocs
Console

ChatGPT

Connect OpsTrails to ChatGPT for AI-powered querying of your operational timeline. ChatGPT uses OAuth for authentication — no API key needed. See the MCP Overview for background on how the protocol works.

1. Enable Developer Mode

2. Add MCP Server

3. Authorize

4. Start Using

Return to ChatGPT and ask questions about your operational timeline:

⚠️ Warning

ChatGPT does not automatically use MCP tools. You must explicitly mention OpsTrails in your prompt for ChatGPT to invoke the integration — for example, “Use OpsTrails to…” or “Check OpsTrails for…”.

💡 Info

No API key needed — ChatGPT handles authentication automatically via OAuth. The connection creates a read-only MCP API key named “MCP — ChatGPT” visible on the API Keys page. You can revoke access anytime by deleting that key.

Troubleshooting

Developer Mode not available

  • Developer Mode requires a ChatGPT Plus, Team, or Enterprise plan
  • If you don't see the option under Apps & Connectors → Advanced, check that your plan supports MCP integrations

Integration not connecting

  • Verify the MCP server URL is exactly https://api.opstrails.dev/api/mcp/mcp — a common mistake is to omit the trailing /mcp
  • Make sure Developer Mode is toggled on before adding the server
  • Try removing the integration and re-adding it

ChatGPT not using OpsTrails tools

  • ChatGPT requires you to mention OpsTrails by name in your prompt
  • Instead of “What was deployed today?”, try “Use OpsTrails to show what was deployed today”
  • Verify the integration is listed under your active MCP servers in Settings

Permission denied

  • During the OAuth flow, make sure you selected the correct organization
  • Check the API Keys page in the console — verify the “MCP — ChatGPT” key exists and has not been revoked
  • If the key was deleted, remove the integration in ChatGPT and re-authorize

No events returned

  • Your organization may not have any events yet — send a test event via the Quick Start guide
  • Check that events fall within your plan's retention window (Free: 7 days, Starter: 30 days, Pro: 90 days)
  • Try a broader query like “Use OpsTrails to show me all events” to confirm the connection is working

What Happens Behind the Scenes

When you authorize ChatGPT to access OpsTrails, the following happens:

  1. ChatGPT initiates an OAuth 2.0 authorization flow with the OpsTrails API
  2. You sign in to OpsTrails and select which organization to connect
  3. OpsTrails creates a READ_ONLY MCP API key named “MCP — ChatGPT”, scoped to the selected organization
  4. This key is visible on your console's API Keys page alongside any manually created keys
  5. ChatGPT uses this key to authenticate all MCP tool calls (event queries, metric lookups, etc.)

The key is read-only — ChatGPT can query events and metrics but cannot create or modify events. To revoke access at any time, simply delete the “MCP — ChatGPT” key from the API Keys page in the console. For a full list of available tools, see the MCP Tools Reference.