Paying for an Order
is in most cases a two step process:
To list the available payment methods for the current order the GetAvailablePaymentMethodsService
should be called. It returns an array of available payment codes.
To create a new payment the CreatePaymentService
should be called:
{
int OrderID
string Code //PaymentMethod code
decimal Amount //Optional amount to pay, if not set the open amount will be used
object Properties //Payment method specific properties
}
Response
{
PaymentTransactionDto PaymentTransaction
decimal OpenAmount
object Properties
}
For a couple of payment methods there are specific request and/or response properties. These are defined below.
The harmony credit payment is used to pay for an order with a Waardebrief
. The ReferenceNumber
and PolicyNumber
are used to validate the payment against Harmony.
RequestProperties
{
string ReferenceNumber
string PolicyNumber
}
ResultProperties
{}
This payment method is used to pay with a giftcard from Intersolve. If a Pin
is provided on the card, it is required for the validation. If the payment fails the result message is available on the Message
property.
RequestProperties
{
string CardNumber
string Pin
}
ResultProperties
{
bool Success
string Message
}
The MediaMarkt payment method is only available in the MediaMarkt application. It will always pay the complete order.
RequestProperties
{}
ResultProperties
{}
This payment method provides support for ideal, paypal and creditcard payments.
TODO: add some docs for ideal/creditcard
RequestProperties
{
string PaymentBrand // AMEX/MAESTRO/MASTER/VISA/VPAY/IDEAL/PAYPAL
object Card {
string Holder
string Number
string ExpiryMonth
string ExpiryYear
string CVV
}
object VirtualAccount { //Username/password for PayPal
string AccountID
string Password
}
object BankAccount {
string Holder
string BankName
string Number
string IBAN
string BankCode
string BIC
string Counrty
string MandateID
DateTime MandateDateOfSignature
DateTime DueDate
}
string ReturlUrl //Url to redirect the user after the payment
}
ResultProperties
{
string AcapturePaymentID
string RedirectUrl
string[] RedirectParameters
bool Success
string ResultCode
string ResultDescription
}
In a store the payment method Cash can be used. The AmountGiven
is the exact amount given by the customer. The API will calculate the rounding and the amount to return to the customer. If the payment is a return, the AmountGiven
is 0
.
RequestProperties
{
decimal AmountGiven //Amount given by the customer
int StationID
}
ResultProperties
{
decimal RawReturnAmount
decimal RoundedReturnAmount //Exact amount to give back to the customer
}
Manual payments are only available for Debtors.
RequestProperties
{}
ResultProperties
{}
When a customer has an EVA usercard available, it can be used to pay for an order. The cards can be listed with the GetUserCardsForUserService
.
A UserCard payment will be created as a pending payment and needs to be finalized with the FinalizePaymentService
.
RequestProperties
{
int UserID
int UserCardID
}
ResultProperties
{}
RequestProperties
{}
ResultProperties
{}
RequestProperties
{}
ResultProperties
{}