Please wait ...


Loading...

Payment web service

Technical documentation for the payment web service

This section contains detailed descriptions of the input and output values which are used for normal payments. The web service for normal payments is found here:

https://ssl.ditonlinebetalingssystem.dk/remote/payment.asmx

How to read the documentation

Every description of a function consists of input and output fields. Input fields are used when calling the web service. Mandatory fields must be entered, while the rest can be given as empty values. The output fields are returned by the web service.

Data flow

1. When the customers enter their card information and complete a purchase, the payment in authorised. Using the authorize call, however, requires PCI certification. Instead, use our payment window. This means that we handle the authorisation.

2. Use the call capture to capture the payment. When the call is completed, your acquirer transfers the captured amount from the card holder’s account to your account.

3. If the customer returns the product, or cancels the order after the payment has been captured, you can refund the amount using the credit call. The amount goes back to the card holder's account. You can either refund the full amount or a part of the amount.

4. If the customer returns the product, or cancels the order before the payment has been captured, you can delete the payment using the delete function. The full amount is released and goes back to the card holder's account.

Data types

The web service uses objects and data types in the SOAP format. The data types are: Integer, Long, String, Enum, Boolean and Datetime. Datetime must be formatted: "yyyy-MM-dd HH:mm:ss". All functions return a boolean, indicating whether the operation was successful. If the returning value is false, the integer values epayresponse and pbsresponse must be used to determine the source of error.

capture

Input fields are the ones you send when calling the web service.

InputTypeValuesDescriptionMandatory
merchantnumberInteger7 digitsYour unique merchant number. The number is located on your agreement with the acquirer (for instance Nets) or in your Bambora administration.Yes
transactionidLong
The unique number to identify the payment returned during the authorisation.Yes
amountIntegerMinor units
The amount in minor units. DKK 125.75 must be specified as 12575 in the amount field.Yes
group
StringMax 100 characters.The group to which the payment is associated.
No
invoice
StringMax 100 characters.Send invoice data to Storebox/Kvittering.dk. Find more information here.
No

Output fields are returned by the web service.

OutputTypeValuesDescription
captureResultBooleanSee description of output values.
pbsResponseIntegerIf the capture is declined by Nets, the error code is defined in pbsresponse. If the payment is captured, the value is 0.
epayresponseIntegerIf the payment is declined by Bambora, the error code is defined in epayresponse.
Output valuesIf the capture is approved, captureResult will return true. Otherwise the returning value is false. If the function call returns false, epayresponse and pbsresponse must be used to determine the source of error.

credit

Input fields are the ones you send when calling the web service.

InputTypeValuesDescriptionMandatory
merchantnumberInteger7 digitsYour unique merchant number. The number is located on your agreement with the acquirer or in your Bambora administration.Yes
transactionidLong
The unique number to identify the payment returned during the authorisation.Yes
amountIntegerMinor units
The amount in minor units. E.g. DKK 125.75 must be specified as 12575 in the amount field.Yes
group
StringMax. 100 characters.The group to which the payment is associated.
No
invoice
StringMax 100 characters.Send invoice data to Storebox/Kvittering.dk. Find more information here.
No

Output fields are returned by the web service.

OutputTypeValuesDescription
creditResultBooleanSee description of output values.
pbsResponseIntegerIf the credit call is declined by Nets, the error code is defined in pbsresponse. If the payment is credited, the value is 0.
epayresponseIntegerIf the credit call is declined by Bambora, the error code is defined in epayresponse.
Output valuesIf the credit is approved, creditResult will return true. Otherwise the returning value is false. If the function call returns false, epayresponse and pbsresponse must be used to determine the source of error.

delete

Input fields are the ones you send when calling the web service.

InputTypeValuesDescriptionMandatory
merchantnumberInteger7 digitsYour unique merchant number. The number is located on your agreement with the or in your Bambora administration.Yes
transactionidLong
The unique number to identify the payment returned during the authorisation.Yes
group
StringMax. 100 characters.The group to which the payment is associated.
No

Output fields are returned by the web service.

OutputTypeValuesDescription
deleteResultBooleanSee description of output values.
epayresponseIntegerIf the delete call is declined by Bambora, the error code is defined in epayresponse.
Output valuesIf the delete is approved, deleteResult will return true. Otherwise the returning value is false. If the function call returns false, epayresponse and pbsresponse must be used to determine the source of error.

getEpayError

Input fields are the ones you send when calling the web service.

InputTypeValuesDescriptionMandatory
merchantnumberInteger7 digitsYour unique merchant number. The number is located on your agreement with the acquirer or in your Bambora administration.Yes
languageInteger1The language in which the result is returned
(1) for Danish 
(2) for English
(3) for Swedish
Yes
epayresponsecode
String
Error code received from Bambora in epayresponse.
No

Output fields are returned by the web service.

OutputTypeValuesDescription
getEpayErrorResultBooleanSee description of output values.
epayResponseStringStringThe error returned as a string from Bambora.
epayresponseIntegerIf the payment is declined by Bambora, the error code is defined in epayresponse.
Output valuesIf it is possible to retrieve information about the error code, getEpayErrorResult will return true. Otherwise the returning value is false. If the call returns false, epayresponse must be used to determine the source of error.

getPbsError

Input fields are the ones you send when calling the web service.

InputTypeValuesDescriptionMandatory
merchantnumberInteger7 digitsYour unique merchant number. The number is located on your agreement with the acquirer or in your Bambora administration.Yes
languageInteger1The language in which the result is returned
(1) for Danish 
(2) for English
(3) for Swedish
Yes
pbsresonsecode
Integer
Error code received from Nets in pbsresponse.
No

Output fields are returned by the web service.

OutputTypeValuesDescription
getPbsErrorResultBooleanSee description of output values.
pbsResponseString
StringThe error returned as string from Bambora.
epayresponseIntegerIf the payment is declined by Bambora, the error code is defined in epayresponse.
Output valuesIf it is possible to retrieve information about the error code, getPbsErrorResult will return true. Otherwise the returning value is false. If the call returns false, epayresponse must be used to determine the source of error.

getcardtype

Input fields are the ones you send when calling the web service.

InputTypeValuesDescriptionMandatory
merchantnumberInteger7 digitsYour unique merchant number. The number is located on your agreement with the acquirer or in your Bambora administration.Yes
cardnumberStringMax 20 charactersThe unique number to identify the payment returned during the authorisation.Yes

Output fields are returned by the web service.

OutputTypeValuesDescription
getcardtypeResultBooleanSee description of output values.
cardtypeidIntegerThe card type as an Integer.
cardnameStringThe name of the card type (e.g. DANKORT).
epayresponseIntegerIf the payment is declined by Bambora, the error code is defined in epayresponse.
Output valuesIf it is possible to return information about the card, getcardtypeResult is true. Otherwise the value is false. If the call returns false, epayresponse must be used to determine the source of error.

gettransaction

Input fields are the ones you send when calling the web service.

InputTypeValuesDescriptionMandatory
merchantnumberInteger7 digitsYour unique merchant number. The number is located on your agreement with the acquirer or in your Bambora administration.
Yes
transactionidLongMax 50 charactersThe unique number to identify the payment returned during the authorisation.
Yes

Output fields are returned by the web service.

OutputTypeValuesDescription
groupStringGroup (if defined).
authamountIntegerThe amount authorised on the card holder's payment card.
currencyIntegerCurrency of the authorisation.
cardtypeidIntegerCardtype of the payment card used.
capturedamountIntegerAmount captured.
creditedamountIntegerAmount credited.
orderidStringOrder number
descriptionStringDescription (If defined)
authdateDatetimeDate of the authorisation.
captureddateDatetimeDate of the capture.
deleteddateDatetimeDate of the deletion.
crediteddateDatetimeDate of the credit.
statusEnum

0 = PAYMENT_UNDEFINED
1 = PAYMENT_NEW
2 = PAYMENT_CAPTURED
3 = PAYMENT_DELETED
4 = PAYMENT_INSTANT_CAPTURE_FAILED
5 = PAYMENT_SUBSCRIPTION_INI
6 = PAYMENT_RENEW
7 = PAYMENT_EUROLINE_WAIT_CAPTURE
8 = PAYMENT_EUROLINE_WAIT_CREDIT

Status of the payment.

Per default,

the status is PAYMENT_NEW.

PAYMENT_EUROLINE_WAIT_CAPTURE status:

The transaction is captured at Bambora and being processed by the

acquirer;

this is done overnight by batch processing.

PAYMENT_EUROLINE_WAIT_CREDIT status:

The transaction is credited at Bambora and being processed by the

acquirer;

this is done overnight by batch processing.

When the payment is captured, the status is PAYMENT_CAPTURED.

[history] list start

transactionHistoryIDLongUnique ID for the history.
logonIDIntegerUnique ID for the user who performed the operation.
eventMsgStringDescription of the operation.
createdDatetimeTimestamp of the operation.
[history] list end

transactionidLongThe payment is identified by this number which is returned during authorisation.
cardholderStringName of the card holder (if defined).
modeEnumPayment type: test or production.
epayresponseIntegerIf the payment is declined by Bambora, the error code is defined in epayresponse.
Output values

If it is possible to retrieve information about the payment, the function will return true.

Otherwise the returning value is false.

As the returning value is false, epayresponse is used to determine the source of error.

gettransactionlist

Input fields are the ones you send when calling the web service.

InputTypeValuesDescriptionManda-
tory
merchantnumberInteger7 digitsYour unique merchant number. The number is located on your agreement with the acquirer or in your Bambora administration.Yes
statusEnum0 = PAYMENT_UNDEFINED
1 = PAYMENT_NEW
2 = PAYMENT_CAPTURED
3 = PAYMENT_DELETED
4 = PAYMENT_INSTANT_CAPTURE_FAILED
5 = PAYMENT_SUBSCRIPTION_INI
6 = PAYMENT_RENEW
7 = PAYMENT_EUROLINE_WAIT_CAPTURE
8 = PAYMENT_EUROLINE_WAIT_CREDIT
Status of the payment. Per default, the status is PAYMENT_NEW.
PAYMENT_EUROLINE_WAIT_CAPTURE status: The transaction is captured at Bambora and being processed by the acquirer; this is done overnight by batch processing.
PAYMENT_EUROLINE_WAIT_CREDIT status: The transaction is credited at Bambora and being processed by the acquirer; this is done overnight by batch processing.
When the payment is captured, the status is PAYMENT_CAPTURED.
No
searchdatestartDatetimeNull (nothing) - and it is ignored.Start date (defined as: "yyyy-MM-dd TT:mm:ss").No
searchdateend
DatetimeNull (nothing) - and it is ignored.End date (defined as: "yyyy-MM-dd TT:mm:ss").No
searchgroup
StringMax 100 characters.Search for payments in a defined group (allowed empty).
No
searchorderid
StringMax 20 characters.Search for payments by order number (allowed empty).
No

Output fields are returned by the web service.

OutputTypeValuesDescription
Output valuesSee the result in gettransaction. The values are the same. However, they are enclosed in transactionInformationAry, which is an array of the type TransactionInformationType

See specifications here: gettransaction.

getcardinfo

Input fields are the ones you send when calling the web service.

InputTypeValuesDescriptionMandatory
merchantnumberInteger7 digitsYour unique merchant number. The number is located on your agreement with the acquirer or in your Bambora administration.
Yes
cardno_prefixInteger6 digitsPrefix on the payment card from which the fee is calculated. It is important that only the first six digits are defined - otherwise the system will reject the call.

Note that Danske Bank, Nordea must use the prefixes below: 

000022 eller 000023 = Danske Bank Netbetaling

000021 = Nordea e-betaling


Yes
amountIntegerMinor unitsThe amount in minor units. For instance, DKK 125.75 must be specified as 12575 in the amount field.Yes
currency
Integer208 = DKK 
978 = EUR 
840 = USD 
578 = NOK 
752 = SEK 
826 = GBP
The currency of the payment. If the customer must be settled in Danish kroner, then put the value at 208. For a complete list of currency codes, please click here.
Yes
acquirerInteger

Nets/Teller = 1
Euroline = 2
BABS Swedbank = 8
Nordea SE = 21
Handelsbanken SE = 23
Elavon = 24
EVRY Swedbank = 25
EVRY Bambora = 26
EVRY Teller = 27
Nordea DK = 29
Nordea NO = 30
Nordea FI = 31
Handelsbanken DK = 32
Handelsbanken NO = 33
Handelsbanken FI = 34
Clearhaus = 37

The acquirer which handles the transaction.No

Output fields are returned by the web service.

OutputTypeValuesDescription
feeIntegerMinor unitsThe transaction fee is calculated based on the value of the input fields amount, currency, and acquirer.
cardtypeInteger

1 = Dankort

2 = Visa/Dankort

3 = Visa/Electron (foreign)

4 = Mastercard

5 = Mastercard (foreign)

6 = Visa Electron

7 = JCB

8 = Diners Club

9 = Maestro

10 = America Express

11 = Ukendt

13 = Diners Club (foreign)

14 = American Expres (foreign)

15 = Maestro (foreign)

16 = Forbrugsforeningen

17 = ewire

18 = Visa

19 = IKANO

20 = Andre

21 = Nordea e-betaling

22 = Danske Netbetaling

23 = BG Netbetalinger

24 = MasterCard

25 = MasterCard (foreign)

26 = PayPal

27 = Mobilpenge

28 = Klarna

29 = Svea

30 = SEB Direktbetalning

31 = Nordea SE e-payment

32 = Handelsbanken SE e-payment

33 = Swedbank Direktbetalning

34 = ViaBill

35 = Beeptify

36 = iDeal

37 = Oberthur

38 = Paii

39 = Brandts

40 = MobilePay

41 = Resurs

42 = Ekspres Bank

Type of credit card used for the payment.
cardtypetextStringType of card in a reader-friendly format.
epayresponseIntegerIf Bambora declines the call to the API (the value returned is false), you can find the source of error in this parameter. For a full list of error codes, go to your Bambora administration in the menu Support -> System error codes.

Troubleshooting

All deviations from the system are stored in a separate log at Bambora's which is accessed from the Bambora administration. If you experience problems when calling the web service, information for troubleshooting (debugging) is available in this log.

The log is located in your Bambora administration in the menu API/Web services -> Remote log. All error codes are available in Support -> System error codes and Support -> Error codes from PBS.