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

# List Credit Ledger Entries

> Lists credit ledger entries.



## OpenAPI

````yaml /api-reference/customer/openapi.json get /api/v1/customer/credit-grants/{creditGrantId}/ledger-entries
openapi: 3.0.0
info:
  title: OABUS Customer API
  description: OABUS API
  version: '1.0'
  contact: {}
servers: []
security: []
tags: []
paths:
  /api/v1/customer/credit-grants/{creditGrantId}/ledger-entries:
    get:
      tags:
        - CreditGrant
      summary: List Credit Ledger Entries
      description: Lists credit ledger entries.
      operationId: listCreditLedgerEntries
      parameters:
        - name: creditGrantId
          required: true
          in: path
          schema:
            type: string
            format: uuid
        - name: limit
          required: false
          in: query
          schema:
            default: 10
            description: Items per page
            example: 10
            type: number
        - name: page
          required: false
          in: query
          schema:
            default: 1
            description: Page number
            example: 1
            type: number
        - name: createdAt
          required: false
          in: query
          schema:
            description: 'Available operators: >, >=, <, <=, =.'
            example: '>=2024-01-01;<=2024-12-31'
            type: string
        - name: sortBy
          required: false
          in: query
          schema:
            default: createdAt
            description: Field to sort by
            example: createdAt
            type: string
            enum:
              - createdAt
              - amount
        - name: sortOrder
          required: false
          in: query
          schema:
            default: desc
            description: Sort order
            example: desc
            type: string
            enum:
              - asc
              - desc
        - name: fields
          required: false
          in: query
          description: >-
            Comma-separated list of fields to include in the response. Supports
            dot notation for nested projection (e.g.
            `id,name,user.email,trips.route.id`). Unknown fields are silently
            dropped.
          schema:
            type: string
      responses:
        '200':
          $ref: '#/components/responses/ListCreditLedgerEntries200Response'
        '400':
          $ref: '#/components/responses/ListCreditLedgerEntries400Response'
        '401':
          $ref: '#/components/responses/ListCreditLedgerEntries401Response'
        '500':
          $ref: '#/components/responses/ListCreditLedgerEntries500Response'
      security:
        - bearer: []
components:
  responses:
    ListCreditLedgerEntries200Response:
      content:
        application/json:
          schema:
            type: object
            properties:
              data:
                type: array
                items:
                  type: object
                  properties:
                    creditLedgerEntryId:
                      type: string
                      format: uuid
                    creditGrantId:
                      type: string
                      format: uuid
                    organizationId:
                      type: string
                      format: uuid
                    companyId:
                      type: string
                      format: uuid
                    customerId:
                      type: string
                      format: uuid
                    cooperativeId:
                      nullable: true
                      type: string
                      format: uuid
                    transportOperatorId:
                      nullable: true
                      type: string
                      format: uuid
                    checkoutId:
                      nullable: true
                      type: string
                      format: uuid
                    orderId:
                      nullable: true
                      type: string
                      format: uuid
                    ticketId:
                      nullable: true
                      type: string
                      format: uuid
                    type:
                      type: string
                      enum:
                        - GRANT
                        - RESERVE
                        - CAPTURE
                        - RELEASE
                        - REFUND
                        - EXPIRE
                        - ADJUSTMENT
                    amount:
                      type: integer
                    availableAfter:
                      type: integer
                    description:
                      nullable: true
                      type: string
                    referenceType:
                      nullable: true
                      type: string
                    referenceId:
                      nullable: true
                      type: string
                    idempotencyKey:
                      nullable: true
                      type: string
                    createdBy:
                      nullable: true
                      type: string
                      format: uuid
                    createdAt:
                      type: string
                      format: date-time
                  required:
                    - creditLedgerEntryId
                    - creditGrantId
                    - organizationId
                    - companyId
                    - customerId
                    - type
                    - amount
                    - availableAfter
                    - createdAt
                  additionalProperties: false
                  description: Credit ledger entry
              meta:
                type: object
                properties:
                  limit:
                    type: number
                    description: Items per page
                    example: 10
                  page:
                    type: number
                    description: Current page
                    example: 1
                  totalItems:
                    type: number
                    description: Total items
                    example: 100
                  totalPages:
                    type: number
                    description: Total pages
                    example: 10
                required:
                  - limit
                  - page
                  - totalItems
                  - totalPages
                additionalProperties: false
            required:
              - data
              - meta
            additionalProperties: false
            description: List credit ledger entries
      description: OK
    ListCreditLedgerEntries400Response:
      content:
        application/json:
          example:
            errors:
              - message: required
                path: name
            message: Bad Request Error
            statusCode: 400
          schema:
            properties:
              message:
                type: string
              statusCode:
                enum:
                  - 400
                type: number
              errors:
                items:
                  properties:
                    message:
                      type: string
                    path:
                      type: string
                  required:
                    - message
                    - path
                  type: object
                type: array
            required:
              - message
              - statusCode
            type: object
      description: Bad Request Error
    ListCreditLedgerEntries401Response:
      content:
        application/json:
          example:
            message: Missing or invalid access token
            statusCode: 401
          schema:
            properties:
              message:
                type: string
              statusCode:
                enum:
                  - 401
                type: number
            required:
              - message
              - statusCode
            type: object
      description: Unauthorized
    ListCreditLedgerEntries500Response:
      content:
        application/json:
          example:
            message: Internal Server Error
            statusCode: 500
          schema:
            properties:
              message:
                type: string
              statusCode:
                enum:
                  - 500
                type: number
            required:
              - message
              - statusCode
            type: object
      description: Internal Server Error
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: JWT
      type: http

````