POST
/
customers
/
{customer_id}
/
balance_transactions
curl --request POST \
  --url https://api.withorb.com/v1/customers/{customer_id}/balance_transactions \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "amount": "<string>",
  "type": "increment",
  "description": "<string>"
}'
{
  "id": "cgZa3SXcsPTVyC4Y",
  "created_at": "2022-05-01T07:01:31+00:00",
  "starting_balance": "33.00",
  "ending_balance": "22.00",
  "amount": "11.00",
  "action": "applied_to_invoice",
  "description": "An optional description",
  "invoice": {
    "id": "gXcsPTVyC4YZa3Sc"
  },
  "type": "increment",
  "credit_note": {
    "id": "<string>"
  }
}

Authorizations

Authorization
string
header
required

API Keys can be issued in the Orb's web application.

Path Parameters

customer_id
string
required

Body

application/json
amount
string
required
type
enum<string>
required
Available options:
increment,
decrement
description
string | null

An optional description that can be specified around this entry.

Response

200
application/json
OK
id
string
required

A unique id for this transaction.

Example:

"cgZa3SXcsPTVyC4Y"

created_at
string
required

The creation time of this transaction.

Example:

"2022-05-01T07:01:31+00:00"

starting_balance
string
required

The original value of the customer's balance prior to the transaction, in the customer's currency.

Example:

"33.00"

ending_balance
string
required

The new value of the customer's balance prior to the transaction, in the customer's currency.

Example:

"22.00"

amount
string
required

The value of the amount changed in the transaction.

Example:

"11.00"

action
enum<string>
required
Available options:
applied_to_invoice,
manual_adjustment,
prorated_refund,
revert_prorated_refund,
return_from_voiding,
credit_note_applied,
credit_note_voided,
overpayment_refund,
external_payment
description
string | null
required

An optional description provided for manual customer balance adjustments.

Example:

"An optional description"

invoice
object | null
required
type
enum<string>
required
Available options:
increment,
decrement
credit_note
object | null
required