Payments
Start payments, cancel payments, EFT-POS payments and order payments.
This page covers the single-transaction payment operations. They all return a
PPStartPaymentResponseModel
(except order payment, which returns
PPOrderPaymentResponseModel).
Each request is created with a toRequest(...) factory. Flutter and React
Native use camelCase parameter names; the native Android package uses
snake_case.
Start a payment
Starts a new payment on POS+ for an order.
The order must first be created via the API. The orderCode you pass must
belong to that order; otherwise an order not found error is returned.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
orderCode | String | yes | Your unique order code |
paymentType | PPPaymentType | yes | e.g. POS, CASH |
paymentMethod | PPPaymentMethod | yes | e.g. CC, QR, NFC |
totalAmount | double | yes | Total amount to charge |
installment | int | no | Number of installments |
isPartial | bool | no | Partial payment (default false) |
partialType | PPPartialPaymentType | no | AMOUNT or PRODUCT |
products | List<PPProduct> | no | Line items (id, qty) |
billingInformation | PPBillingInfo | no | Invoice / billing details |
final result = await _pluspay.startPayment(
PPStartPaymentRequestModel.toRequest(
orderCode: 'ORD001',
totalAmount: 11.9,
paymentType: PPPaymentType.POS,
paymentMethod: PPPaymentMethod.CC,
),
);
print(result.status); // transaction status
print(result.id); // POS+ transaction id
print(result.payment?.rrn); // bank reference numberFor a partial payment set isPartial: true and provide partialType
(AMOUNT or PRODUCT). For product-based partial payments also pass
products.
Cancel a payment
Cancels a previously completed payment by its transaction id.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
transactionId | String | yes | Id returned by the original payment |
orderCode | String | yes | The original order code |
note | String | no | Free-text cancellation note |
await _pluspay.cancelPayment(
PPCancelPaymentRequestModel.toRequest(
orderCode: 'ORD001',
transactionId: '539c5225-0741-4f0e-b460-1fdb842c2c16',
note: 'Customer cancelled',
),
);EFT-POS payment
Starts a payment directly on the EFT-POS device. Requires a tax rate.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
totalAmount | double | yes | Amount to charge |
paymentType | PPPaymentType | yes | Payment type |
paymentMethod | PPPaymentMethod | yes | Payment method |
transactionId | String | yes | Your transaction id |
taxRate | int | yes | Applied tax rate (%) |
installment | int | no | Number of installments |
await _pluspay.startEftPayment(
PPEftPaymentRequestModel.toRequest(
totalAmount: 3.0,
paymentType: PPPaymentType.POS,
paymentMethod: PPPaymentMethod.CC,
transactionId: '27517a85-cfc3-4eee-b83b-63dc6bcb9fd6',
taxRate: 0,
),
);Cancel an EFT-POS payment
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
transactionId | String | yes | The EFT transaction id |
totalAmount | double | yes | Amount of the EFT transaction |
await _pluspay.cancelEftPayment(
PPEftCancelRequestModel.toRequest(
transactionId: 'a111ed26-ed2b-4f0b-9d6c-82056e52c96c',
totalAmount: 3.0,
),
);Pay an existing order
Pays an order that already exists in POS+, addressed only by its order code.
Returns a PPOrderPaymentResponseModel
containing the order totals and the list of transaction results.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
orderCode | String | yes | The existing order code in POS+ |
final result = await _pluspay.startOrderPayment(
PPOrderPaymentRequestModel.toRequest(
orderCode: 'ORD001',
),
);
print(result.status); // PPOrderStatusEnum
print(result.amountDue);
for (final r in result.results) {
print('${r.completed} ${r.errorMessage}');
}Next: Multi-payment for product-based orders with multiple transactions.

