{
  "openapi": "3.1.0",
  "info": {
    "title": "Truespar MCP Registry API",
    "description": "A free, open directory of Model Context Protocol servers, synced daily from the public MCP registries, deduplicated, ranked provenance-first, and checked with a real MCP handshake so you can tell which hosted endpoints still answer.\n\nNo account, no key. Rate-limited per IP; responses carry `X-RateLimit-Limit` and `X-RateLimit-Remaining`, and a 429 carries `Retry-After`.\n\nEverything listed here is **discovered, not vetted**. Truespar does not operate, host, proxy or endorse these servers, and does not review what they do with a request. `liveness` records only whether an endpoint answered a handshake when the catalog was last built. Every listing response repeats that caveat in its `note` field; relay it rather than stripping it.\n\nAn MCP endpoint over the same catalog is available at `/mcp` (Streamable HTTP), with the tools `find_mcp_servers` and `get_mcp_server`.",
    "contact": {
      "name": "Truespar",
      "url": "https://truespar.com"
    },
    "license": {
      "name": ""
    },
    "version": "1.0.0"
  },
  "servers": [
    {
      "url": "https://registry.truespar.com",
      "description": "Production"
    }
  ],
  "paths": {
    "/v1/categories": {
      "get": {
        "tags": [
          "reference"
        ],
        "summary": "The category facet with counts.",
        "operationId": "list_categories",
        "responses": {
          "200": {
            "description": "Categories with counts",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CategoriesResponse"
                }
              }
            }
          },
          "429": {
            "description": "Per-IP rate limit exceeded; see Retry-After",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/servers": {
      "get": {
        "tags": [
          "servers"
        ],
        "summary": "Search and list MCP servers.",
        "description": "The ranked catalog, filtered. Every response carries a `note` caveat: these\nare servers discovered in the open ecosystem, not vetted or operated by us.",
        "operationId": "list_servers",
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "description": "Free text, minimum 2 characters. Matched against name, description,\ndomain, registry name, categories and tool names.",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "stripe"
          },
          {
            "name": "category",
            "in": "query",
            "description": "Exact category filter. See `/v1/categories`.",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "payments"
          },
          {
            "name": "tier",
            "in": "query",
            "description": "Provenance tier: `S` first-party or vendor-verified, `A` trusted OSS,\n`B`/`C` community, `D` no usable home. Case-insensitive.",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "S"
          },
          {
            "name": "hostable",
            "in": "query",
            "description": "True returns only servers with a hosted endpoint reachable over the\nnetwork; false returns only local stdio/package servers.",
            "required": false,
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "liveness",
            "in": "query",
            "description": "Result of the last check: `ok-tools`, `ok`, `auth-required`, `dead`.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Page size. Default 25, maximum 100. Clamped, not rejected.",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "description": "Rows to skip. Default 0.",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A page of matching servers",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ListResponse"
                }
              }
            }
          },
          "400": {
            "description": "An unknown category, tier or liveness value, or a query under 2 characters",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            }
          },
          "429": {
            "description": "Per-IP rate limit exceeded; see Retry-After",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/servers/{key}": {
      "get": {
        "tags": [
          "servers"
        ],
        "summary": "Fetch one server by its canonical key.",
        "description": "The key comes from a search result and contains slashes; it is matched as a\nwildcard path segment, so pass it literally and unescaped.",
        "operationId": "get_server",
        "parameters": [
          {
            "name": "key",
            "in": "path",
            "description": "Canonical key from a search result",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "repo:github.com/stripe/agent-toolkit"
          }
        ],
        "responses": {
          "200": {
            "description": "The server, with a connection block",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DetailResponse"
                }
              }
            }
          },
          "404": {
            "description": "No server with that key in the catalog",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            }
          },
          "429": {
            "description": "Per-IP rate limit exceeded; see Retry-After",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/stats": {
      "get": {
        "tags": [
          "reference"
        ],
        "summary": "Catalog size, composition and freshness.",
        "operationId": "get_stats",
        "responses": {
          "200": {
            "description": "Catalog statistics",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CatalogStats"
                }
              }
            }
          },
          "429": {
            "description": "Per-IP rate limit exceeded; see Retry-After",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiError"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "ApiError": {
        "type": "object",
        "description": "A single error, the shape every non-2xx response takes.",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "string",
            "example": "Unknown tier \"Z\". Valid tiers: S, A, B, C, D."
          }
        }
      },
      "CatalogStats": {
        "type": "object",
        "required": [
          "servers",
          "hostable",
          "byTier",
          "byLiveness",
          "categories"
        ],
        "properties": {
          "byLiveness": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TierCount"
            }
          },
          "byTier": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TierCount"
            }
          },
          "catalogAsOf": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "categories": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CategoryCount"
            }
          },
          "hostable": {
            "type": "integer",
            "format": "int64",
            "description": "How many advertise a hosted endpoint."
          },
          "lastSyncStatus": {
            "type": [
              "string",
              "null"
            ]
          },
          "servers": {
            "type": "integer",
            "format": "int64"
          }
        }
      },
      "CategoriesResponse": {
        "type": "object",
        "description": "The body of `GET /v1/categories`.",
        "required": [
          "categories"
        ],
        "properties": {
          "categories": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CategoryCount"
            }
          }
        }
      },
      "CategoryCount": {
        "type": "object",
        "required": [
          "category",
          "count"
        ],
        "properties": {
          "category": {
            "type": "string"
          },
          "count": {
            "type": "integer",
            "format": "int64"
          }
        }
      },
      "Connection": {
        "type": "object",
        "description": "How to reach a server: the part a caller needs in order to actually use it.",
        "required": [
          "hostable",
          "authRequired",
          "note"
        ],
        "properties": {
          "authRequired": {
            "type": "boolean",
            "description": "True when the last check came back 401/403, so credentials are needed."
          },
          "hostable": {
            "type": "boolean",
            "description": "True when there is a hosted endpoint to connect to."
          },
          "note": {
            "type": "string",
            "description": "Plain-language summary of what a caller can do with this entry."
          },
          "recommended": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RemoteEndpoint",
                "description": "The endpoint to try first, if any: a `streamable-http` transport is\npreferred over `sse`, which is the older of the two."
              }
            ]
          }
        }
      },
      "DetailResponse": {
        "type": "object",
        "description": "The body of `GET /v1/servers/{key}`.",
        "required": [
          "note",
          "server"
        ],
        "properties": {
          "note": {
            "type": "string"
          },
          "server": {
            "$ref": "#/components/schemas/ServerDetail"
          }
        }
      },
      "ListResponse": {
        "type": "object",
        "description": "The body of `GET /v1/servers`.\n\nA struct rather than an ad-hoc `json!`, so the OpenAPI document describes\nthe bytes that actually go out. `note` rides on every listing on purpose:\na caller acting on this data is about to connect to a third party, and the\ncaveat should travel with the results rather than live only in the docs.",
        "required": [
          "note",
          "total",
          "limit",
          "offset",
          "results"
        ],
        "properties": {
          "catalogAsOf": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the catalog last finished a successful sync."
          },
          "limit": {
            "type": "integer",
            "format": "int64"
          },
          "note": {
            "type": "string"
          },
          "offset": {
            "type": "integer",
            "format": "int64"
          },
          "results": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ServerSummary"
            }
          },
          "total": {
            "type": "integer",
            "format": "int64",
            "description": "Total matching the filter, not the length of `results`."
          }
        }
      },
      "PackageRef": {
        "type": "object",
        "properties": {
          "name": {
            "type": [
              "string",
              "null"
            ]
          },
          "registry": {
            "type": [
              "string",
              "null"
            ],
            "description": "Package registry, e.g. `npm`, `pypi`, `oci`."
          }
        }
      },
      "RemoteEndpoint": {
        "type": "object",
        "description": "Deserialize as well as Serialize: the endpoints come back from Postgres as\nan aggregated JSON array and are parsed straight into this type.",
        "properties": {
          "transport": {
            "type": [
              "string",
              "null"
            ],
            "description": "Transport advertised by the registry, e.g. `streamable-http`, `sse`."
          },
          "url": {
            "type": [
              "string",
              "null"
            ]
          }
        }
      },
      "ServerDetail": {
        "allOf": [
          {
            "$ref": "#/components/schemas/ServerSummary"
          },
          {
            "type": "object",
            "required": [
              "connection",
              "tools",
              "packages",
              "sources",
              "authorityReasons"
            ],
            "properties": {
              "authorityReasons": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Why it landed in its tier, e.g. `dns-verified-namespace:com.stripe`."
              },
              "connection": {
                "$ref": "#/components/schemas/Connection"
              },
              "downloadCount": {
                "type": [
                  "integer",
                  "null"
                ],
                "format": "int64"
              },
              "firstSeen": {
                "type": [
                  "string",
                  "null"
                ],
                "format": "date-time"
              },
              "lastHandshakeAt": {
                "type": [
                  "string",
                  "null"
                ],
                "format": "date-time"
              },
              "lastSeen": {
                "type": [
                  "string",
                  "null"
                ],
                "format": "date-time"
              },
              "officialStatus": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Publication status upstream: `active`, `deprecated`, `deleted`."
              },
              "packages": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/PackageRef"
                },
                "description": "Installable packages for a locally-run server."
              },
              "registryName": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Reverse-DNS name in the official registry, when it has one."
              },
              "registryNamespace": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "sources": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Which upstream registries listed this server."
              },
              "spdxLicense": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "tools": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Tool names, when a source published them."
              }
            }
          }
        ],
        "description": "The full record for one server, including everything needed to connect."
      },
      "ServerSummary": {
        "type": "object",
        "description": "One row of a list or search response.",
        "required": [
          "key",
          "categories",
          "hostable",
          "remoteEndpoints"
        ],
        "properties": {
          "authorityTier": {
            "type": [
              "string",
              "null"
            ],
            "description": "`S` first-party or vendor-verified, `A` trusted OSS or high adoption,\n`B`/`C` community. Higher means better-established provenance."
          },
          "categories": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "domain": {
            "type": [
              "string",
              "null"
            ],
            "description": "Host of the server's best URL (remote endpoint, else homepage, else repo)."
          },
          "githubStars": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int32"
          },
          "homepage": {
            "type": [
              "string",
              "null"
            ]
          },
          "hostable": {
            "type": "boolean",
            "description": "True when the server advertises a hosted endpoint, so a client can\nconnect to it over the network. False means it runs locally as a\nstdio/package server."
          },
          "key": {
            "type": "string",
            "description": "Stable id; this is what `/v1/servers/{key}` takes."
          },
          "liveness": {
            "type": [
              "string",
              "null"
            ],
            "description": "Result of the last check on the hosted endpoint: `ok-tools`, `ok`,\n`auth-required`, or `dead`. Null for a local server, which is never\nchecked."
          },
          "name": {
            "type": [
              "string",
              "null"
            ]
          },
          "rank": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int32",
            "description": "Position in the ranked catalog. Lower is better."
          },
          "remoteEndpoints": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RemoteEndpoint"
            }
          },
          "repoUrl": {
            "type": [
              "string",
              "null"
            ]
          },
          "toolCount": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int32"
          }
        }
      },
      "TierCount": {
        "type": "object",
        "required": [
          "tier",
          "count"
        ],
        "properties": {
          "count": {
            "type": "integer",
            "format": "int64"
          },
          "tier": {
            "type": "string"
          }
        }
      }
    }
  },
  "tags": [
    {
      "name": "servers",
      "description": "Search and retrieve MCP servers"
    },
    {
      "name": "reference",
      "description": "Category vocabulary and catalog statistics"
    }
  ]
}