Get Bill List

This API is to fetch a list of bills from across all collections.

Authentication

LeanX uses Auth Token to authenticate in each request's header.

Auth Token can be retrieved in your portal dashboard under API page.

Request Header

{
    "auth-token": "LP-0D7C06DE-MM|7394e58e-edee-4c42-9ca5-bcbc449f1b9f|2141df4a3cb633d5ce8683bb0c55067e5caebfbe07390dde277dc455bcc95c91723a81b5e565c7c02d68fb84e396722563016bf99e576a4b8cdbe4423fbf226b"
}

Get Bill List

HTTP Method: POST

https://api.leanx.dev/api/v1/merchant/bill-list

Query

Query
Type
Description

skip*

Number

Start row

limit*

Number

Amount of row per page

Request Body

{
  "start_date": "01-01-1970",
  "end_date": "31-12-2050",
  "record_status": 1,
  "invoice_status": "success",
  "search": {
    "search_enable": true,
    "search_key": "50",
    "search_column": "id"
  },
  "sort": {
    "parameter_name": "created_at",
    "sort_type": "desc"
  }
}

Attributes

Property
Type
Description

start_date*

String

Start date in DD-MM-YYYY format

end_date*

String

End date in DD-MM-YYYY format

record_status*

Number

1 = ACTIVE

invoice_status

String

success/failed/pending

search.search_enable*

Boolean

To enable searches

search.search_key

String

Search value. Required if search.search_enable is true

search.search_column

String

A collection property. Required if search.search_enable is true

sort.sort_type

String

asc or desc

sort.parameter_name

String

One of collection property. Eg: created_at

Response

{
  "response_code": 2000,
  "description": "SUCCESS",
  "app_version": "/api/v1",
  "talk_to_server_before": "2023-02-01T17:53:25.430186",
  "data": {
    "list": {
      "draw": 1,
      "record_total": 1,
      "record_filtered": 1,
      "data": [
        {
          "phone_number": "0182954574",
          "invoice_status_id": 2,
          "collection_id": 16,
          "created_at": "2023-01-31T14:48:53",
          "status": null,
          "bill_transaction_type_id": 1,
          "payment_record_id": 74,
          "updated_at": "2023-01-31T14:48:55",
          "id": 73,
          "total": 1.00,
          "shipping_address_id": null,
          "customer_id": 28,
          "total_amount_with_fee": 1.70,
          "invoice_status": "SUCCESS",
          "account_id": 2,
          "full_name": "Roro",
          "transaction_fee": 0.70,
          "base_url": null,
          "api_key": null,
          "quantity": 1,
          "checking_counter": 1,
          "payment_date": "2023-01-31T14:48:54",
          "email": "roro@gmail.com",
          "invoice_no": "BP-5F1F5BD9E7-LNP",
          "price_per_quantity": null,
          "record_status": 1,
          "transaction_invoice_no": "FPX16751477326yuoZYft",
          "customer_bill_payment_record": {
            "reference_number": "FPX16751477326yuoZYft",
            "payment_date": "2023-01-31T14:48:54",
            "payment_method": "STANDARD_CHARTERED_WEBPAY",
            "transaction_fee": 0.50,
            "bank_code": null,
            "net_amount": 2,
            "total": null,
            "record_status": 1,
            "updated_at": "2023-01-31T14:48:55",
            "id": 74,
            "payment_mode": "WEB_PAYMENT",
            "amount": 1,
            "kind": null,
            "paid_at": null,
            "customer_id": 28,
            "created_at": "2023-01-31T14:48:53"
          }
        }
      ],
      "next_page_start": 10,
      "next_page_length": 10,
      "previous_page_start": 0,
      "previous_page_length": 10
    }
  },
  "breakdown_errors": null,
  "token": ""
}

Last updated