PrePayment
PrePayment
Create a pre-payment on order
Create a pre-payment on order. Returns a settlementUid, and is handled at the settlements/{settlementUid} endpoint
Required permissions: SALES_ORDER,RETURN_ORDER
Access token recevied after user login with a deviceToken
Reference to a tenant.
^[A-Za-z0-9-_]+Reference to a Store.
^[A-Za-z0-9-_]+Reference to an Order.
^[A-Za-z0-9-_]+Create a new settlement
in cents, e.g. 1,50 as 150
External reference for the settlement
^[A-Za-z0-9-_]+Example response
The external payment reference for this settlement. For invoices, this could contain the KID
Ledger number must be a valid number with possible leading zeros
| ENUM | Description |
|---|---|
| LEDGER | Ledger |
| GENERAL_LEDGER | General ledger |
| CUSTOMER_LEDGER | Customer ledger |
^[A-Za-z0-9-_]+^[A-Za-z0-9-_]+^[A-Za-z0-9-_]+Number of credits on this settlement. Only applicable for invoice
The total amount credited. Only applicable for invoice
Number of payments on this settlement. Only applicable for invoice
The total amount of payments. Only applicable for invoice
^[A-Za-z0-9-_]*Display name of the till where the payment was registered.
Till register number where the payment was registered.
^[A-Za-z0-9-_]*Display name of the store where the payment was registered.
^[A-Za-z0-9-_]*The total authorized amount on this settlement, calculated from authorize transactions.
The total captured amount on this settlement, calculated from capture transactions.
The total refunded amount on this settlement, calculated from refund transactions.
Text printed on the receipt for this payment method when configured on the tenant payment method. Empty when not set, when suppressed for this settlement type (e.g. store credit, gift cards), or when cleared.
POST /v2/tenants/{tenantUid}/stores/{storeUid}/orders/{orderUid}/pre-payments HTTP/1.1
Host: api.flowretail.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 124
{
"amount": 1,
"externalId": "text",
"settlementCode": "text",
"parameters": [
{
"key": "text",
"value": "text"
}
],
"settlementUid": "text"
}Example response
{
"amount": 1,
"createdAt": "2026-01-01T00:00:00.000Z",
"displayMessages": [
{
"key": "text",
"message": "text",
"timestamp": "2026-01-01T00:00:00.000Z"
}
],
"externalId": "text",
"externalPaymentReference": "text",
"idMethod": "NO_CVM_RULE_PERFORMED",
"lastModifiedAt": "2026-01-01T00:00:00.000Z",
"ledgerNumber": "text",
"ledgerType": "LEDGER",
"parameters": [
{
"key": "text",
"value": "text",
"name": "text",
"type": "TEXT"
}
],
"settledAt": "2026-01-01T00:00:00.000Z",
"settlementCode": "text",
"settlementUid": "text",
"settlementName": "text",
"state": "NOT_STARTED",
"status": "NEW",
"storeSettlementIssuer": {
"storeSettlementIssuerUid": "text",
"name": "text",
"code": "text"
},
"tenantUserDisplayName": "text",
"tenantUserUid": "text",
"storePaymentMethodUid": "text",
"currency": {
"amount": 1,
"code": "text",
"exchangeRate": 1
},
"additionalDetails": [
{
"key": "text",
"value": "text"
}
],
"creditCount": 1,
"creditAmount": 1,
"paymentCount": 1,
"paymentAmount": 1,
"tillUid": "text",
"tillName": "text",
"tillNumber": 1,
"storeUid": "text",
"storeName": "text",
"orderReceiptUid": "text",
"authorizedAmount": 1,
"capturedAmount": 1,
"refundedAmount": 1,
"receiptText": "text",
"transactions": [
{
"transactionType": "text",
"pspTransactionId": "text",
"transactionAmount": 1,
"orderReceiptUid": "text"
}
]
}Create a pre-payment refund on order
Create a pre-payment refund on order. Returns a settlementUid, and is handled at the settlements/{settlementUid} endpoint
Required permissions: SALES_ORDER,RETURN_ORDER
Access token recevied after user login with a deviceToken
Reference to a tenant.
^[A-Za-z0-9-_]+Reference to a Store.
^[A-Za-z0-9-_]+Reference to an Order.
^[A-Za-z0-9-_]+Create a new settlement refund
in cents, e.g. 1,50 as 150
External reference for the settlement
The settlement uid
^[A-Za-z0-9-_]+The settlement that is being refunded
^[A-Za-z0-9-_]+Example response
The external payment reference for this settlement. For invoices, this could contain the KID
Ledger number must be a valid number with possible leading zeros
| ENUM | Description |
|---|---|
| LEDGER | Ledger |
| GENERAL_LEDGER | General ledger |
| CUSTOMER_LEDGER | Customer ledger |
^[A-Za-z0-9-_]+^[A-Za-z0-9-_]+^[A-Za-z0-9-_]+Number of credits on this settlement. Only applicable for invoice
The total amount credited. Only applicable for invoice
Number of payments on this settlement. Only applicable for invoice
The total amount of payments. Only applicable for invoice
^[A-Za-z0-9-_]*Display name of the till where the payment was registered.
Till register number where the payment was registered.
^[A-Za-z0-9-_]*Display name of the store where the payment was registered.
^[A-Za-z0-9-_]*The total authorized amount on this settlement, calculated from authorize transactions.
The total captured amount on this settlement, calculated from capture transactions.
The total refunded amount on this settlement, calculated from refund transactions.
Text printed on the receipt for this payment method when configured on the tenant payment method. Empty when not set, when suppressed for this settlement type (e.g. store credit, gift cards), or when cleared.
POST /v2/tenants/{tenantUid}/stores/{storeUid}/orders/{orderUid}/pre-payments/refund HTTP/1.1
Host: api.flowretail.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 158
{
"amount": 1,
"externalId": "text",
"settlementCode": "text",
"parameters": [
{
"key": "text",
"value": "text"
}
],
"settlementUid": "text",
"referencingSettlementUid": "text"
}Example response
{
"amount": 1,
"createdAt": "2026-01-01T00:00:00.000Z",
"displayMessages": [
{
"key": "text",
"message": "text",
"timestamp": "2026-01-01T00:00:00.000Z"
}
],
"externalId": "text",
"externalPaymentReference": "text",
"idMethod": "NO_CVM_RULE_PERFORMED",
"lastModifiedAt": "2026-01-01T00:00:00.000Z",
"ledgerNumber": "text",
"ledgerType": "LEDGER",
"parameters": [
{
"key": "text",
"value": "text",
"name": "text",
"type": "TEXT"
}
],
"settledAt": "2026-01-01T00:00:00.000Z",
"settlementCode": "text",
"settlementUid": "text",
"settlementName": "text",
"state": "NOT_STARTED",
"status": "NEW",
"storeSettlementIssuer": {
"storeSettlementIssuerUid": "text",
"name": "text",
"code": "text"
},
"tenantUserDisplayName": "text",
"tenantUserUid": "text",
"storePaymentMethodUid": "text",
"currency": {
"amount": 1,
"code": "text",
"exchangeRate": 1
},
"additionalDetails": [
{
"key": "text",
"value": "text"
}
],
"creditCount": 1,
"creditAmount": 1,
"paymentCount": 1,
"paymentAmount": 1,
"tillUid": "text",
"tillName": "text",
"tillNumber": 1,
"storeUid": "text",
"storeName": "text",
"orderReceiptUid": "text",
"authorizedAmount": 1,
"capturedAmount": 1,
"refundedAmount": 1,
"receiptText": "text",
"transactions": [
{
"transactionType": "text",
"pspTransactionId": "text",
"transactionAmount": 1,
"orderReceiptUid": "text"
}
]
}Last updated