Skip to main content
GET
/
billing
/
bills
/
{bill}
Retrieve Bill
curl --request GET \
  --url https://api.momentco.io/billing/bills/{bill} \
  --header 'Authorization: Bearer <token>'
{
  "id": "bill_H4jp6KnU5cPw263v1jyz4",
  "external_reference": "UBR1234567890",
  "customer_id": "bcus_H4jp6KnU5cPw263v1jyz4",
  "account_id": "bacc_H4jp6KnU5cPw263v1jyz4",
  "status": "unpaid",
  "currency": "ZAR",
  "amount_due": 2000,
  "amount_paid": 0,
  "amount_remaining": 2000,
  "bill_date": "2025-01-01",
  "due_date": "2025-01-31",
  "payment_rules": {
    "min_amount": 100,
    "max_amount": 2000,
    "underpayment_allowed": true,
    "overpayment_allowed": false
  },
  "metadata": {
    "invoice_period": "January 2025",
    "service_type": "subscription"
  }
}

Authorizations

Authorization
string
header
required

Authentication using Bearer tokens. Include your API key in the Authorization header.

Key Types:

  • Test Keys: sk_test_* for development and testing
  • Live Keys: sk_* for production environments
  • Public Keys: pk_test_* or pk_* for client-side operations

📩 Need access? Contact Support to request your API keys.

Usage:

Authorization: Bearer sk_test_4eC39HqLyjWDarjtT1zdp7dc

Path Parameters

bill
required

Bill identifier - either the unique ID provided by Moment or the external reference provided by the merchant.

The unique ID provided by Moment to identify this bill

Pattern: ^bill_[a-zA-Z0-9]+$
Example:

"bill_H4jp6KnU5cPw263v1jyz4"

Response

Bill retrieved successfully

A bill represents a payment request that can be associated with a customer or specific account.

id
string
required

Unique identifier for a bill

Pattern: ^bill_[a-zA-Z0-9]+$
Example:

"bill_H4jp6KnU5cPw263v1jyz4"

external_reference
string
required

External reference for reconciliation or tracking purposes. Must be unique within your merchant account.

Maximum string length: 255
Pattern: ^[a-zA-Z0-9_-]+$
Example:

"INV-2024-001"

customer_id
string
required

Unique identifier for a customer

Pattern: ^bcus_[a-zA-Z0-9]+$
Example:

"bcus_H4jp6KnU5cPw263v1jyz4"

status
enum<string>
required

Current status of the bill

Available options:
unpaid,
paid,
voided
Example:

"unpaid"

currency
string
required

The ISO 4217 currency code for the payment.

Example:

"ZAR"

amount_due
integer
required

Payment amount due at the time of bill creation.

The value is in the smallest currency unit (e.g., cents for ZAR).

Required range: 1 <= x <= 99999999
Example:

2000

amount_paid
integer
required

The amount that has been paid against this bill.

The value is in the smallest currency unit (e.g., cents for ZAR).

Note: If amount_paid is specified, the currency field must also be provided.

Required range: 0 <= x <= 99999999
Example:

1500

amount_remaining
integer
required

The amount remaining to be paid against this bill.

The value is in the smallest currency unit (e.g., cents for ZAR).

Note: If amount_remaining is specified, the currency field must also be provided.

Required range: 0 <= x <= 99999999
Example:

500

account_id
string

Unique identifier for an account

Pattern: ^bacc_[a-zA-Z0-9]+$
Example:

"bacc_H4jp6KnU5cPw263v1jyz4"

bill_date
string<date>

The date the bill was raised in ISO 8601 format (YYYY-MM-DD). Defaults to current date if not provided.

Example:

"2025-01-01"

due_date
string<date>

The due date for bill payment in ISO 8601 format (YYYY-MM-DD)

Example:

"2025-01-31"

payment_rules
object

Payment rules associated with the entity. If not specified, the entity cannot be paid against.

metadata
object

Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. NEW Limitations:

  • Maximum 10 keys
  • Key names must be strings (max 40 characters)
  • Values must be strings (max 500 characters)
Example:
{
"customer_id": "cust_123456",
"order_id": "ord_789012"
}