Authorize a payment using Google Pay by providing a Google Pay token.
When successful, returns a paymentToken value. Requires the caller to interact with Google Pay
to create the googlePay
specific authorization data.
POST /payment-method-kinds/googlepay/authorize
curl \
-X POST https://api.pace.cloud/pay/2024-3/payment-method-kinds/googlepay/authorize \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/vnd.api+json"
Request examples
{
"data": {
"type": "paymentToken",
"id": "f4267aea-2567-4a3c-934d-b8355a76abe9",
"attributes": {
"currency": "EUR",
"amount": 65.49,
"purposePRNs": [
"prn:poi:gas-stations:124e522d-65ef-4386-b7e0-00d2eceeadc6",
"prn:cms:fuels:ron95"
],
"discountTokens": [
"prn:discount:tokens:f7aa2664-bcfa-4e23-967d-ecd6596b73a9"
],
"twoFactor": {
"otp": "366382",
"method": "string"
},
"googlePay": {
"version": "ECv1",
"signature": "MEUCIFWTRWUZAOM5nfJC79FtJm56olnbwG4H5uWWxAUWA...",
"paymentData": {
"encryptedMessage": "8nxjB9mr2tWZeDRQRcGN91UUnb7AioGp3oRo8kmQ6lyvJZiqD7PJlbR...",
"ephemeralPublicKey": "BGH3fRFdoAobYrAlxnZOCYzkH84Cna92IZxtgsU36CMDaqSaDYb9/Ls...",
"tag": "nvmOUNpnOTZULLhMxT/hWCHzH/4f7gGpfvQgwl3p8ng"
}
},
"billingEmail": "jon.smith@example.com"
}
}
}
Response examples (201)
{
"data": {
"type": "paymentToken",
"id": "33331f72-a672-453c-9d36-d5809ef0ded6",
"attributes": {
"amount": 23,
"currency": "EUR",
"value": "12c52345c1x34",
"validUntil": "2024-05-04T09:42:00+00:00",
"accountPRN": [
"prn:pay:accounts:pace"
],
"purposePRNs": [
"prn:poi:gas-stations:124e522d-65ef-4386-b7e0-00d2eceeadc6",
"prn:cms:fuels:ron95"
]
},
"relationships": {
"paymentMethod": {
"data": {
"type": "paymentMethod",
"id": "33331f72-a672-453c-9d36-d5809ef0ded6"
}
}
}
}
}
Response examples (401)
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
Response examples (403)
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
Response examples (404)
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
Response examples (406)
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
Response examples (409)
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
Response examples (410)
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
Response examples (415)
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
Response examples (500)
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
Response examples (502)
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}