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

# Listar facturas paginadas con filtros

> Operacion: Listar facturas paginadas con filtros.



## OpenAPI

````yaml /generated/specs/finance.json get /api/v1/billing/invoices
openapi: 3.0.0
info:
  title: Raul API - Finanzas
  description: >-
    Facturas, boletas, ejecuciones de billing, cuentas por pagar y medios de
    pago.
  version: 2.0.0
  contact: {}
servers:
  - url: https://api.raul.ugps.io
    description: Production
security: []
tags: []
paths:
  /api/v1/billing/invoices:
    get:
      tags:
        - Invoices
      summary: Listar facturas paginadas con filtros
      description: 'Operacion: Listar facturas paginadas con filtros.'
      operationId: InvoiceQueryController_list
      parameters:
        - name: payment_status
          required: false
          in: query
          description: >-
            Pago de facturas emitidas con total mayor que cero. Excluye
            borradores, pendientes de emisión, rechazadas, anuladas y notas de
            crédito; se intersecta con el estado comercial seleccionado.
          schema:
            type: string
            enum:
              - paid
              - partial
              - unpaid
        - name: dte_type
          required: false
          in: query
          description: >-
            Tipo guardado en la factura. UNDEFINED selecciona NULL: la emisión
            resuelve la preferencia del receptor legal o infiere el tipo por
            RUT.
          schema:
            type: string
            enum:
              - FACTURA
              - BOLETA
              - UNDEFINED
        - name: type
          required: false
          in: query
          description: Tipo de factura
          schema:
            type: string
            enum:
              - MANUAL
              - MENSUAL
        - name: invoice_type
          required: false
          in: query
          description: Tipo de facturación (regular, consolidada o filial)
          schema:
            type: string
            enum:
              - regular
              - consolidated
              - filial
        - name: client_id
          required: false
          in: query
          description: UUID del cliente
          schema:
            type: string
        - name: search
          required: false
          in: query
          description: Búsqueda por nombre, RUT, email o concepto
          schema:
            type: string
        - name: page
          required: false
          in: query
          description: Número de página
          schema:
            default: 1
            type: number
        - name: limit
          required: false
          in: query
          description: Límite por página
          schema:
            default: 20
            type: number
        - name: status
          required: false
          in: query
          description: >-
            Estado(s) de la factura (eje comercial). Acepta un valor o lista
            separada por comas.
          schema:
            type: array
            items:
              type: string
              enum:
                - DRAFT
                - PUBLISHED
                - DTE_SENT
                - SII_ACCEPTED
                - SII_REJECTED
                - EMAIL_SENDING
                - EMAIL_SENT
                - EMAIL_FAILED
                - PAID
                - OVERDUE
                - CREDIT_NOTE
                - VOIDED
        - name: sii_status
          required: false
          in: query
          description: >-
            Estado(s) del DTE ante el SII (local_status del XML), separados por
            comas. NOT_EMITTED filtra facturas sin DTE vigente.
          schema:
            type: array
            items:
              type: string
              enum:
                - NOT_EMITTED
                - DRAFT
                - LOCAL_VALIDATED
                - ODOO_DRAFT_CREATED
                - ODOO_POSTED
                - SII_PENDING
                - SII_UPLOAD_UNCERTAIN
                - SII_ACCEPTED
                - SII_REJECTED
                - SII_ERROR
                - ODOO_ERROR
        - name: periodo
          required: false
          in: query
          description: Período (YYYY-MM)
          schema:
            type: string
        - name: overdue_only
          required: false
          in: query
          description: Solo facturas vencidas
          schema:
            type: boolean
        - name: requires_oc
          required: false
          in: query
          description: >-
            Filtrar facturas de clientes que requieren OC (orden de compra) y no
            tienen OC cargada
          schema:
            type: boolean
        - name: sort_by
          required: false
          in: query
          description: Campo por el que ordenar
          schema:
            default: total_amount
            type: string
            enum:
              - created_at
              - issue_date
              - total_amount
              - due_date
        - name: order
          required: false
          in: query
          description: Dirección de ordenamiento
          schema:
            default: desc
            type: string
            enum:
              - asc
              - desc
      responses:
        '200':
          description: Lista paginada de facturas
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaginatedInvoiceResponseDto'
      security:
        - bearerAuth: []
components:
  schemas:
    PaginatedInvoiceResponseDto:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/InvoiceResponseDto'
        total:
          type: number
        page:
          type: number
        limit:
          type: number
        total_pages:
          type: number
      required:
        - data
        - total
        - page
        - limit
        - total_pages
    InvoiceResponseDto:
      type: object
      properties:
        id:
          type: string
        type:
          type: string
        status:
          type: string
        client_id:
          type: object
        receiver_rut:
          type: object
        receiver_name:
          type: string
        receiver_email:
          type: object
        receiver_address:
          type: object
        receiver_ciudad:
          type: object
        receiver_comuna:
          type: object
        receiver_giro:
          type: object
        issue_date:
          type: string
          format: date-time
        due_date:
          type: string
          format: date-time
        subtotal:
          type: number
        discount_total:
          type: number
        net_amount:
          type: number
        tax_rate:
          type: number
        tax_amount:
          type: number
        total_amount:
          type: number
        tax_amount_override:
          type: object
        total_amount_override:
          type: object
        amount_paid:
          type: number
        client_credit_balance:
          type: number
          description: >-
            Saldo a favor disponible del cliente desde sobrepagos de otras
            facturas
        uf_value_at_creation:
          type: object
        folio_prefix:
          type: object
        folio_number:
          type: object
        internal_notes:
          type: object
        public_notes:
          type: object
        concept:
          type: object
        periodo:
          type: object
        payment_terms_days:
          type: number
        credit_note_for_id:
          type: object
        credit_note_reason:
          type: object
        factura_id:
          type: object
        invoice_type:
          type: string
        parent_client_id:
          type: object
        billing_client_id:
          type: object
        oc_number:
          type: object
        hes_number:
          type: object
        requires_oc:
          type: boolean
        requires_hes:
          type: boolean
        detail_xlsx_url:
          type: object
        last_dte_error:
          type: object
        dte_retry_count:
          type: number
        dte_local_status:
          type: object
          description: local_status del DTE más reciente (estado del XML ante el SII)
        sii_status_detail:
          type: object
          description: Detalle libre devuelto por el SII para el DTE más reciente
        created_by:
          type: object
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
        deleted_at:
          type: object
      required:
        - id
        - type
        - status
        - receiver_name
        - issue_date
        - due_date
        - subtotal
        - discount_total
        - net_amount
        - tax_rate
        - tax_amount
        - total_amount
        - amount_paid
        - client_credit_balance
        - payment_terms_days
        - invoice_type
        - created_at
        - updated_at
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Token de sesión Better Auth para rutas de backoffice; las rutas de
        portal usan su token propio.

````

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