From Barion Documentation
Revision as of 20:44, 1 December 2021 by Stankovicsa (talk | contribs) (→‎Possible error responses)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Barion API: Validate Apple Pay session

POST /v2/ApplePay/ValidateSession

Input properties

Property name Property type Limitations and constraints Description
POSKey Guid * Required The secret API key of the shop, generated by Barion. This lets the shop to authenticate through the Barion API, but does not provide access to the account owning the shop itself.
SessionRequestUrl string * Required The Session Request url, provided by Apple in the onvalidatemerchant callback as validationURL parameter.
ShopUrl string * Required The url of the shop, where the payment is being initialized.

Output properties

Property name Property type Description
ApplePaySessionResponse string The validation response received from Apple.

Possible error responses

Error code Description
AuthenticationFailed Authentication failed.
ModelValidationError This happens when some of the input properties fail the basic validation. For example the session request url is malformed.
InvalidShop The provided poskey is invalid.
NotRegisteredToApple The provided shop url is not registered to Apple.
InvalidShopUrl The provided shop url is invalid.
UnableToCreateApplePaySession A technical error occured, and Apple Pay Session could not be created.