PurchaseEx works as Purchase with the additional parameter paymentParameters. This method should be used when overriding the configured values for selected payment methods. See Payments for more information about the checkout process.
General: 'test'=true to enable tests. When 'test' is used no payments will be processed for real. Payments may interpret supplied values such as cardNumber or ssn to simulate failures. Not implemented. Klarna: 'sessionId'=id. Used to provide a sessionId to Klarna payments. Not implemented. Payex and Dibs. Supported values are 'returnUrl' and 'cancelUrl'. Values should point to where the payment service should go in case of success/failure.
Success
Bad Request
Key: BasketItemNotBuyable. Gets raised when the basket item is not buyable or when it is inactive.
Key: BasketItemQuantityLessThanZero. Gets raised when the basket item quantity is less than zero.
Key: BuyerMissing. Gets raised when the buyer is missing.
Key: CannotCreatOrderOnBasket. Gets raised if the basket is not buyable and not already paid for.
Key: DeliveryAddressMissing. Gets raised when the delivery address does not exist.
Key: DiscountCodeAlreadyUsed. Gets raised when the discount code is already used.
Key: InvalidCompanyOnBasket. Gets raised when the basket has an invalid company. The customer does not exist in this company.
Key: InvoiceAddressMissing. Gets raised when the invoice address does not exist.
Key: NoDeliveryMethodSelected. Gets raised when there are no delivery method selected.
Key: NoPaymentMethodSelected. Gets raised when there are no payment method selected.
Key: PaymentFailed. Gets raised when the payment fails.
Key: PromotionInvalid. Gets raised when the promotion is invalid.
Key: QuotationMissing. Gets raised when the basket is missing.
Key: BasketContainsSomeUnbuyableItems. Gets raised when the basket has some unbuyable items.
Key: BasketContainsNoBuyableItems. Gets raised when the basket does not have any buyable items.
Internal Server Error
[- {
- "Name": "string",
- "Value": "string"
}
]
{- "Status": "string",
- "StatusDescription": "string",
- "BasketId": 0,
- "OrderNo": "string",
- "PaymentCode": "string",
- "PaymentReference": "string",
- "HostedPaymentPage": "string",
- "RedirectUrl": "string",
- "RedirectParameters": [
- {
- "Name": "string",
- "Value": "string"
}
], - "IsSyncronous": true,
- "PaymentServiceId": 0
}