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

# List records

> Returns a paginated list of records, newest first. At least one of `data_stream_key`, `reconciliation_match_id`, `reconciliation_id`, `external_id`, `import_batch_id`, or `bulk_request_id` is required.

Pagination is cursor-based: pass each response's `next_cursor` back as `cursor` until `next_cursor` is null. The legacy `offset` parameter and its `has_more`/`offset`/`total_count` response shape have been removed.



## OpenAPI

````yaml /openapi.json get /records
openapi: 3.1.0
info:
  title: End Close API
  description: REST API is used to interact with the End Close platform.
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.endclose.com/v1
security:
  - ApiKeyAuth: []
paths:
  /records:
    get:
      summary: List records
      description: >-
        Returns a paginated list of records, newest first. At least one of
        `data_stream_key`, `reconciliation_match_id`, `reconciliation_id`,
        `external_id`, `import_batch_id`, or `bulk_request_id` is required.


        Pagination is cursor-based: pass each response's `next_cursor` back as
        `cursor` until `next_cursor` is null. The legacy `offset` parameter and
        its `has_more`/`offset`/`total_count` response shape have been removed.
      parameters:
        - in: query
          name: data_stream_key
          required: false
          schema:
            type: string
          description: Filter by data stream key
        - in: query
          name: reconciliation_match_id
          required: false
          schema:
            type: string
          description: Filter to records that belong to the given match
        - in: query
          name: reconciliation_id
          required: false
          schema:
            type: string
          description: Filter to records that have a status row in the given reconciliation
        - in: query
          name: external_id
          required: false
          schema:
            type: string
          description: Filter to records with this exact `external_id`
        - in: query
          name: import_batch_id
          required: false
          schema:
            type: integer
          description: Filter to records created by this import batch
        - in: query
          name: bulk_request_id
          required: false
          schema:
            type: integer
          description: Filter to records created by this bulk request
        - in: query
          name: created_after
          required: false
          schema:
            type: string
            format: date-time
          description: ISO8601 lower bound on `created_at`
        - in: query
          name: created_before
          required: false
          schema:
            type: string
            format: date-time
          description: ISO8601 upper bound on `created_at`
        - in: query
          name: source
          required: false
          schema:
            type: string
            enum:
              - csv_upload
              - nacha_upload
              - bulk_api
          description: Filter via the joined import batch's `source`
        - in: query
          name: status
          required: false
          schema:
            type: string
            enum:
              - matched
              - unmatched
          description: Filter by match status
        - in: query
          name: cursor
          required: false
          schema:
            type: string
          description: >-
            Opaque cursor from a previous response's `next_cursor`. Omit for the
            first page.
        - in: query
          name: limit
          required: false
          schema:
            type: integer
            minimum: 1
            maximum: 200
            default: 50
      responses:
        '200':
          description: Paginated list of records
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Record'
                  next_cursor:
                    type: string
                    nullable: true
                    description: Opaque cursor for the next page. Null when no more pages.
                  limit:
                    type: integer
        '422':
          description: >-
            No scoping filter provided, or invalid `status`, `created_after`, or
            `created_before`
components:
  schemas:
    Record:
      type: object
      required:
        - date
        - data_stream_key
        - amount
        - direction
      properties:
        id:
          type: integer
        amount:
          type: integer
          description: The monetary amount in cents (e.g., 1234 = $12.34)
        currency:
          type: string
          description: >-
            Three-letter ISO 4217 currency code (e.g. USD, EUR). **Optional on
            create — defaults to `USD` when omitted.** Case-insensitive on
            input; always returned uppercase.
          pattern: ^[A-Za-z]{3}$
          default: USD
        decimal_places:
          type: integer
          description: Number of decimal places for this currency (2 for USD)
          default: 2
        direction:
          type: string
          enum:
            - credit
            - debit
        description:
          type: string
        date:
          type: string
          format: date
        metadata:
          type: object
          additionalProperties: true
          default: {}
        external_id:
          type: string
        data_stream_key:
          type: string
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-KEY

````