> ## Documentation Index
> Fetch the complete documentation index at: https://docs.url2llm.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Scrape

> Fetch one page and return the requested formats.



## OpenAPI

````yaml /openapi-public.json post /v1/scrape
openapi: 3.1.0
info:
  title: url2llm
  version: 0.1.0
servers: []
security: []
paths:
  /v1/scrape:
    post:
      tags:
        - public
        - scrape
      summary: Scrape
      description: Fetch one page and return the requested formats.
      operationId: scrape
      parameters:
        - in: header
          name: Idempotency-Key
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Idempotency-Key
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ScrapeRequest'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIResponse_ScrapeResult_'
          description: Successful Response
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Bad Request
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Unauthorized
        '402':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Payment Required
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Forbidden
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Not Found
        '409':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Conflict
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Unprocessable Content
        '429':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Too Many Requests
        '500':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Internal Server Error
        '503':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Service Unavailable
        '504':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResult'
          description: Gateway Timeout
      security:
        - HTTPBearer: []
components:
  schemas:
    ScrapeRequest:
      additionalProperties: false
      properties:
        blockAds:
          default: true
          title: Blockads
          type: boolean
        excludeTags:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Excludetags
        formats:
          anyOf:
            - $ref: '#/components/schemas/ScrapeFormats'
            - items:
                enum:
                  - markdown
                  - html
                  - rawHtml
                  - links
                  - screenshot
                  - screenshot@fullPage
                  - assets
                  - branding
                type: string
              type: array
          title: Formats
        headers:
          anyOf:
            - additionalProperties:
                type: string
              type: object
            - type: 'null'
          title: Headers
        includeTags:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Includetags
        jsonPrompt:
          anyOf:
            - maxLength: 10000
              type: string
            - type: 'null'
          title: Jsonprompt
        jsonSchema:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Jsonschema
        location:
          anyOf:
            - $ref: '#/components/schemas/Location'
            - type: 'null'
        mobile:
          default: false
          title: Mobile
          type: boolean
        onlyMainContent:
          default: true
          title: Onlymaincontent
          type: boolean
        renderJs:
          default: true
          title: Renderjs
          type: boolean
        screenshotParams:
          anyOf:
            - $ref: '#/components/schemas/ScreenshotParams'
            - type: 'null'
        timeout:
          default: 30000
          exclusiveMinimum: 0
          maximum: 120000
          title: Timeout
          type: integer
        url:
          maxLength: 8192
          minLength: 1
          title: Url
          type: string
        waitFor:
          default: 0
          maximum: 60000
          minimum: 0
          title: Waitfor
          type: integer
      required:
        - url
      title: ScrapeRequest
      type: object
    APIResponse_ScrapeResult_:
      properties:
        data:
          anyOf:
            - $ref: '#/components/schemas/ScrapeResult'
            - type: 'null'
        message:
          anyOf:
            - type: string
            - type: 'null'
          title: Message
        meta:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Meta
        request_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Request Id
        success:
          default: true
          title: Success
          type: boolean
      required:
        - success
        - data
        - meta
        - message
        - request_id
      title: APIResponse[ScrapeResult]
      type: object
    ErrorResult:
      properties:
        error:
          $ref: '#/components/schemas/ApiError'
        request_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Request Id
        success:
          default: false
          title: Success
          type: boolean
      required:
        - success
        - error
        - request_id
      title: ErrorResult
      type: object
    ScrapeFormats:
      additionalProperties: false
      properties:
        assets:
          default: false
          title: Assets
          type: boolean
        branding:
          default: false
          title: Branding
          type: boolean
        html:
          default: false
          title: Html
          type: boolean
        links:
          default: false
          title: Links
          type: boolean
        markdown:
          default: false
          title: Markdown
          type: boolean
        rawHtml:
          default: false
          title: Rawhtml
          type: boolean
        screenshot:
          default: false
          title: Screenshot
          type: boolean
      title: ScrapeFormats
      type: object
    Location:
      additionalProperties: false
      properties:
        country:
          default: us
          maxLength: 2
          minLength: 2
          pattern: ^[A-Za-z]{2}$
          title: Country
          type: string
        languages:
          items:
            type: string
          title: Languages
          type: array
      title: Location
      type: object
    ScreenshotParams:
      additionalProperties: false
      properties:
        delivery:
          default: base64
          enum:
            - base64
            - url
          title: Delivery
          type: string
        format:
          default: jpeg
          enum:
            - png
            - jpeg
            - webp
          title: Format
          type: string
        fullPage:
          default: false
          title: Fullpage
          type: boolean
        quality:
          anyOf:
            - maximum: 100
              minimum: 1
              type: integer
            - type: 'null'
          description: JPEG/WebP quality; defaults to 80.
          title: Quality
      title: ScreenshotParams
      type: object
    ScrapeResult:
      description: Return page metadata and nullable requested outputs.
      properties:
        assets:
          anyOf:
            - items:
                $ref: '#/components/schemas/BrandAsset'
              type: array
            - type: 'null'
          title: Assets
        branding:
          anyOf:
            - $ref: '#/components/schemas/Branding'
            - type: 'null'
        html:
          anyOf:
            - type: string
            - type: 'null'
          title: Html
        json:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Json
        links:
          anyOf:
            - items:
                $ref: '#/components/schemas/Link'
              type: array
            - type: 'null'
          title: Links
        markdown:
          anyOf:
            - type: string
            - type: 'null'
          title: Markdown
        metadata:
          $ref: '#/components/schemas/ScrapeMetadata'
        raw_html:
          anyOf:
            - type: string
            - type: 'null'
          title: Raw Html
        screenshot:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Image data URL for base64 delivery, or a public image URL for URL
            delivery.
          title: Screenshot
        summary:
          anyOf:
            - type: string
            - type: 'null'
          title: Summary
      required:
        - metadata
        - markdown
        - html
        - raw_html
        - links
        - screenshot
        - json
        - summary
        - assets
        - branding
      title: ScrapeResult
      type: object
    ApiError:
      properties:
        code:
          title: Code
          type: string
        details:
          anyOf:
            - {}
            - type: 'null'
          title: Details
        message:
          title: Message
          type: string
      required:
        - code
        - message
        - details
      title: ApiError
      type: object
    BrandAsset:
      description: One image or video the page references, as produced by render.assets.
      properties:
        asset_type:
          description: image or video
          title: Asset Type
          type: string
        context:
          anyOf:
            - type: string
            - type: 'null'
          description: 'Images only: page or product_gallery'
          title: Context
        filename:
          anyOf:
            - type: string
            - type: 'null'
          description: Derived from the title or alt text
          title: Filename
        metadata:
          $ref: '#/components/schemas/AssetMetadata'
        mimetype:
          title: Mimetype
          type: string
        title:
          default: ''
          title: Title
          type: string
        url:
          title: Url
          type: string
      required:
        - url
        - filename
        - title
        - asset_type
        - context
        - mimetype
        - metadata
      title: BrandAsset
      type: object
    Branding:
      description: >-
        The composed brand kit, as produced by render.branding. Unsignalled
        roles stay null.
      properties:
        colors:
          $ref: '#/components/schemas/BrandingColors'
        components:
          $ref: '#/components/schemas/BrandingComponents'
        fonts:
          $ref: '#/components/schemas/BrandingFonts'
        logo:
          $ref: '#/components/schemas/BrandingLogo'
        spacing:
          $ref: '#/components/schemas/BrandingSpacing'
        typography:
          $ref: '#/components/schemas/BrandingTypography'
      required:
        - colors
        - fonts
        - typography
        - spacing
        - components
        - logo
      title: Branding
      type: object
    Link:
      description: One anchor on the page, as produced by render.links.
      properties:
        image_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Image Url
        internal:
          default: false
          title: Internal
          type: boolean
        normalized_url:
          title: Normalized Url
          type: string
        text:
          default: ''
          title: Text
          type: string
        title:
          default: ''
          title: Title
          type: string
        type:
          title: Type
          type: string
        url:
          title: Url
          type: string
      required:
        - url
        - normalized_url
        - type
        - text
        - title
        - image_url
        - internal
      title: Link
      type: object
    ScrapeMetadata:
      properties:
        author:
          anyOf:
            - type: string
            - type: 'null'
          title: Author
        credits_used:
          default: 0
          description: Credits this request charged. Zero on an unbilled failure
          title: Credits Used
          type: integer
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
        final_url:
          title: Final Url
          type: string
        language:
          anyOf:
            - type: string
            - type: 'null'
          title: Language
        page_id:
          anyOf:
            - type: integer
            - type: 'null'
          title: Page Id
        published_at:
          anyOf:
            - type: string
            - type: 'null'
          title: Published At
        request_id:
          anyOf:
            - type: integer
            - type: 'null'
          title: Request Id
        scrape_id:
          anyOf:
            - type: integer
            - type: 'null'
          title: Scrape Id
        source_url:
          title: Source Url
          type: string
        status_code:
          title: Status Code
          type: integer
        title:
          anyOf:
            - type: string
            - type: 'null'
          title: Title
      required:
        - title
        - description
        - author
        - published_at
        - language
        - source_url
        - final_url
        - status_code
        - request_id
        - scrape_id
        - page_id
        - credits_used
      title: ScrapeMetadata
      type: object
    AssetMetadata:
      description: What is known about one asset beyond its URL. Keys differ by asset_type.
      properties:
        alt:
          anyOf:
            - type: string
            - type: 'null'
          description: Images only
          title: Alt
        height:
          default: 0
          title: Height
          type: integer
        poster_url:
          anyOf:
            - type: string
            - type: 'null'
          description: html5 video only
          title: Poster Url
        provider:
          anyOf:
            - type: string
            - type: 'null'
          description: 'Videos only: html5, youtube or vimeo'
          title: Provider
        width:
          default: 0
          title: Width
          type: integer
      required:
        - width
        - height
        - alt
        - provider
        - poster_url
      title: AssetMetadata
      type: object
    BrandingColors:
      description: The palette by role. Vocabulary shared with scalistro ColorRole.
      properties:
        accent:
          anyOf:
            - type: string
            - type: 'null'
          description: Top palette colour no other role wears
          title: Accent
        action:
          anyOf:
            - type: string
            - type: 'null'
          description: Fill of the primary call to action
          title: Action
        body:
          anyOf:
            - type: string
            - type: 'null'
          description: Colour running text is set in
          title: Body
        heading:
          anyOf:
            - type: string
            - type: 'null'
          description: Colour headings are set in
          title: Heading
        link:
          anyOf:
            - type: string
            - type: 'null'
          description: Colour of an in-content anchor
          title: Link
        surface:
          anyOf:
            - type: string
            - type: 'null'
          description: The page ground
          title: Surface
      required:
        - action
        - heading
        - body
        - surface
        - accent
        - link
      title: BrandingColors
      type: object
    BrandingComponents:
      description: The three controls a brand kit shows.
      properties:
        input:
          $ref: '#/components/schemas/ComponentStyle'
        primary_button:
          $ref: '#/components/schemas/ComponentStyle'
        secondary_button:
          $ref: '#/components/schemas/ComponentStyle'
      required:
        - primary_button
        - secondary_button
        - input
      title: BrandingComponents
      type: object
    BrandingFonts:
      description: Which declared family dresses headings, and which dresses running text.
      properties:
        body:
          anyOf:
            - type: string
            - type: 'null'
          title: Body
        heading:
          anyOf:
            - type: string
            - type: 'null'
          title: Heading
      required:
        - heading
        - body
      title: BrandingFonts
      type: object
    BrandingLogo:
      description: >-
        The brand mark: its lockup and its square form. Slots match scalistro
        LogoSlot.
      properties:
        favicon:
          anyOf:
            - type: string
            - type: 'null'
          title: Favicon
        primary:
          anyOf:
            - type: string
            - type: 'null'
          title: Primary
      required:
        - primary
        - favicon
      title: BrandingLogo
      type: object
    BrandingSpacing:
      description: The grid the page sits on.
      properties:
        base_unit_px:
          anyOf:
            - type: integer
            - type: 'null'
          description: Step the spacing scale is built on, null when no grid
          title: Base Unit Px
        border_radius_px:
          anyOf:
            - type: number
            - type: 'null'
          description: Most common non-pill control corner radius
          title: Border Radius Px
      required:
        - base_unit_px
        - border_radius_px
      title: BrandingSpacing
      type: object
    BrandingTypography:
      description: The rendered scale, one binding per level.
      properties:
        body:
          $ref: '#/components/schemas/TypographyBinding'
        h1:
          $ref: '#/components/schemas/TypographyBinding'
        h2:
          $ref: '#/components/schemas/TypographyBinding'
        h3:
          $ref: '#/components/schemas/TypographyBinding'
      required:
        - h1
        - h2
        - h3
        - body
      title: BrandingTypography
      type: object
    ComponentStyle:
      description: The resolved styles of one component.
      properties:
        background:
          anyOf:
            - type: string
            - type: 'null'
          title: Background
        border:
          anyOf:
            - type: string
            - type: 'null'
          title: Border
        border_radius_px:
          anyOf:
            - type: number
            - type: 'null'
          title: Border Radius Px
        font_family:
          anyOf:
            - type: string
            - type: 'null'
          title: Font Family
        font_size_px:
          anyOf:
            - type: number
            - type: 'null'
          title: Font Size Px
        font_weight:
          anyOf:
            - type: integer
            - type: 'null'
          title: Font Weight
        text:
          anyOf:
            - type: string
            - type: 'null'
          title: Text
      required:
        - background
        - text
        - border
        - border_radius_px
        - font_size_px
        - font_weight
        - font_family
      title: ComponentStyle
      type: object
    TypographyBinding:
      description: >-
        One typographic role: the family, how it is set, and the size it is set
        at.
      properties:
        case:
          anyOf:
            - type: string
            - type: 'null'
          description: sentence, upper, lower or title
          title: Case
        fallback_family:
          anyOf:
            - type: string
            - type: 'null'
          description: Generic family the stack ends on
          title: Fallback Family
        family:
          anyOf:
            - type: string
            - type: 'null'
          title: Family
        size_px:
          anyOf:
            - type: number
            - type: 'null'
          title: Size Px
        weight:
          anyOf:
            - type: integer
            - type: 'null'
          title: Weight
      required:
        - family
        - fallback_family
        - weight
        - case
        - size_px
      title: TypographyBinding
      type: object
  securitySchemes:
    HTTPBearer:
      description: API key for public endpoints; Clerk session for account endpoints.
      scheme: bearer
      type: http

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.