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

# Batchinformatie

> Haalt de status- en voortgangsinformatie van een batch op. Om de inhoud van een batch op te halen, zie [hier](/api-reference/batches/items)

<Tip>
  **Aangepaste gegevens toevoegen:** Gebruik de `metadata` parameter om sleutel-waardeparen met je batch op te slaan. Zie [Metadata](/api-reference/common/metadata) voor details.
</Tip>


## OpenAPI

````yaml nl/openapi/batches.json GET /v1/batches/{batch_id}
openapi: 3.0.3
info:
  title: Batches API
  version: 1.0.0
servers:
  - url: https://api.olostep.com
security: []
paths:
  /v1/batches/{batch_id}:
    get:
      summary: Batchinformatie ophalen
      description: >-
        Haalt informatie op over een specifieke batch met behulp van zijn
        `batch_id`.
      parameters:
        - name: batch_id
          in: path
          required: true
          schema:
            type: string
          description: De ID van de batch waarvoor je informatie wilt ophalen.
      responses:
        '200':
          description: Succesvolle respons met batchinformatie.
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    description: Batch ID
                  object:
                    type: string
                    description: Het soort object. "batch" voor dit endpoint.
                  status:
                    type: string
                    description: '`in_progress` of `completed`'
                  created:
                    type: number
                    description: Gemaakt epoch
                  total_urls:
                    type: number
                    description: Aantal URLs in de batch
                  completed_urls:
                    type: number
                    description: Aantal voltooide URLs
                  parser:
                    type: string
                  country:
                    type: string
                  metadata:
                    $ref: '#/components/schemas/Metadata'
                  webhook:
                    type: string
                    description: Webhook URL om een voltooiingsmelding te ontvangen
                  credits_consumed:
                    type: integer
                    nullable: true
                    description: >-
                      Aantal credits verbruikt door dit verzoek. Wordt ingevuld
                      nadat de uitvoering is voltooid. Credits zijn de bron van
                      waarheid voor facturering.
                  cost_usd:
                    type: number
                    nullable: true
                    description: >-
                      Geschatte kosten in USD voor dit verzoek. Wordt ingevuld
                      nadat de uitvoering is voltooid. Berekend op basis van
                      verbruikte credits en je tariefplan — 99% nauwkeurig, maar
                      credits_consumed is de gezaghebbende waarde.
        '401':
          description: >-
            Authenticatiegegevens ontbreken of zijn ongeldig. Zie
            [Unauthorized](/api-reference/errors/unauthorized) voor details.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                id: error_abc123
                object: error
                code: invalid_api_key
                type: https://docs.olostep.com/api-reference/errors/unauthorized
                status: 401
                title: Niet geautoriseerd
                detail: Your API key is invalid
                created: 1704067200
                metadata: {}
        '404':
          description: >-
            Batch niet gevonden voor de opgegeven ID. Zie [Not
            Found](/api-reference/errors/not_found) voor details.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                id: error_abc123
                object: error
                code: batch_not_found
                type: https://docs.olostep.com/api-reference/errors/not_found
                status: 404
                title: Niet Gevonden
                detail: Batch not found
                created: 1704067200
                metadata: {}
        '500':
          description: >-
            Interne serverfout. Zie [Internal
            Error](/api-reference/errors/internal_error) voor details.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                id: error_abc123
                object: error
                code: internal_server_error
                type: https://docs.olostep.com/api-reference/errors/internal_error
                status: 500
                title: Interne Serverfout
                detail: An unexpected error occurred
                created: 1704067200
                metadata: {}
      security:
        - Authorization: []
components:
  schemas:
    Metadata:
      type: object
      description: >-
        Set van sleutel-waarde paren voor het opslaan van aanvullende informatie
        over een object. Volgt Stripe's aanpak met validatieregels: max 50
        sleutels, sleutel max 40 tekens (geen vierkante haken), waarde max 500
        tekens, alle waarden opgeslagen als strings.
      additionalProperties:
        type: string
        maxLength: 500
        description: >-
          Metadata waarde (max 500 tekens). Nummers en booleans worden
          automatisch omgezet naar strings.
      maxProperties: 50
      example:
        order_id: '12345'
        customer_name: John Doe
        priority: high
        processed: 'true'
      x-validation-rules:
        max_keys: 50
        key_max_length: 40
        key_forbidden_chars:
          - '['
          - ']'
        value_max_length: 500
        value_types:
          - string
          - number (coerced)
          - boolean (coerced)
    Error:
      type: object
      description: RFC 7807 Probleem Details foutrespons
      properties:
        id:
          type: string
          description: Unieke foutidentificatie
        object:
          type: string
          enum:
            - error
          description: Altijd 'error'
        code:
          type: string
          description: Machine-leesbare foutcode
        type:
          type: string
          format: uri
          description: URI referentie die het probleemtype identificeert
        status:
          type: integer
          description: HTTP statuscode
        title:
          type: string
          description: Korte, mens-leesbare samenvatting
        detail:
          type: string
          description: Mens-leesbare uitleg
        created:
          type: integer
          description: Unix tijdstempel
        metadata:
          $ref: '#/components/schemas/Metadata'
        errors:
          type: array
          description: Optionele array van aanvullende foutdetails
          items: {}
      required:
        - id
        - object
        - code
        - type
        - status
        - title
        - detail
        - created
  securitySchemes:
    Authorization:
      type: http
      scheme: bearer
      description: >-
        Bearer authenticatie header in de vorm Bearer <token>, waar <token> jouw
        auth token is.

````