const resultToken = 'eyJhbGciOiJIUzI1NiIs...'; // from client after payment
const response = await fetch('https://api.orchestrasolutions.com/EWalletOperations/validateResults', {
method: 'POST',
headers: {
'X-Api-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify(resultToken)
});
const data = await response.json();
if (data.clientSuccess) {
console.log('Payment confirmed');
if (data.upgChargeResults) {
console.log('Reference:', data.upgChargeResults.gatewayReference);
}
} else {
console.log('Payment failed:', data.clientErrorMessage);
}
import requests
import json
result_token = 'eyJhbGciOiJIUzI1NiIs...' # from client after payment
response = requests.post(
'https://api.orchestrasolutions.com/EWalletOperations/validateResults',
headers={
'X-Api-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
data=json.dumps(result_token)
)
data = response.json()
if data.get('clientSuccess'):
print('Payment confirmed')
if data.get('upgChargeResults'):
print('Reference:', data['upgChargeResults']['gatewayReference'])
else:
print('Payment failed:', data.get('clientErrorMessage'))
{
"upgChargeResults": {
"authorizationCode": "<string>",
"amount": 123,
"operationResultDescription": "<string>",
"customGatewayResponse": null,
"gatewayName": "<string>",
"gatewayReference": "<string>",
"gatewayResultCode": "<string>",
"gatewayResultDescription": "<string>",
"gatewayResultSubCode": "<string>",
"gatewayResultSubDescription": "<string>",
"gatewayToken": null
},
"directChargeResults": {
"success": true,
"message": "<string>",
"data": null
},
"tokenAndMaskedCardModel": {
"bankCard": {
"nameOnCard": "<string>",
"issueNumber": "<string>",
"ownerId": "<string>",
"securityCode": "<string>",
"number": "<string>",
"expirationMonth": 123,
"expirationYear": 123
},
"threeDS": {
"authenticationValue": "<string>",
"eci": "<string>",
"xid": "<string>",
"version": "<string>",
"sli": "<string>",
"acsTransactionId": "<string>",
"universal_TransactionId": "<string>"
},
"errorMessage": "<string>",
"token": "<string>",
"tokenLocation": "<string>"
},
"failedUpgChargeResults": [
{
"authorizationCode": "<string>",
"amount": 123,
"operationResultDescription": "<string>",
"customGatewayResponse": null,
"gatewayName": "<string>",
"gatewayReference": "<string>",
"gatewayResultCode": "<string>",
"gatewayResultDescription": "<string>",
"gatewayResultSubCode": "<string>",
"gatewayResultSubDescription": "<string>",
"gatewayToken": null
}
]
}[
{
"fieldName": "<string>",
"errors": [
"<string>"
]
}
]Payments Library
Validate Operation results
POST
/
EWalletOperations
/
validateResults
const resultToken = 'eyJhbGciOiJIUzI1NiIs...'; // from client after payment
const response = await fetch('https://api.orchestrasolutions.com/EWalletOperations/validateResults', {
method: 'POST',
headers: {
'X-Api-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify(resultToken)
});
const data = await response.json();
if (data.clientSuccess) {
console.log('Payment confirmed');
if (data.upgChargeResults) {
console.log('Reference:', data.upgChargeResults.gatewayReference);
}
} else {
console.log('Payment failed:', data.clientErrorMessage);
}
import requests
import json
result_token = 'eyJhbGciOiJIUzI1NiIs...' # from client after payment
response = requests.post(
'https://api.orchestrasolutions.com/EWalletOperations/validateResults',
headers={
'X-Api-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
data=json.dumps(result_token)
)
data = response.json()
if data.get('clientSuccess'):
print('Payment confirmed')
if data.get('upgChargeResults'):
print('Reference:', data['upgChargeResults']['gatewayReference'])
else:
print('Payment failed:', data.get('clientErrorMessage'))
{
"upgChargeResults": {
"authorizationCode": "<string>",
"amount": 123,
"operationResultDescription": "<string>",
"customGatewayResponse": null,
"gatewayName": "<string>",
"gatewayReference": "<string>",
"gatewayResultCode": "<string>",
"gatewayResultDescription": "<string>",
"gatewayResultSubCode": "<string>",
"gatewayResultSubDescription": "<string>",
"gatewayToken": null
},
"directChargeResults": {
"success": true,
"message": "<string>",
"data": null
},
"tokenAndMaskedCardModel": {
"bankCard": {
"nameOnCard": "<string>",
"issueNumber": "<string>",
"ownerId": "<string>",
"securityCode": "<string>",
"number": "<string>",
"expirationMonth": 123,
"expirationYear": 123
},
"threeDS": {
"authenticationValue": "<string>",
"eci": "<string>",
"xid": "<string>",
"version": "<string>",
"sli": "<string>",
"acsTransactionId": "<string>",
"universal_TransactionId": "<string>"
},
"errorMessage": "<string>",
"token": "<string>",
"tokenLocation": "<string>"
},
"failedUpgChargeResults": [
{
"authorizationCode": "<string>",
"amount": 123,
"operationResultDescription": "<string>",
"customGatewayResponse": null,
"gatewayName": "<string>",
"gatewayReference": "<string>",
"gatewayResultCode": "<string>",
"gatewayResultDescription": "<string>",
"gatewayResultSubCode": "<string>",
"gatewayResultSubDescription": "<string>",
"gatewayToken": null
}
]
}[
{
"fieldName": "<string>",
"errors": [
"<string>"
]
}
]const resultToken = 'eyJhbGciOiJIUzI1NiIs...'; // from client after payment
const response = await fetch('https://api.orchestrasolutions.com/EWalletOperations/validateResults', {
method: 'POST',
headers: {
'X-Api-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify(resultToken)
});
const data = await response.json();
if (data.clientSuccess) {
console.log('Payment confirmed');
if (data.upgChargeResults) {
console.log('Reference:', data.upgChargeResults.gatewayReference);
}
} else {
console.log('Payment failed:', data.clientErrorMessage);
}
import requests
import json
result_token = 'eyJhbGciOiJIUzI1NiIs...' # from client after payment
response = requests.post(
'https://api.orchestrasolutions.com/EWalletOperations/validateResults',
headers={
'X-Api-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
data=json.dumps(result_token)
)
data = response.json()
if data.get('clientSuccess'):
print('Payment confirmed')
if data.get('upgChargeResults'):
print('Reference:', data['upgChargeResults']['gatewayReference'])
else:
print('Payment failed:', data.get('clientErrorMessage'))
Related
Library Reference
Result parsing, data structures, and validation
Authorizations
Please enter ApiKey into field
Body
application/json
Operation results token
The body is of type string.
⌘I