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

# Scrape Sitemap

> Fetches and parses sitemaps from the given URL and returns the extracted links



## OpenAPI

````yaml post /scrape_sitemap
openapi: 3.1.0
info:
  contact:
    email: support@blat.ai
    name: Blat Support
  description: >-
    A web scraping API that supports HTML and Markdown output with optional link
    extraction.
  title: Scrape API
  version: '1.0'
servers:
  - url: https://api.blat.ai
security: []
externalDocs:
  description: ''
  url: ''
paths:
  /scrape_sitemap:
    post:
      tags:
        - scraping
      summary: Scrape Sitemap
      description: >-
        Fetches and parses sitemaps from the given URL and returns the extracted
        links
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/api.SitemapRequest'
        description: Sitemap scraping request parameters
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/api.SitemapResponse'
          description: OK
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/utils.APIError'
          description: Invalid request parameters or URL
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/utils.APIError'
          description: Unauthorized - Make sure you have a valid API key
        '429':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/utils.APIError'
          description: Rate limit exceeded
        '500':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/utils.APIError'
          description: Unknown Error
        '504':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/utils.APIError'
          description: Request timeout
      security:
        - bearerauth: []
components:
  schemas:
    api.SitemapRequest:
      properties:
        url:
          description: The URL to scrape sitemap links from
          example: https://example.com
          type: string
      required:
        - url
    api.SitemapResponse:
      example:
        links:
          - links
          - links
      properties:
        links:
          items:
            type: string
          type: array
          uniqueItems: false
    utils.APIError:
      example:
        code: code
        details:
          key: ''
        message: message
      properties:
        code:
          type: string
        details:
          additionalProperties: {}
        message:
          type: string
  securitySchemes:
    bearerauth:
      bearerFormat: JWT
      scheme: bearer
      type: http

````