Requests an Apple Pay session.
Requests a new Apple Pay session including merchant validation. The client needs to acquire the validation url beforehand.
This endpoint is pre-requisite for calling /payment-method-kinds/applepay/authorize
.
Responses
-
201 application/vnd.api+json
Created
-
401 application/vnd.api+json
OAuth token missing or invalid or a linked identity is missing.
Linked identity missing is a special case where you need to make sure that the user has additionally logged in / authorized with a third-party.
This is not relevant for most use-cases.
The specific error code that identifies a missing linked identity is
missing-linked-identity
Example:
{ "errors": [ { "id": "cbgmhslmp1o9or9kh1p0", "title": "Missing linked identity for authorized access", "detail": "Linked identity is needed to access this resource, please check why the user does not have a linked identity", "status": "401", "code": "missing-linked-identity" } ] }
-
403 application/vnd.api+json
Amount cannot be authorized
-
404 application/vnd.api+json
Payment information cannot be resolved with Apple Pay.
-
406 application/vnd.api+json
The specified accept header is invalid
-
409 application/vnd.api+json
Resource conflicts
-
500 application/vnd.api+json
Internal server error
-
502 application/vnd.api+json
Error occurred while communicating with upstream services
curl \
-X POST https://api.pace.cloud/pay/2024-3/payment-method-kinds/applepay/session \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/vnd.api+json"
{
"data": {
"type": "applePayPaymentSession",
"id": "f4267aea-2567-4a3c-934d-b8355a76abe9",
"attributes": {
"validationURL": "apple-pay-gateway.apple.com/paymentservices"
}
}
}
{
"data": {
"type": "applePayPaymentSession",
"id": "f4267aea-2567-4a3c-934d-b8355a76abe9",
"attributes": {
"epochTimestamp": 1555507053169,
"expiresAt": 1555507053169,
"merchantSessionIdentifier": "SSH2EAF8AFAEAA94DEEA898162A5DAFD36E_916523AAED1343F....E12BEE",
"merchantIdentifier": "BD62FEB196874511C22DB28A9E14A89E3534C93194F73EA417EC566368D391EB",
"domainName": "pay.example.org",
"displayName": "Your eCommerce Shop DO NOT LOCALIZE",
"signature": "308006092a864886f7...8cc030ad3000000000000",
"nonce": "AAKJHJGS83732",
"operationalAnalyticsIdentifier": "string"
}
}
}
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
{
"errors": [
{
"id": "string",
"links": {
"about": "string"
},
"status": "string",
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}