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

# List recorded adjustments

> Use this endpoint to list the balancing entries recorded against a context, newest first. Use `matchGroupId` to narrow the list to one match group.



## OpenAPI

````yaml /es/openapi/v3-current/matcher.yaml get /v1/matching/contexts/{contextId}/adjustments
openapi: 3.1.0
info:
  title: Matcher APIs
  description: >-
    Complete API reference for the Matcher reconciliation engine, providing
    automated transaction matching between Midaz Ledger and external systems.
  version: 5.0.0
  license:
    name: Lerian Studio General License
servers:
  - url: https://matcher.sandbox.lerian.net
security: []
paths:
  /v1/matching/contexts/{contextId}/adjustments:
    get:
      tags:
        - Matching
      summary: List recorded adjustments
      description: >-
        Use this endpoint to list the balancing entries recorded against a
        context, newest first. Use `matchGroupId` to narrow the list to one
        match group.
      operationId: listAdjustments
      parameters:
        - description: Context ID whose adjustments to list
          in: path
          name: contextId
          required: true
          schema:
            description: Context ID whose adjustments to list
            format: uuid
            type: string
        - description: >-
            Narrow to the entries balancing one match group. Omit to read the
            whole context.
          explode: false
          in: query
          name: matchGroupId
          schema:
            description: >-
              Narrow to the entries balancing one match group. Omit to read the
              whole context.
            format: uuid
            type: string
        - description: Maximum number of records to return
          explode: false
          in: query
          name: limit
          schema:
            default: 20
            description: Maximum number of records to return
            format: int64
            maximum: 200
            minimum: 1
            type: integer
        - description: Opaque pagination cursor
          explode: false
          in: query
          name: cursor
          schema:
            description: Opaque pagination cursor
            type: string
        - description: Sort order
          explode: false
          in: query
          name: sort_order
          schema:
            description: Sort order
            enum:
              - asc
              - desc
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ListAdjustmentsResponse'
          description: OK
        default:
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Detail'
          description: Error
      security:
        - BearerAuth: []
components:
  schemas:
    ListAdjustmentsResponse:
      additionalProperties: false
      properties:
        hasMore:
          examples:
            - true
          type: boolean
        items:
          description: Page of recorded adjustments
          items:
            $ref: '#/components/schemas/AdjustmentResponse'
          maxItems: 200
          type:
            - array
            - 'null'
        limit:
          examples:
            - 20
          format: int64
          maximum: 200
          minimum: 1
          type: integer
        nextCursor:
          examples:
            - eyJpZCI6IjEyMyJ9
          type: string
        prevCursor:
          examples:
            - eyJpZCI6IjEyMiJ9
          type: string
      required:
        - items
        - limit
        - hasMore
      type: object
    Detail:
      additionalProperties: false
      properties:
        code:
          description: >-
            Stable, machine-readable domain error code scoped to the emitting
            service (format: <SERVICE>-NNNN).
          examples:
            - ERR-0001
          type: string
        detail:
          description: >-
            A human-readable explanation specific to this occurrence of the
            problem.
          examples:
            - Property foo is required but is missing.
          type: string
        errors:
          description: Optional list of individual error details
          items:
            $ref: '#/components/schemas/ErrorDetail'
          type:
            - array
            - 'null'
        instance:
          description: >-
            A URI reference that identifies the specific occurrence of the
            problem.
          examples:
            - https://example.com/error-log/abc123
          format: uri
          type: string
        status:
          description: HTTP status code
          examples:
            - 400
          format: int64
          type: integer
        title:
          description: >-
            A short, human-readable summary of the problem type. This value
            should not change between occurrences of the error.
          examples:
            - Bad Request
          type: string
        type:
          default: about:blank
          description: A URI reference to human-readable documentation for the error.
          examples:
            - https://example.com/errors/example
          format: uri
          type: string
        upstream:
          $ref: '#/components/schemas/Upstream'
          description: >-
            RFC 9457 extension member: the error a proxied third-party provider
            reported. Absent unless the emitting service explicitly surfaced
            one.
      type: object
    AdjustmentResponse:
      additionalProperties: false
      properties:
        amount:
          description: >-
            Adjustment amount as a decimal string in the adjustment currency's
            minor-unit precision
          examples:
            - '10.50'
          type: string
        contextId:
          description: Reconciliation context ID this adjustment belongs to
          examples:
            - 550e8400-e29b-41d4-a716-446655440000
          type: string
        createdAt:
          description: Creation timestamp (RFC 3339)
          examples:
            - '2025-01-15T10:30:00Z'
          type: string
        createdBy:
          description: Principal that created the adjustment
          examples:
            - user@example.com
          type: string
        currency:
          description: ISO 4217 currency code of the adjustment
          examples:
            - USD
          type: string
        description:
          description: Human-readable description of the adjustment
          examples:
            - Bank wire fee adjustment
          type: string
        direction:
          description: >-
            Direction of the entry: DEBIT explains a shortfall (moves the
            outstanding variance up, toward zero), CREDIT explains a surplus
            (moves it down)
          enum:
            - DEBIT
            - CREDIT
          examples:
            - DEBIT
          type: string
        id:
          description: Unique identifier for the adjustment
          examples:
            - 550e8400-e29b-41d4-a716-446655440000
          type: string
        matchGroupId:
          description: >-
            Match group the adjustment balances; set when the adjustment targets
            a group
          examples:
            - 550e8400-e29b-41d4-a716-446655440000
          type: string
        reason:
          description: Reason the adjustment was recorded
          examples:
            - Variance due to bank processing fee
          type: string
        transactionId:
          description: >-
            Single transaction the adjustment balances; set when the adjustment
            targets one transaction
          examples:
            - 550e8400-e29b-41d4-a716-446655440000
          type: string
        type:
          description: >-
            Adjustment type: BANK_FEE (bank charge), FX_DIFFERENCE (currency
            conversion variance), ROUNDING (minor-unit rounding), WRITE_OFF
            (uncollectible balance), or MISCELLANEOUS (other)
          enum:
            - BANK_FEE
            - FX_DIFFERENCE
            - ROUNDING
            - WRITE_OFF
            - MISCELLANEOUS
          examples:
            - BANK_FEE
          type: string
        updatedAt:
          description: Last update timestamp (RFC 3339)
          examples:
            - '2025-01-15T10:30:00Z'
          type: string
      required:
        - id
        - contextId
        - type
        - direction
        - amount
        - currency
        - description
        - reason
        - createdBy
        - createdAt
        - updatedAt
      type: object
    ErrorDetail:
      additionalProperties: false
      properties:
        location:
          description: >-
            Where the error occurred, e.g. 'body.items[3].tags' or
            'path.thing-id'
          type: string
        message:
          description: Error message text
          type: string
        value:
          description: The value at the given location
      type: object
    Upstream:
      additionalProperties: false
      properties:
        code:
          description: The upstream provider's own error code, verbatim.
          examples:
            - E4001
          type: string
        message:
          description: >-
            The upstream provider's own error message, verbatim (bounded, never
            its raw response body).
          examples:
            - account not found at provider
          type: string
      type: object
  securitySchemes:
    BearerAuth:
      bearerFormat: JWT
      description: 'Bearer token authentication (format: "Bearer {token}")'
      scheme: bearer
      type: http

````

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