The Sales Invoice Payment object

Attributes

id string

Unique identifier for the object.

idx integer
parent_id string required
parent_type string required
mode_of_payment string required
amount number

Default: 0

account string
type string
base_amount number
clearance_date string
default boolean

Default: false

reference_no string
The Sales Invoice Payment object
{
  "id": "sales-invoice-payment_abc123",
  "idx": 1,
  "parent_id": null,
  "parent_type": "parent_type_example",
  "mode_of_payment": "mode_of_payment_example",
  "amount": 0,
  "account": "account_example",
  "type": "type_example",
  "base_amount": 0,
  "clearance_date": "2024-01-15",
  "default": false,
  "reference_no": "reference_no_example"
}
GET /api/accounts/sales-invoice-payment?parent_id={id}

List sales invoice payments by parent

Returns all sales invoice payments belonging to the specified parent.

Query parameters

parent_id string required

The ID of the parent to list children for.

Returns

A list of sales invoice payment objects belonging to the parent.

GET /api/accounts/sales-invoice-payment?parent_id={id}
curl https://api.overplane.dev/api/accounts/sales-invoice-payment?parent_id=parent_abc123 \
  -H "Authorization: Bearer sk_test_..."
Response
{
  "data": [
    {
      "id": "sales-invoice-payment_abc123",
      "idx": 1,
      "parent_id": null,
      "parent_type": "parent_type_example",
      "mode_of_payment": "mode_of_payment_example",
      "amount": 0,
      "account": "account_example",
      "type": "type_example",
      "base_amount": 0,
      "clearance_date": "2024-01-15",
      "default": false,
      "reference_no": "reference_no_example"
    }
  ],
  "has_more": false,
  "total": 1
}
POST /api/accounts/sales-invoice-payment

Create a sales invoice payment

Creates a new sales invoice payment object.

Body parameters

idx integer
parent_id string required
parent_type string required
mode_of_payment string required
amount number

Default: 0

account string
type string
base_amount number
clearance_date string
default boolean

Default: false

reference_no string

Returns

Returns the newly created sales invoice payment object if the call succeeded.

POST /api/accounts/sales-invoice-payment
curl https://api.overplane.dev/api/accounts/sales-invoice-payment \
  -H "Authorization: Bearer sk_test_..." \
  -X POST \
  -H "Content-Type: application/json" \
  -d '{"parent_id":null,"parent_type":"parent_type_example","mode_of_payment":"mode_of_payment_example"}'
Response
{
  "id": "sales-invoice-payment_abc123",
  "idx": 1,
  "parent_id": null,
  "parent_type": "parent_type_example",
  "mode_of_payment": "mode_of_payment_example",
  "amount": 0,
  "account": "account_example",
  "type": "type_example",
  "base_amount": 0,
  "clearance_date": "2024-01-15",
  "default": false,
  "reference_no": "reference_no_example"
}
PATCH /api/accounts/sales-invoice-payment/{id}

Update a sales invoice payment

Updates the specified sales invoice payment by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

Path parameters

id string required

The identifier of the sales invoice payment to update.

Body parameters

idx integer
parent_id string
parent_type string
mode_of_payment string
amount number

Default: 0

account string
type string
base_amount number
clearance_date string
default boolean

Default: false

reference_no string

Returns

Returns the updated sales invoice payment object.

PATCH /api/accounts/sales-invoice-payment/{id}
curl https://api.overplane.dev/api/accounts/sales-invoice-payment/sales-invoice-payment_abc123 \
  -H "Authorization: Bearer sk_test_..." \
  -X PATCH \
  -H "Content-Type: application/json" \
  -d '{"idx":1,"parent_id":null}'
Response
{
  "id": "sales-invoice-payment_abc123",
  "idx": 1,
  "parent_id": null,
  "parent_type": "parent_type_example",
  "mode_of_payment": "mode_of_payment_example",
  "amount": 0,
  "account": "account_example",
  "type": "type_example",
  "base_amount": 0,
  "clearance_date": "2024-01-15",
  "default": false,
  "reference_no": "reference_no_example"
}
DELETE /api/accounts/sales-invoice-payment/{id}

Delete a sales invoice payment

Permanently deletes a sales invoice payment. This cannot be undone.

Path parameters

id string required

The identifier of the sales invoice payment to delete.

Returns

Returns a confirmation that the sales invoice payment has been deleted.

DELETE /api/accounts/sales-invoice-payment/{id}
curl https://api.overplane.dev/api/accounts/sales-invoice-payment/sales-invoice-payment_abc123 \
  -H "Authorization: Bearer sk_test_..." \
  -X DELETE
Response
{
  "id": "sales-invoice-payment_abc123",
  "deleted": true
}
POST /api/accounts/sales-invoice-payment/reorder

Reorder sales invoice payments

Updates the sort order of sales invoice payments within their parent by setting new index values.

Returns

Returns the reordered list.

POST /api/accounts/sales-invoice-payment/reorder
curl https://api.overplane.dev/api/accounts/sales-invoice-payment/reorder \
  -H "Authorization: Bearer sk_test_..." \
  -X POST
Response
{
  "id": "sales-invoice-payment_abc123",
  "idx": 1,
  "parent_id": null,
  "parent_type": "parent_type_example",
  "mode_of_payment": "mode_of_payment_example",
  "amount": 0,
  "account": "account_example",
  "type": "type_example",
  "base_amount": 0,
  "clearance_date": "2024-01-15",
  "default": false,
  "reference_no": "reference_no_example"
}