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

# Get factura by client and period

> Operacion: Get factura by client and period.



## OpenAPI

````yaml /generated/specs/finance.json get /api/v1/factura/client/{clientId}
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/factura/client/{clientId}:
    get:
      tags:
        - Billing - Facturas
      summary: Get factura by client and period
      description: 'Operacion: Get factura by client and period.'
      operationId: FacturaController_getFacturaByClientAndPeriod
      parameters:
        - name: clientId
          required: true
          in: path
          schema:
            type: string
        - name: year
          required: true
          in: query
          schema:
            example: 2024
            type: number
        - name: month
          required: true
          in: query
          schema:
            type: number
            example: 1
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FacturaResponseDto'
        '404':
          description: Factura not found
      security:
        - bearerAuth: []
components:
  schemas:
    FacturaResponseDto:
      type: object
      properties:
        id:
          type: number
        client_id:
          type: string
        fecha:
          format: date-time
          type: string
        uf_value:
          type: number
        total_clp:
          type: number
        total_descuento_clp:
          type: number
        created_at:
          format: date-time
          type: string
        detalleSubscripciones:
          type: array
          items:
            $ref: '#/components/schemas/DetalleFacturaSubscripcionesResponseDto'
        detalleVisitas:
          type: array
          items:
            $ref: '#/components/schemas/DetalleFacturaVisitasResponseDto'
        detalleVentas:
          type: array
          items:
            $ref: '#/components/schemas/DetalleFacturaVentasResponseDto'
        descuentosAplicados:
          type: array
          items:
            $ref: '#/components/schemas/DescuentoAplicadoResponseDto'
      required:
        - id
        - client_id
        - fecha
        - uf_value
        - created_at
    DetalleFacturaSubscripcionesResponseDto:
      type: object
      properties:
        id:
          type: number
        subscription_detail_id:
          type: string
        equipo:
          type: string
        patente:
          type: string
        plan_comercial:
          type: string
        estado:
          type: string
        precio_uf:
          type: number
        precio_clp:
          type: number
        dias:
          type: number
        child_client_name:
          type: string
      required:
        - id
    DetalleFacturaVisitasResponseDto:
      type: object
      properties:
        id:
          type: number
        visit_detail_id:
          type: string
        tipo_visita:
          type: string
        patente:
          type: string
        ciudad:
          type: string
        direccion:
          type: string
        fecha_visita:
          format: date-time
          type: string
        km_recorridos:
          type: number
        moneda:
          type: string
        costo_visita:
          type: number
        costo_por_km:
          type: number
        carga_costo_km:
          type: boolean
        carga_costo_cliente:
          type: boolean
        child_client_name:
          type: string
      required:
        - id
    DetalleFacturaVentasResponseDto:
      type: object
      properties:
        id:
          type: number
        subscription_cancellation_id:
          type: number
        equipo:
          type: string
        patente:
          type: string
        plan_comercial:
          type: string
        fecha_venta:
          format: date-time
          type: string
        motivo_venta:
          type: string
        moneda:
          type: string
        monto_venta:
          type: number
        child_client_name:
          type: string
      required:
        - id
    DescuentoAplicadoResponseDto:
      type: object
      properties:
        id:
          type: string
        motivo:
          type: string
        tipo_descuento:
          type: string
        valor:
          type: number
        base_calculo_clp:
          type: number
        monto_descuento_clp:
          type: number
        monto_descuento_uf:
          type: number
        subscription_name:
          type: string
      required:
        - id
        - base_calculo_clp
        - monto_descuento_clp
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Bearer token authentication

````