{
  "openapi": "3.1.0",
  "info": {
    "title": "Read Content Extractor",
    "summary": "Extract readable text/markdown from a URL or raw HTML.",
    "description": "Fetches a URL (or accepts text/PDF), strips boilerplate, and returns clean content. Output formats: json, xml, md.",
    "version": "1.0.0",
    "contact": {
      "name": "baditaflorin",
      "url": "https://github.com/baditaflorin/utils-readcontent"
    }
  },
  "servers": [
    {
      "url": "https://utils-readcontent.0exec.com",
      "description": "Production"
    }
  ],
  "tags": [
    {
      "name": "nlp"
    },
    {
      "name": "scraping"
    },
    {
      "name": "content-extraction"
    }
  ],
  "paths": {
    "/": {
      "get": {
        "summary": "Extract content from URL or text",
        "responses": {
          "200": {
            "description": "depends on output param"
          },
          "400": {
            "description": "Bad request \u2014 missing/invalid params"
          },
          "500": {
            "description": "Server error"
          }
        },
        "parameters": [
          {
            "name": "url",
            "in": "query",
            "required": false,
            "description": "URL to fetch",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "text",
            "in": "query",
            "required": false,
            "description": "Raw HTML/text (alternative to url)",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "output",
            "in": "query",
            "required": false,
            "description": "json | xml | md",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "final",
            "in": "query",
            "required": false,
            "description": "true to return formatted final output",
            "schema": {
              "type": "string"
            }
          }
        ],
        "x-example-url": "https://utils-readcontent.0exec.com/?url=https://en.wikipedia.org/wiki/Anthropic&output=md"
      },
      "post": {
        "summary": "Same as GET, with multipart 'file' upload",
        "responses": {
          "200": {
            "description": "depends on output"
          },
          "400": {
            "description": "Bad request \u2014 missing/invalid params"
          },
          "500": {
            "description": "Server error"
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "string",
                "format": "binary"
              }
            }
          },
          "description": "multipart/form-data; field 'file' = binary"
        }
      }
    },
    "/.deploy/version.json": {
      "get": {
        "summary": "Deploy metadata (gateway-served)",
        "responses": {
          "200": {
            "description": "JSON with service, commit, build_date"
          }
        },
        "tags": [
          "meta"
        ]
      }
    },
    "/_gw_health": {
      "get": {
        "summary": "Gateway-level liveness (always 200 if gateway up)",
        "responses": {
          "200": {
            "description": "ok"
          }
        },
        "tags": [
          "meta"
        ]
      }
    },
    "/openapi.json": {
      "get": {
        "summary": "This OpenAPI document",
        "responses": {
          "200": {
            "description": "OpenAPI 3.1 spec"
          }
        },
        "tags": [
          "meta"
        ]
      }
    },
    "/llms.txt": {
      "get": {
        "summary": "LLM-friendly plain-text description of this service",
        "responses": {
          "200": {
            "description": "text/plain"
          }
        },
        "tags": [
          "meta"
        ]
      }
    }
  },
  "components": {}
}
