{
  "openapi": "3.1.0",
  "info": {
    "title": "x402-tools.com directory API",
    "version": "1.0.0",
    "description": "Find paid x402 APIs for AI agents."
  },
  "servers": [
    {
      "url": "https://x402-tools.com"
    }
  ],
  "paths": {
    "/api/tools": {
      "get": {
        "operationId": "searchTools",
        "summary": "Search x402 tools",
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "category",
            "in": "query",
            "schema": {
              "type": "string",
              "enum": [
                "search",
                "scraping",
                "ai",
                "social",
                "trading",
                "crypto-data",
                "finance",
                "news",
                "data",
                "media",
                "compute",
                "storage",
                "communication",
                "commerce",
                "identity",
                "fun",
                "other"
              ]
            }
          },
          {
            "name": "network",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "max_price",
            "in": "query",
            "schema": {
              "type": "number"
            }
          },
          {
            "name": "active",
            "in": "query",
            "schema": {
              "type": "string",
              "enum": [
                "1"
              ]
            }
          },
          {
            "name": "sort",
            "in": "query",
            "schema": {
              "type": "string",
              "enum": [
                "popular",
                "calls",
                "price",
                "newest"
              ]
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "maximum": 200
            }
          },
          {
            "name": "offset",
            "in": "query",
            "schema": {
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Matching tools"
          }
        }
      }
    },
    "/api/tools/{id}": {
      "get": {
        "operationId": "getTool",
        "summary": "Get one tool",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Tool"
          }
        }
      }
    },
    "/api/categories": {
      "get": {
        "operationId": "listCategories",
        "summary": "List categories",
        "responses": {
          "200": {
            "description": "Categories"
          }
        }
      }
    },
    "/api/stats": {
      "get": {
        "operationId": "getStats",
        "summary": "Directory stats",
        "responses": {
          "200": {
            "description": "Stats"
          }
        }
      }
    }
  }
}