← Back to App

AI Integration

Connect any AI assistant to manage gists via our API. Supports ChatGPT, Claude, and any agent with HTTP capabilities.

Quick Start

Get Started in 3 Steps

  1. Authenticate: Complete the device code flow
  2. Connect: Configure your AI with our OpenAPI spec
  3. Manage: Create, edit, and publish gists conversationally
Auto-Discovery

Discoverable Endpoints

AI agents can auto-discover our API via these standard endpoints:

MCP Discovery: /.well-known/mcp.json
AI Plugin: /.well-known/ai-plugin.json
AI Metadata: /ai.txt
OpenAPI Spec: /api/docs
Authentication

Device Code OAuth Flow

Secure, user-friendly authentication for headless AI agents:

  1. AI makes POST request to /api/auth/device/code
  2. Receives a user-friendly code (e.g., "ABC-DEF")
  3. User visits /auth/device/verify and enters code
  4. AI polls /api/auth/device/token until approved
  5. Receives long-lived access token (1 year validity)
Approve a Device →
Supported Platforms

Works With Any AI

ChatGPT (Custom GPT)

Create a Custom GPT and import our OpenAPI spec for instant integration

Claude Desktop (MCP)

Auto-discovers via MCP manifest or use the local MCP server

Any HTTP-capable AI

Use our REST API with bearer token authentication

Capabilities

What AI Agents Can Do

  • List gists (with filters by date, category, publication status)
  • Get details of specific gists
  • Create new gists with custom content
  • Update existing gists
  • Publish and unpublish gists
  • Generate gists using AI (Claude)
  • Manage gists based on role permissions (admin/team member)
Example

Try It Out

Tell your AI assistant:

"I have a gist management API at https://thegist.fun. Check the OpenAPI spec at /api/docs and help me authenticate using the device code flow. Then list my recent gists."

The AI will fetch the spec, understand all endpoints, guide you through authentication, and start managing your gists!

Resources

Documentation & Links

OpenAPI Specification →MCP Discovery Manifest →AI Metadata (ai.txt) →Authorize Device →