GET/v1.1/online-payments/payment-request/<code>
Request headers
Attribute |
Type |
Condition |
Description |
X-Request-ID |
UUID |
Mandatory |
ID of the request, unique to the call. |
Authorization |
String |
Mandatory |
The oAuth2 Bearer token |
API-Key |
String |
Mandatory |
The Client ID obtained from the myPOS Account |
Path parameters
Attribute | Type | Condition | Description |
code | String | Mandatory | Unique code of the payment request. |
Response headers
Attribute |
Type |
Condition |
Description |
X-Request-ID |
UUID |
Mandatory |
ID of the request, unique to the call. |
Content-Type |
String |
Mandatory |
application/json |
Response body
Attribute |
Type |
Condition |
Description |
- |
Payment Request Details |
Mandatory |
Fields with details for payment request. |
Examples
curl --location --request GET 'https://transactions-api.mypos.com/v1.1/online-payments/payment-request/BI8QOBJQKTWN45' \ --header 'API-Key: MY_API_KEY' \ --header 'X-Request-ID: 232465ab-66ea-4776-b3f0-f7a123f988e4' \ --header 'Authorization: Bearer yAacLGA2ucAckxHsgYgMe7kK5yT5KERHtkIrirjSDU'
import requests url = "https://transactions-api.mypos.com/v1.1/online-payments/payment-request/BI8QOBJQKTWN45" payload={} headers = { 'API-Key': 'MY_API_KEY', 'X-Request-ID': '232465ab-66ea-4776-b3f0-f7a123f988e4', 'Authorization': 'Bearer yAacLGA2ucAckxHsgYgMe7kK5yT5KERHtkIrirjSDU' } response = requests.request("GET", url, headers=headers, data=payload)
var request = require('request'); var options = { 'method': 'GET', 'url': 'https://transactions-api.mypos.com/v1.1/online-payments/payment-request/BI8QOBJQKTWN45', 'headers': { 'API-Key': 'MY_API_KEY', 'X-Request-ID': '232465ab-66ea-4776-b3f0-f7a123f988e4', 'Authorization': 'Bearer yAacLGA2ucAckxHsgYgMe7kK5yT5KERHtkIrirjSDU' } }; request(options, function (error, response) { });
<?php require_once 'HTTP/Request2.php'; $request = new HTTP_Request2(); $request->setUrl('https://transactions-api.mypos.com/v1.1/online-payments/payment-request/BI8QOBJQKTWN45'); $request->setMethod(HTTP_Request2::METHOD_GET); $request->setConfig(array( 'follow_redirects' => TRUE )); $request->setHeader(array( 'API-Key' => 'MY_API_KEY', 'X-Request-ID' => '232465ab-66ea-4776-b3f0-f7a123f988e4', 'Authorization' => 'Bearer yAacLGA2ucAckxHsgYgMe7kK5yT5KERHtkIrirjSDU' )); try { $response = $request->send(); if ($response->getStatus() == 200) { echo $response->getBody(); } else { echo 'Unexpected HTTP status: ' . $response->getStatus() . ' ' . $response->getReasonPhrase(); } } catch(HTTP_Request2_Exception $e) { echo 'Error: ' . $e->getMessage(); }
{ "code": "BI8QOBJQKTWN45", "url": "https://mypos.eu/public/pr/BI8QOBJQKTWN45", "added_on": "2021-03-16 13:33:25", "client_name": "My client", "amount": 2.14, "currency": "EUR", "reason": "Payment Request Reason", "booking_text": "Booking Text", "attempts": 0, "expiry_on": "2021-04-16 23:59:59", "qr_generated": false, "email": "client@gmail.com", "gsm": "+359899999999", "status": 1 }