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

# Get ClearLoop Settlement by ID



## OpenAPI

````yaml /copper-open-api-public.json get /clearloop/settlements/{settlementId}
openapi: 3.1.0
info:
  description: >-
    Copper API is based on the REST API interface provided for data exchange
    between a client and a server with the use of HTTPS requests and responses.

    By default, the request should include a Content-Type header set as
    application/json. Some requests require different header fields, as well as
    other Content-Type values. In this case, a proper header will be stated in
    an example.

    When interacting with the API, please note that all numerical values, such
    as order amounts or timestamps, should be transmitted as strings. This
    ensures consistent data representation and prevents potential issues with
    floating-point precision
  title: Copper Platform API
  version: latest
servers:
  - description: platform.copper.co
    url: https://api.copper.co/platform
  - description: demo.copper.co
    url: https://api.stage.copper.co/platform
  - description: testnet.copper.co
    url: https://api.testnet.copper.co/platform
security: []
tags:
  - name: reports
  - name: deposit-targets
  - name: lending
  - name: portfolios
  - name: wallets
  - name: network
  - name: stake
  - name: blockchain
  - name: organizations
  - name: files
  - name: orders
  - name: address-book
  - name: clearloop
  - name: currencies
paths:
  /clearloop/settlements/{settlementId}:
    get:
      tags:
        - clearloop
      summary: Get ClearLoop Settlement by ID
      parameters:
        - in: path
          name: settlementId
          required: true
          schema:
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ClearLoopSettlementV2'
          description: OK
        '400':
          content:
            application/json:
              schema:
                properties:
                  error:
                    description: The machine-readable error code
                    examples:
                      - bad-request
                    type: string
                  message:
                    description: >-
                      A human-readable message providing more details about the
                      error
                    type: string
                type: object
          description: Bad Request
        '403':
          content:
            application/json:
              schema:
                properties:
                  error:
                    description: The machine-readable error code
                    examples:
                      - forbidden
                    type: string
                  message:
                    description: >-
                      A human-readable message providing more details about the
                      error
                    type: string
                type: object
          description: Forbidden
        '409':
          content:
            application/json:
              schema:
                properties:
                  error:
                    description: The machine-readable error code
                    examples:
                      - conflict
                    type: string
                  message:
                    description: >-
                      A human-readable message providing more details about the
                      error
                    type: string
                type: object
          description: Conflict
components:
  schemas:
    ClearLoopSettlementV2:
      properties:
        completedAt:
          description: >-
            Unix timestamp (in milliseconds) of the date and time when the
            settlement was fully completed
          type: string
        createdAt:
          description: >-
            Unix timestamp (in milliseconds) of the date and time when the
            settlement started
          type: string
        custodian:
          description: Custodian associated to settlement
          type: string
        cycleEndTimestamp:
          description: >-
            Unix timestamp (in milliseconds) of the date and time when the
            settlement cycle has ended
          type: string
        cycleStartTimestamp:
          description: >-
            Unix timestamp (in milliseconds) of the date and time when the
            settlement cycle has started
          type: string
        deadline:
          description: Unix timestamp (in milliseconds) of the settlement deadline
          type: string
        exchange:
          description: Exchange name
          type: string
        exchangeId:
          description: Exchange identifier
          type: string
        failureReason:
          type: string
        settlementDetails:
          description: >-
            Array of settlement detail records for each client account linked to
            a given settlement ID
          items:
            $ref: '#/components/schemas/ClearLoopSettlementDetails'
          type: array
        settlementId:
          description: Unique Copper settlement identifier
          type: string
        settlementStatus:
          $ref: '#/components/schemas/ClearLoopSettlementStatus'
          description: >-
            Status describing the settlement. [See
            details](/enums/ClearLoopSettlementStatus)
        settlementSubStatus:
          $ref: '#/components/schemas/ClearLoopSettlementSubStatus'
          description: >-
            Sub-status providing additional context to the status of the
            settlement
      required:
        - settlementId
        - settlementStatus
        - settlementSubStatus
        - cycleStartTimestamp
        - exchange
        - exchangeId
      type: object
    ClearLoopSettlementDetails:
      properties:
        clientAccountId:
          description: Unique exchange account identifier
          type: string
        exchangeSettlementId:
          description: Unique identifier assigned by the exchange for the settlement
          type: string
        exclusionDetails:
          $ref: '#/components/schemas/ClearLoopSettlementExclusionDetails'
          description: Exclusion details
          type: object
        organizationId:
          description: >-
            Unique identifier for the client organisation tied to a settlement
            record
          type: string
        pnlAttributionEndTimestamp:
          description: >-
            Unix timestamp (in milliseconds) of the end of the period used to
            attribute profit and loss (PnL) for the settlement
          type: string
        pnlAttributionStartTimestamp:
          description: >-
            Unix timestamp (in milliseconds) of the start of the period used to
            attribute profit and loss (PnL) for the settlement
          type: string
        portfolioId:
          description: Unique Copper account identifier
          type: string
        settlementInstructions:
          description: >-
            Array of settlement instruction records, grouped by settlement
            currency and client account, linked to a given settlement ID
          items:
            $ref: '#/components/schemas/ClearLoopSettlementInstruction'
          type: array
        status:
          $ref: '#/components/schemas/ClearLoopSettlementStatus'
          description: >-
            Client settlement status. [See
            details](/enums/ClearLoopSettlementStatus)
      required:
        - portfolioId
        - clientAccountId
        - exchangeSettlementId
        - settlementInstructions
      type: object
    ClearLoopSettlementStatus:
      enum:
        - new
        - pending-exchange-confirmation
        - in-progress
        - completed
        - failed
        - cancelled
        - partially-completed
        - ignored
        - on-chain-orders-in-progress
        - excluded
      type: string
    ClearLoopSettlementSubStatus:
      enum: []
      type: string
    ClearLoopSettlementExclusionDetails:
      properties:
        exclusionReason:
          description: Settlement exclusion reason
          type: string
        exclusionSettlementId:
          description: >-
            Exclusion settlement identifier, if the client has been excluded
            from a settlement cycle.
          type: string
      required:
        - exclusionReason
      type: object
    ClearLoopSettlementInstruction:
      properties:
        balance:
          description: >-
            Client's delegated balance in Copper, fetched at the time of
            settlement
          type: string
        currency:
          description: Settlement currency
          type: string
        orderId:
          description: >-
            Identifier of the order linked to the settlement for the specified
            client account and currency
          type: string
        orderStatus:
          $ref: '#/components/schemas/OrderStatus'
          description: >-
            Status of the order associated with the settlement for the given
            client account and currency. [See details](/enums/OrderStatus)
        settlementAmount:
          description: >-
            Aggregate amount to be settled across main and subaccounts within
            the exchange
          type: string
        settlementAmountUSD:
          description: USD equivalent of the `settlementAmount`
          type: string
        settlementInstructionId:
          description: >-
            Unique identifier for the settlement instruction (per client account
            and currency per cycle)
          type: string
        status:
          $ref: '#/components/schemas/ClearLoopSettlementStatus'
          description: >-
            Status of the settlement at client account and currency level. [See
            details](/enums/ClearLoopSettlementStatus)
      required:
        - currency
        - settlementAmount
      type: object
    OrderStatus:
      enum:
        - new
        - waiting-funds
        - reserving
        - reserved
        - queued
        - validating-funds
        - working
        - waiting-approve
        - co-sign-require
        - approved
        - processing
        - executed
        - canceled
        - rejecting
        - rejected
        - declining
        - declined
        - suspending
        - suspended
        - blocked
        - action-required
        - accepting
        - accepted
        - require-initializer-approve
        - waiting-counterparty-approve
        - require-counterparty-approve
        - ready-for-settlement
        - settled
        - part-signed-tx-added
        - full-signed-tx-added
        - rejected-part-signed-tx-added
        - rejected-full-signed-tx-added
        - accepted-part-signed-tx-added
        - accepted-full-signed-tx-added
        - awaiting-settlement
        - master-password-required
        - manual-resolving
        - error
        - pending-atomic-settlement-confirmation
        - atomic-settlement-reservation-completed
        - require-finalize
        - waiting-accept-deposit
        - waiting-reject-deposit
      type: string

````