GET api/pos/payments?state={state}&orderId={orderId}&terminalId={terminalId}&accessToken={accessToken}&bioCode={bioCode}
Gets a list of active payments (ie. neither captured, rejected, cancelled, or reversed) if no paymentState is provided.
Can also return only captured payments if the Captured paymentState is explicitly provided.
You can use this also in the case of an unexpected restart of the client where the payment flow cannot be continued it might be necessary to cancel the active payment since there can be only one active payment on a PoS. If the paymentId of the active payment is lost it can be retrieved by calling API.
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| state |
The state of the payment. Possible states "Prepared","Initiated","Paired","IssuedToUser", "Reserved","CancelledByUser","CancelledByClient","CancelledByMobilePay","ExpiredAndCancelled","Captured","RejectedByMobilePayDueToAgeRestrictions" |
string |
None. |
| orderId |
The orderId |
string |
None. |
| terminalId |
Required : The terminalId |
string |
None. |
| accessToken | string |
None. |
|
| bioCode | string |
None. |
Body Parameters
None.
Response Information
Resource Description
The IDs of the payments that matched the query if success is true, otherwise errors
PosPaymentsIdsViewModel| Name | Description | Type | Additional information |
|---|---|---|---|
| paymentsIds | Collection of string |
None. |
|
| success | boolean |
None. |
|
| errors | Collection of string |
None. |
Response Formats
application/xml, text/xml
<PosPaymentsIdsViewModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/_1SA_MobilePay_POS_ViewModels.ViewModels">
<errors xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d2p1:string>sample string 1</d2p1:string>
<d2p1:string>sample string 2</d2p1:string>
</errors>
<success>true</success>
<paymentsIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d2p1:string>sample string 1</d2p1:string>
<d2p1:string>sample string 2</d2p1:string>
</paymentsIds>
</PosPaymentsIdsViewModel>
application/json, text/json
{
"paymentsIds": [
"sample string 1",
"sample string 2"
],
"success": true,
"errors": [
"sample string 1",
"sample string 2"
]
}