{
  "openapi": "3.1.0",
  "info": {
    "title": "Rendershed screenshot API",
    "version": "0.1.0",
    "description": "A screenshot API that removes consent walls, sign-in modals and paywall overlays before it captures. Most screenshot APIs succeed 93% of the time and return something usable 69% of the time — we measured it, and fixed it."
  },
  "servers": [
    {
      "url": "https://shots.rendershed.com"
    }
  ],
  "paths": {
    "/v1/render": {
      "post": {
        "operationId": "renderScreenshot",
        "summary": "Render a web page to an image, with overlays removed",
        "description": "Authentication is optional. Without a key the call runs on the anonymous tier: 20 renders an hour, metered per IP, viewport capture only. A key raises the limit and unlocks paid features.",
        "security": [
          {
            "apiKey": []
          },
          {}
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "url"
                ],
                "properties": {
                  "url": {
                    "type": "string",
                    "description": "The page to render. http and https only."
                  },
                  "width": {
                    "type": "integer",
                    "description": "Viewport width, 200–3840.",
                    "default": "1440"
                  },
                  "height": {
                    "type": "integer",
                    "description": "Viewport height, 200–4320.",
                    "default": "900"
                  },
                  "dpr": {
                    "type": "number",
                    "description": "Device pixel ratio, up to 3.",
                    "default": "1"
                  },
                  "full_page": {
                    "type": "boolean",
                    "description": "Capture the whole document, not just the viewport.",
                    "default": false
                  },
                  "format": {
                    "type": "string",
                    "description": "png, jpeg or webp.",
                    "default": "png"
                  },
                  "quality": {
                    "type": "integer",
                    "description": "1–100, for jpeg and webp."
                  },
                  "overlay_mode": {
                    "type": "string",
                    "description": "off, hide or dismiss.",
                    "default": "dismiss"
                  },
                  "block_ads": {
                    "type": "boolean",
                    "description": "Drop known ad and tracker requests.",
                    "default": true
                  },
                  "dark_mode": {
                    "type": "boolean",
                    "description": "Render with prefers-color-scheme: dark.",
                    "default": false
                  },
                  "wait_for_selector": {
                    "type": "string",
                    "description": "Wait for a CSS selector before capture."
                  },
                  "delay_ms": {
                    "type": "integer",
                    "description": "Extra settle time, up to 10000.",
                    "default": "0"
                  },
                  "locale": {
                    "type": "string",
                    "description": "Browser locale.",
                    "default": "en-US"
                  },
                  "timezone": {
                    "type": "string",
                    "description": "IANA timezone.",
                    "default": "UTC"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The rendered image",
            "content": {
              "image/png": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              }
            }
          },
          "400": {
            "description": "Invalid parameters, or a URL that will not be fetched"
          },
          "402": {
            "description": "The plan does not include the requested feature"
          },
          "403": {
            "description": "Invalid API key, or a signature that does not match"
          },
          "429": {
            "description": "Hourly rate limit or monthly allowance reached"
          },
          "504": {
            "description": "Render deadline exceeded"
          }
        }
      }
    },
    "/v1/sign": {
      "post": {
        "operationId": "signRenderUrl",
        "summary": "Mint a signed render URL usable directly in an img tag",
        "security": [
          {
            "apiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "A signed relative URL"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "apiKey": {
        "type": "apiKey",
        "in": "header",
        "name": "X-API-Key"
      }
    }
  }
}