ApplePay-StartPaymentWithAppleToken: Difference between revisions
Jump to navigation
Jump to search
Stankovicsa (talk | contribs) |
|||
(4 intermediate revisions by one other user not shown) | |||
Line 15: | Line 15: | ||
| 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. | | 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. | ||
|- | |- | ||
| ShippingContact || [[ApplePayShippingContact|ShippingContact]] || * Required || The shipping information of the payer | | ShippingContact || [[ApplePayShippingContact|ShippingContact]] || * Required || The shipping information of the payer provided by Apple | ||
|- | |- | ||
| BillingContact || [[ApplePayBillingContact|BillingContact]] || * Required|| The billing information of the payer | | BillingContact || [[ApplePayBillingContact|BillingContact]] || * Required|| The billing information of the payer provided by Apple | ||
|- | |- | ||
| | | ApplePayToken || [[ApplePayToken|Token]] || * Required|| The Token provided by Apple in [https://developer.apple.com/documentation/apple_pay_on_the_web/applepaysession/1778020-onpaymentauthorized onpaymentauthorized] callback. | ||
|- | |- | ||
| PaymentType || string || | | PaymentType || string || | ||
Line 79: | Line 79: | ||
|- | |- | ||
|} | |} | ||
Note: You can pass all the properties of [[Payment-Start-v2|PaymentStart]], but the rest of it is not used in this process, thus unnecessary. | |||
== Output properties == | == Output properties == | ||
Line 96: | Line 97: | ||
| InvalidApplePayMessage|| The provided message is invalid. | | InvalidApplePayMessage|| The provided message is invalid. | ||
|- | |- | ||
| ApplePayNotAllowed|| Apple Pay not allowed for token payments | | ApplePayNotAllowed|| Apple Pay not allowed for token payments. | ||
|- | |- | ||
| NotRegisteredToApple|| The provided shop url is not registered to Apple. | | NotRegisteredToApple|| The provided shop url is not registered to Apple. | ||
|- | |- | ||
|} | |} |
Latest revision as of 15:43, 2 February 2022
Barion API: Start Payment With Apple token
POST | /v2/ApplePay/StartPaymentWithAppleToken |
---|
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. |
ShippingContact | ShippingContact | * Required | The shipping information of the payer provided by Apple |
BillingContact | BillingContact | * Required | The billing information of the payer provided by Apple |
ApplePayToken | Token | * Required | The Token provided by Apple in onpaymentauthorized callback. |
PaymentType | string |
|
The type of payment, which can be either immediate or a money reservation. Reservation means that the shop has a time window to finish the payment (even though the money transaction still takes place immediately). Reservation amounts can be modified during this time window unless the new amount is lower than the original.
Click here to learn more about reservation payments: Reservation payments, and delayed capture: Delayed capture. |
ReservationPeriod | TimeSpan (d.hh:mm:ss) |
|
Only makes sense at reservation payments. This is the time window that allows the shop to finish (finalize) the payment. If this does not happen within the time window, the system refunds the payment amount to the payer. |
DelayedCapturePeriod | TimeSpan (d.hh:mm:ss) |
|
This is the time window that allows the shop to complete (finalize) the payment. If this does not happen within the time window, the system releases the payment amount. |
PaymentRequestId | string |
|
The unique identifier for the payment generated by the shop. This is so the shop can track its own payment identifiers. It is also useful for bookkeeping purposes since this shows up in the monthly account statement and the transaction history export, making identification of payments easier for the shop. |
CallbackUrl | string |
|
The URL where the Barion system sends a request whenever there is a change in the state of the payment. The payment identifier is added to the query string part of this URL in the paymentId parameter. Click here to learn more about the callback mechanism: Payment callback mechanism (IPN)
|
Transactions | PaymentTransaction[] |
|
An array of payment transactions contained in the payment. A payment must contain at least one such transaction. See the PaymentTransaction page for the appropriate structure and syntax.
Defining multiple transactions allow the payment initiator to distribute the payment amount between multiple shops. See the following page to learn more: Facilitated payments |
OrderNumber | string |
|
The order number generated by the shop. This is to aid the shop in identifying a given payment in its own system. This also shows up in generated monthly account statements and transaction history exports, so it also helps with bookkeeping. |
Currency | string |
Accepted values:
|
The currency of the payment. Must be supplied in ISO 4217 format. This affects all transactions included in the payment; it is not possible to define multiple transactions in different currencies. |
Note: You can pass all the properties of PaymentStart, but the rest of it is not used in this process, thus unnecessary.
Output properties
No specific output property is available, besided the generic ones.
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. |
InvalidApplePayToken | The provided token is invalid. |
InvalidApplePayMessage | The provided message is invalid. |
ApplePayNotAllowed | Apple Pay not allowed for token payments. |
NotRegisteredToApple | The provided shop url is not registered to Apple. |