{
  "openapi": "3.1.0",
  "info": {
    "title": "AgentIndex AI/Bot-Friendly Link Directory API",
    "version": "2.5.0",
    "description": "Zero-CAPTCHA REST API & MCP Registry for discovering and submitting AI Agents, Micro-SaaS, and Developer Tools with automated SpamBrain-safe contextual backlink verification and Crypto/PayPal Fast-Track.",
    "contact": {
      "url": "https://directory.omnitoolcalc.com/agents.md"
    }
  },
  "servers": [
    {
      "url": "https://directory.omnitoolcalc.com"
    }
  ],
  "paths": {
    "/api/tools": {
      "get": {
        "operationId": "listTools",
        "summary": "List verified and featured AI tools in the directory",
        "parameters": [
          {
            "name": "category",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "q",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "tier",
            "in": "query",
            "schema": {
              "type": "string",
              "enum": [
                "featured",
                "free"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List of directory listings"
          }
        }
      }
    },
    "/api/tools/{slug}": {
      "get": {
        "operationId": "getToolBySlug",
        "summary": "Get detailed profile and verification audit logs for a single tool",
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Tool details and verification history"
          }
        }
      }
    },
    "/api/anchor-suggestions": {
      "get": {
        "operationId": "getAnchorSuggestions",
        "summary": "Generate natural contextual HTML backlink snippets with high anchor entropy",
        "parameters": [
          {
            "name": "name",
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "4 natural contextual link snippets"
          }
        }
      }
    },
    "/api/verify-backlink": {
      "post": {
        "operationId": "verifyBacklinkCompliance",
        "summary": "Dry-run inspect a URL for single-page contextual dofollow link & absence of sitewide footer footprint",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "backlink_url"
                ],
                "properties": {
                  "backlink_url": {
                    "type": "string"
                  },
                  "product_url": {
                    "type": "string"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Detailed DOM & Dual-Page verification result"
          }
        }
      }
    },
    "/api/payments/config": {
      "get": {
        "operationId": "getPaymentConfig",
        "summary": "Get Crypto On-Chain (Base, Solana, Arbitrum, Ethereum, BSC, Tron) & PayPal checkout parameters",
        "responses": {
          "200": {
            "description": "Payment configuration and x402 specs"
          }
        }
      }
    },
    "/api/payments/verify-crypto": {
      "post": {
        "operationId": "verifyCryptoPayment",
        "summary": "Verify an On-Chain USDC/USDT transaction hash and mint a Fast-Track API Key",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "chain",
                  "tx_hash"
                ],
                "properties": {
                  "chain": {
                    "type": "string",
                    "enum": [
                      "base",
                      "solana",
                      "arbitrum",
                      "ethereum",
                      "bsc",
                      "tron"
                    ]
                  },
                  "tx_hash": {
                    "type": "string"
                  },
                  "plan_id": {
                    "type": "string",
                    "enum": [
                      "pro_fast_track_29",
                      "featured_vip_49"
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Minted Fast-Track API Key"
          }
        }
      }
    },
    "/api/payments/verify-paypal": {
      "post": {
        "operationId": "verifyPaypalPayment",
        "summary": "Verify a PayPal Order ID and mint a Fast-Track API Key",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "order_id"
                ],
                "properties": {
                  "order_id": {
                    "type": "string"
                  },
                  "plan_id": {
                    "type": "string"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Minted Fast-Track API Key"
          }
        }
      }
    },
    "/api/submit": {
      "post": {
        "operationId": "submitTool",
        "summary": "Submit a new AI Tool or Micro-SaaS (Free Contextual Exchange or Paid Crypto/PayPal Fast-Track)",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "name",
                  "tagline",
                  "description",
                  "url",
                  "category_slug"
                ],
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "tagline": {
                    "type": "string"
                  },
                  "description": {
                    "type": "string"
                  },
                  "url": {
                    "type": "string"
                  },
                  "category_slug": {
                    "type": "string",
                    "enum": [
                      "ai-agents",
                      "developer-tools",
                      "automation-workflows",
                      "voice-audio-ai",
                      "seo-geo-growth",
                      "micro-saas"
                    ]
                  },
                  "pricing_model": {
                    "type": "string"
                  },
                  "tier": {
                    "type": "string",
                    "enum": [
                      "free",
                      "featured"
                    ]
                  },
                  "backlink_url": {
                    "type": "string"
                  },
                  "fast_track_key": {
                    "type": "string"
                  },
                  "chain": {
                    "type": "string"
                  },
                  "tx_hash": {
                    "type": "string"
                  },
                  "paypal_order_id": {
                    "type": "string"
                  },
                  "llms_txt_url": {
                    "type": "string"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Submission status and SEO link attribute granted"
          },
          "402": {
            "description": "x402 Payment Required instructions for Featured tier"
          }
        }
      }
    }
  }
}