FolioActions

Splits a payment into two using the percent or amount provided Creates a refund and two new payments.

<br>You must have at least one of these scopes: 'payments.create, refunds.create, folios.manage'.<br>For fine-grained clients, you must have this permission: 'core.folios.split_payment'.

post/finance/v1/folio-actions/{folioId}/payments/{paymentId}/split

Request

  • Base URL
    https://api.apaleo.com (the document declares no server; this is the origin it was published from)
  • URL
    https://api.apaleo.com/finance/v1/folio-actions/{folioId}/payments/{paymentId}/split
  • Auth
    OAuth 2
    Implicit: https://identity.apaleo.com/connect/authorize
    Scopes: payments.create, refunds.create, folios.manage, admin

Path parameters

folioIdstring required

The folio ID

paymentIdstring required

The ID of the payment

Headers

Idempotency-Keystring

Unique key for safely retrying requests without accidentally performing the same operation twice. We'll always send back the same response for requests made with the same key, and keys can't be reused with different request parameters. Keys expire after 24 hours.

Request body

percentnumber double nullable

The percent to split payment (between 0 and 100)

type'ByPercent' | 'ByAmount' required

How to split the payment: by percent value, or by absolute amount

Example request

{
  "percent": 51,
  "type": "ByPercent"
}

Response

OK

refundIdstring nullable
firstPaymentIdstring nullable
secondPaymentIdstring nullable

Example response

{
  "refundId": "ABCDEF-1-1",
  "firstPaymentId": "ABCDEF-1-2",
  "secondPaymentId": "ABCDEF-1-3"
}

Changes

No recorded changes to this operation across all 3 revisions of this API.