Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Get all invoices item

Resource information

Response format(s)

JSON

Requires authentication?

Yes using API key

Request Header

Name

Value

X-Api-Key

S93Hrwp5w7J9kJRBfFgjAcexLTKvLHBY

Authorization

Bearer [access_token]

Accept-Account

a5c574c9-fe95-4983-f738-08db81308328

Parameters

Statuses

  • array[string]

  • query

Filter the items by statuses

  • Unpaid

  • Paid

  • Expired

  • Cancelled

  • Sending

  • Refunded

  • PaidFail

Types

  • array[string]

  • query

Filter the items by types

  • Trading

  • Retirement

  • DeListing

TransactionType

  • string

  • query

Filter the items by transaction type

  • AccountsPayable

  • AccountsReceivable

Search

  • string

  • query

Enter search data that can be used to search on each items. You can search by:

  • Invoice Number

CurrentPage

  • numeric

  • query

Request field for pagination. The Page that you wish to view

ItemPerPage

  • numeric

  • query

The total items that return in the response

OrderBy

  • string

  • query

Sorting field, Default sorting is get all items sort by CreatedDate Desc

Values:

  • CreatedDate

  • To Be Updated

IsDecending

  • boolean

  • query

Used in OrderBy

default: false

Returns

Returns all invoices item

Request

GET /rehash/v1/invoices

Request

?Statuses=Paid&Statuses=Sending&Types=Trading&TransactionType=AccountsPayable

Response

Success:

{
  "Data": {
    "CurrentPage": 1,
    "TotalPage": 2,
    "PageSize": 50,
    "TotalRow": 100,
    "Results": [
    {
      "InvoiceNumber": "INV-REAP-2023-07-13-00001",
      "BusinessAccountName": "YENLE REGISTRANT SG",
      "Quantity": 90,
      "Total": 1240.29,
      "IssuedDate": "2023-07-13T03:49:46.1656485",
      "DueDate": "2023-07-22T23:59:59.9999999",
      "PaidDate": null,
      "Type": "Trading",
      "TypeDescription": "Trading",
      "SubTotal": 1176.3,
      "TotalFee": 27.8865,
      "TotalReceivable": 1240.2835,
      "CreatedTime": "2023-07-13T03:49:46.43",
      "UpdatedTime": "2023-07-13T03:50:22.88",
      "WhiteLabelName": "REDEX",
      "CurrencyCode": "USD",
      "CurrencySymbolic": "$",
      "CurrencyDisplayFormat": "{CurrencyCode} {Symbolic}{Value}",
      "TaxPercent": 0.08,
      "TaxAmount": 91.87,
      "FeeCodeNumber": null,
      "Status": "Unpaid",
      "StatusDescription": "Unpaid",
      "ClientStatus": "Unpaid"
      }
    ]
  },
  "StatusCode": 200,
  "Message": "Success"
}

Error:

{
  "Data": null,
  "StatusCode": 400,
  "Message": "Bad request"
}
  • No labels