Skip to content
Navigation

Get a statement

GET
https://api.nicer.travel/commerce/statements/{statementId}

One statement with a page of its lines (100 by default, at most 500), each with the booking it was earned on, its adjustments and notes, its payout, a link to its PDF signed for minutes, and the actions the caller may run. An advisor reads only their own; another company's statement answers 404. Every staff read is audited.

Authorization

  • bearerAuth
    HTTP Bearer (JWT)
    required

    Authorization: Bearer <token>

Path parameters

  • statementId
    string
    required

Query parameters

  • cursor
    optional
    string
    maxLength: 2048 · minLength: 1
  • limit
    optional
    integer
    maximum: 500 · minimum: 1

Header parameters

  • x-nicer-company
    string
    required

    Company context. Authentication and tenant membership are validated by the API.

Returns

200

OK

JSON
  • adjustmentsMinor
    integer
    required
    maximum: 9007199254740991 · minimum: -9007199254740991
  • approvedAt
    required

    Any of the following:

    • string
    • null
  • approvedByUserId
    required

    Any of the following:

    • string
    • null
  • closedAt
    required

    Any of the following:

    • string
    • null
  • companyName
    string
    required
    minLength: 1
  • createdAt
    string
    required
    format: date-time · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
  • currency
    string
    required
    pattern: ^[A-Z]{3}$
  • cycleOn
    string
    required
    format: date · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$
  • earningsMinor
    integer
    required
    maximum: 9007199254740991 · minimum: -9007199254740991
  • lineCount
    integer
    required
    maximum: 9007199254740991 · minimum: 0
  • number
    string
    required
    minLength: 1
  • paidAt
    required

    Any of the following:

    • string
    • null
  • payeeId
    string
    required
    minLength: 1
  • payeeKind
    ADVISOR
    or
    COMPANY
    required
  • periodEnd
    string
    required
    format: date · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$
  • periodStart
    string
    required
    format: date · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$
  • statementId
    string
    required
    minLength: 1
  • status
    OPEN
    or
    PENDING_APPROVAL
    or
    APPROVED
    or
    PAID
    or
    VOID
    required
  • totalMinor
    integer
    required
    maximum: 9007199254740991 · minimum: -9007199254740991
  • updatedAt
    string
    required
    format: date-time · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
  • version
    integer
    required
    maximum: 9007199254740991
  • voidReason
    required

    Any of the following:

    • string
    • null
  • adjustments
    array of
    object
    required
    • adjustmentId
      string
      required
      minLength: 1
    • amountMinor
      integer
      required
      maximum: 9007199254740991 · minimum: -9007199254740991
    • carriedFromStatementId
      required

      Any of the following:

      • string
      • null
    • createdAt
      string
      required
      format: date-time · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
    • createdByUserId
      required

      Any of the following:

      • string
      • null
    • description
      string
      required
      maxLength: 500 · minLength: 1
    • kind
      CREDIT
      or
      DEBIT
      required
    • quantity
      integer
      required
      maximum: 9007199254740991
    • unitAmountMinor
      integer
      required
      maximum: 9007199254740991
  • allowedActions
    array of
    string
    ·
    one of 10 values
    required
    Allowed values: ADD_ADJUSTMENT, REMOVE_ADJUSTMENT, ADD_NOTE, CLOSE, APPROVE, REOPEN, VOID, RECOMPUTE, MARK_PAID, ADD_ATTACHMENT
  • attachments
    array of
    object
    required
    • attachmentId
      string
      required
      minLength: 1
    • contentType
      string
      required
      minLength: 1
    • createdAt
      string
      required
      format: date-time · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
    • downloadUrl
      string
      required
      format: uri
    • fileName
      string
      required
      minLength: 1
    • label
      required

      Any of the following:

      • string
      • null
    • sizeBytes
      integer
      required
      maximum: 9007199254740991
    • uploadedByUserId
      string
      required
      minLength: 1
  • lines
    array of
    object
    required
    • amountMinor
      integer
      required
      maximum: 9007199254740991 · minimum: -9007199254740991
    • bucket
      PENDING
      or
      AVAILABLE
      required
    • clientName
      required

      Any of the following:

      • string
      • null
    • commissionItemId
      required

      Any of the following:

      • string
      • null
    • confirmationNumber
      required

      Any of the following:

      • string
      • null
    • earningId
      string
      required
      minLength: 1
    • earningKind
      string
      required
      minLength: 1
    • entryType
      EARNING
      or
      REVERSAL
      or
      CLAWBACK
      required
    • orderId
      required

      Any of the following:

      • string
      • null
    • payableOn
      string
      required
      format: date · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$
    • supplierName
      required

      Any of the following:

      • string
      • null
    • travelEnd
      required

      Any of the following:

      • string
      • null
  • nextCursor
    required

    Any of the following:

    • string
    • null
  • notes
    array of
    object
    required
    • authorUserId
      string
      required
      minLength: 1
    • bodyMarkdown
      string
      required
      minLength: 1
    • createdAt
      string
      required
      format: date-time · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
    • noteId
      string
      required
      minLength: 1
  • payout
    required

    Any of the following:

    • Payout
      • amountMinor
        integer
        required
        maximum: 9007199254740991
      • attempts
        integer
        required
        maximum: 9007199254740991 · minimum: 0
      • companyName
        string
        required
        minLength: 1
      • createdAt
        string
        required
        format: date-time · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
      • currency
        string
        required
        pattern: ^[A-Z]{3}$
      • failureReason
        required

        Any of the following:

        • string
        • null
      • method
        STRIPE_CONNECT
        or
        CHECK
        or
        MANUAL
        required
      • paidAt
        required

        Any of the following:

        • string
        • null
      • payeeId
        string
        required
        minLength: 1
      • payeeKind
        ADVISOR
        or
        COMPANY
        required
      • payoutId
        string
        required
        minLength: 1
      • payoutRunId
        string
        required
        minLength: 1
      • processorReference
        required

        Any of the following:

        • string
        • null
      • statementId
        string
        required
        minLength: 1
      • statementNumber
        string
        required
        minLength: 1
      • status
        PENDING
        or
        PAID
        or
        FAILED
        or
        CANCELLED
        required
      • updatedAt
        string
        required
        format: date-time · pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
    • null
  • pdfUrl
    required

    Any of the following:

    • string
    • null

400

Request failed. errorCode is stable; errorMessage is for humans.
JSON
  • errorCode
    string
    required
  • errorMessage
    string
    required

401

Request failed. errorCode is stable; errorMessage is for humans.
JSON
  • errorCode
    string
    required
  • errorMessage
    string
    required

403

Request failed. errorCode is stable; errorMessage is for humans.
JSON
  • errorCode
    string
    required
  • errorMessage
    string
    required

Type to search…

↑↓ navigate↵ selectEsc close