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

# List invoices inside a batch



## OpenAPI

````yaml /openapi.json get /api/v1/invoice_batches/{invoice_batch_id}/batch_invoices
openapi: 3.1.0
info:
  title: YoFacturo API v1
  version: 1.0.0
  summary: API for authentication and invoice batch ingestion and status
  description: |
    API v1 operational endpoints.

    Authentication flow:
    1. Exchange organization api_key for a session token.
    2. Use Authorization: Bearer <session_token> for protected endpoints.
servers:
  - url: https://app.yofacturo.es
security: []
tags:
  - name: Auth
  - name: Invoice Batches
  - name: Batch Invoices
paths:
  /api/v1/invoice_batches/{invoice_batch_id}/batch_invoices:
    get:
      tags:
        - Batch Invoices
      summary: List invoices inside a batch
      operationId: listBatchInvoices
      parameters:
        - name: invoice_batch_id
          in: path
          required: true
          schema:
            type: integer
            minimum: 1
        - $ref: '#/components/parameters/Page'
        - $ref: '#/components/parameters/PerPage'
      responses:
        '200':
          description: Paginated list of batch invoices
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BatchInvoiceListResponse'
        '401':
          description: Missing, invalid, or expired bearer token
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - bearerAuth: []
components:
  parameters:
    Page:
      name: page
      in: query
      required: false
      schema:
        type: integer
        minimum: 1
        default: 1
    PerPage:
      name: per_page
      in: query
      required: false
      schema:
        type: integer
        minimum: 1
        maximum: 100
        default: 25
  schemas:
    BatchInvoiceListResponse:
      type: object
      additionalProperties: false
      required:
        - data
        - meta
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/BatchInvoice'
        meta:
          $ref: '#/components/schemas/PaginationMeta'
    ErrorResponse:
      type: object
      additionalProperties: false
      required:
        - error
      properties:
        error:
          type: object
          additionalProperties: false
          required:
            - code
            - message
          properties:
            code:
              type: string
            message:
              type: string
    BatchInvoice:
      type: object
      additionalProperties: false
      required:
        - id
        - external_invoice_id
        - invoice_number
        - total_after_taxes
        - processing_status
        - processing_error
        - issued_invoice_id
        - verifactu_state
      properties:
        id:
          type: integer
        external_invoice_id:
          type: string
          nullable: true
        invoice_number:
          type: string
          nullable: true
        total_after_taxes:
          type: string
          nullable: true
        processing_status:
          type: string
          description: >-
            pending (just received), processing (synchronizing with external
            systems), success (correctly issued), failed (`processing_error`
            will be informed).
        processing_error:
          type: string
          nullable: true
        issued_invoice_id:
          type: integer
          nullable: true
        verifactu_state:
          type: string
          nullable: true
          enum:
            - remission
            - to_fix
            - verifactu_synced
            - pre_verifactu_issued
          description: >
            Verifactu fiscal synchronization state of the associated issued
            invoice. Indicates whether the invoice has been synchronized with
            Spain's Verifactu system.

            - `null`: Invoice has not been converted to an issued invoice yet
            (no `issued_invoice_id`)

            - `remission`: Invoice created but not yet synchronized with
            Verifactu

            - `to_fix`: Invoice needs correction before Verifactu sync can
            succeed

            - `verifactu_synced`: Invoice fully synchronized with fiscal
            authorities

            - `pre_verifactu_issued`: Invoice was issued before Verifactu became
            mandatory, so it is correct as is now.
    PaginationMeta:
      type: object
      additionalProperties: false
      required:
        - current_page
        - total_pages
        - total_count
        - per_page
      properties:
        current_page:
          type: integer
        total_pages:
          type: integer
        total_count:
          type: integer
        per_page:
          type: integer
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: token

````