paydirekt

REST API & Wirecard Payment Page v1

paydirekt is a type of Online Bank Transfer.

Countries and Currencies

Countries

Germany

Currencies

EUR

Communication Formats

This table illustrates how paydirekt notifications are encoded and which formats and methods can be used for requests and responses.

Requests/Responses

Format

XML

Methods

POST, GET

IPN Encodement

Base64

Transaction Types

For transaction type details look at Transaction Types.

Transaction Type Link to the Sample

authorization

authorization samples

capture-authorization

capture samples

debit

debit samples

refund-request

refund-request samples

Test Credentials

URLs (Endpoints)

For transaction types authorization and debit

https://api-test.wirecard.com/engine/rest/paymentmethods/

For transaction types capture and refund-request

https://api-test.wirecard.com/engine/rest/payments/

Merchant Account ID (MAID)

c7f465c6-7982-4a58-a878-66265e75db50

Username

16390-testing

Password

3!3013=D3fD8X7

Secret Key

30520cf9-8f5b-4b0b-9430-58a1223b79dc

On paydirekt Environment

login

WirecardPDExpress2

password

WirecardPDExpress22$

Workflow
paydirekt Workflow
  1. Consumer selects paydirekt.

  2. Merchant sends a payment request to WPG.

  3. WPG forwards the payment request to paydirekt.

  4. paydirekt initializes payment.

  5. paydirekt sends payment result to WPG.

  6. WPG sends redirect URL to merchant.

  7. Merchant forwards redirect URL to consumer.

  8. Consumer authorizes the transaction in paydirekt account.

  9. paydirekt processes the transaction.

  10. paydirekt sends success result to WPG.

  11. WPG forwards success result to merchant and sends consumer data to paydirekt.

  12. Merchant redirects consumer to success landing page.

  13. Consumer receives the successful result from merchant.

  14. paydirekt collects amount from consumer’s account.

Fields

The following elements are mandatory M, optional O or conditional C for a request/response/notification. If the respective cell is empty, the field is disregarded or not sent.

authorization
Term Request Response Notification Type Size Description

merchant-account-id

M

M

M

String

36

Unique identifier for a merchant account.

transaction-id

M

M

36

The Transaction ID is the unique identifier for a transaction. It is generated by Wirecard.

request-id

M

M

M

String

36

This is the identification number of the request. It has to be unique for each request.

transaction-type

M

M

M

String

22

This is the type for a transaction. Must be authorization.

payment-methods/payment-method[@name]

M

M

M

String

9

The name of the Payment Method is paydirekt. Must be paydirekt.

payment-methods/payment-method[@url]

M

String

paydirekt url where the consumer is going to be redirected in order to confirm the payment.

api-id

O

O

M

String

requested-amount

M

M

M

Decimal

7,2

This is the amount of the transaction. The amount of the decimal place is dependent of the currency. Minimum is 0.01. Maximum is 50000.

requested-amount[@currency]

M

M

M

String

3

paydirekt supports only EUR currency. Must be EUR.

order-number

M

M

M

String

20

The order number from the merchant.

order-items

O

O

O

order-item[]

Basket items details

order-items/order-item

O

O

O

order-item

Basket item detail

order-items/order-item/name

M

M

M

String

256

Basket item name. Mandatory for each instance of order-item.

order-items/order-item/quantity

M

M

M

Number

Basket item quantity. Should be greater than zero. Mandatory for each instance of order-item.

order-items/order-item/amount

M

M

M

Decimal

12,3

Basket item amount. Mandatory for each instance of order-item.

order-items/order-item/amount[@currency]

M

M

M

String

3

Basket item amount currency, must be EUR.

order-items/order-item/article-number

O

O

O

String

Article number

order-items/order-item/tax-rate

O

O

O

String

Tax rate

shipping

M

M

M

Shipping

Shipping details

Only mandatory for non-express payment! In case of express, shipping data shall not be set.

shipping/first-name

M

M

M

String

32

Consumer’s first name

shipping/last-name

M

M

M

String

32

Consumer’s last name

shipping/address

M

M

M

Address

Consumer’s shipping address details

shipping/address/street1

M

M

M

String

70

Consumer’s shipping address street 1

shipping/address/city

M

M

M

String

32

Consumer’s shipping address city

shipping/address/country

M

M

M

String

3

Consumer’s shipping address country

shipping/address/postal-code

M

M

M

String

16

Consumer’s shipping address zip code

transaction-state

M

M

String

7

Transaction result status. Should be success or cancel or failed.

Statuses/status[@code]

M

M

String

Transaction status code, e.g. 201.0000.

statuses/status[@description]

M

M

String

Transaction status description

statuses/status[@severity]

M

M

String

Transaction status severity. Should be information for successful transactions, error for failed transactions.

completion-time-stamp

M

M

Date time

Timestamp of the transaction

debit
Term Request Response Notification Type Size Description

merchant-account-id

M

M

M

String

36

Unique identifier for a merchant account.

transaction-id

M

M

String

36

The Transaction ID is the unique identifier for a transaction. It is generated by Wirecard.

request-id

M

M

M

String

36

This is the identification number of the request. It has to be unique for each request.

transaction-type

M

M

M

String

22

This is the type for a transaction. Must be debit.

payment-methods/payment-method[@name]

M

M

M

String

9

The name of the Payment Method is paydirekt. Must be paydirekt.

payment-methods/payment-method[@url]

M

String

paydirekt url where the consumer is going to be redirected in order to confirm the payment.

api-id

O

O

M

String

requested-amount

M

M

M

Decimal

7,2

This is the amount of the transaction. The amount of the decimal place is dependent of the currency. Minimum is 0.01. Maximum is 50000.

requested-amount[@currency]

M

M

M

String

3

paydirekt supports only EUR currency. Must be EUR.

order-number

M

M

M

String

20

The order number from the merchant.

order-items

O

O

O

order-item[]

Basket items details

order-items/order-item

O

O

O

order-item

Basket item detail

order-items/order-item/name

M

M

M

String

256

Basket item name. Mandatory for each instance of order-item.

order-items/order-item/quantity

M

M

M

Number

Basket item quantity. Should be greater than zero. Mandatory for each instance of order-item.

order-items/order-item/amount

M

M

M

Decimal

12,3

Basket item amount. Mandatory for each instance of order-item.

order-items/order-item/amount[@currency]

M

M

M

String

3

Basket item amount currency, must be EUR.

order-items/order-item/article-number

O

O

O

String

Article number

order-items/order-item/tax-rate

O

O

O

String

Tax rate

shipping

M

M

M

Shipping

Shipping details

Only mandatory for non-express payment! In case of express, shipping data shall not be set.

shipping/first-name

M

M

M

String

32

Consumer’s first name

shipping/last-name

M

M

M

String

32

Consumer’s last name

shipping/address

M

M

M

Address

Consumer’s shipping address details

shipping/address/street1

M

M

M

String

70

Consumer’s shipping address street 1

shipping/address/city

M

M

M

String

32

Consumer’s shipping address city

shipping/address/country

M

M

M

String

3

Consumer’s shipping address country

shipping/address/postal-code

M

M

String

16

Consumer’s shipping address zip code

transaction-state

M

M

String

7

Transaction result status. Should be success or cancel or failed.

Statuses/status[@code]

M

M

String

Transaction status code, e.g. 201.0000.

statuses/status[@description]

M

M

String

Transaction status description

statuses/status[@severity]

M

M

String

Transaction status severity. Should be information for successful transactions, error for failed transactions.

completion-time-stamp

M

M

Date time

Timestamp of the transaction

capture-authorization & refund-capture & refund-debit
Term Request Response Notification Type Size Description

merchant-account-id

M

M

M

String

36

Unique identifier for a merchant account.

transaction-id

M

M

36

The Transaction ID is the unique identifier for a transaction. It is generated by Wirecard.

parent-transaction-id

M

M

String

36

request-id

M

M

M

String

36

This is the identification number of the request. It has to be unique for each request.

transaction-type

M

M

M

String

22

This is the type for a transaction. Must be capture-authorization or refund-request.

payment-methods/payment-method[@name]

M

M

M

String

9

The name of the Payment Method is paydirekt. Must be paydirekt.

api-id

O

M

M

String

requested-amount

M

M

M

Decimal

7,2

This is the amount of the transaction.

The amount of the decimal place is dependent of the currency. Minimum is 0.01. Maximum is 50000.

requested-amount[@currency]

M

M

M

String

3

paydirekt supports only EUR currency. Must be EUR.

order-number

M

M

String

20

The order number from the merchant.

order-items

O

O

order-item

Basket items details. Present if exists for parent transaction.

order-items/order-item

O

O

order-item

Basket item detail. Present if exists for parent transaction.

order-items/order-item/name

M

M

String

256

Basket item name. Mandatory for each instance of order-item.

order-items/order-item/quantity

M

M

Number

Basket item quantity. Should be greater than zero. Mandatory for each instance of order-item.

order-items/order-item/amount

M

M

Decimal

12,3

Basket item amount. Mandatory for each instance of order-item.

order-items/order-item/amount[@currency]

M

M

String

3

Basket item amount currency, Must be EUR.

order-items/order-item/article-number

O

O

String

Article number

order-items/order-item/tax-rate

O

O

String

Tax rate

shipping

M

M

Shipping

Shipping details

Only mandatory for non-express payment! In case of express, shipping data shall not be set.

shipping/first-name

M

M

String

32

Consumer’s first name

shipping/last-name

M

M

String

32

Consumer’s last name

shipping/address

M

M

Address

Consumer’s shipping address details

shipping/address/street1

M

M

String

70

Consumer’s shipping address street 1

shipping/address/city

M

M

String

32

Consumer’s shipping address city

shipping/address/country

M

M

String

3

Consumer’s shipping address country

shipping/address/postal-code

M

M

String

16

Consumer’s shipping address zip code

transaction-state

M

M

String

7

Transaction result status. Should be success or cancel or failed.

Statuses/status[@code]

M

M

String

Transaction status code, e.g. 201.0000.

statuses/status[@description]

M

M

String

Transaction status description

statuses/status[@severity]

M

M

String

Transaction status severity. Should be information for successful transactions, error for failed transactions.

completion-time-stamp

M

M

Date time

Timestamp of the capture/refund transaction

custom-fields/custom-field[@field-name='finalCapture'][@field-value]

O

O

O

Boolean

Final capture flag. If set to true the final capture will be created and no further capture will be possible.

Features
EXPRESS Checkout
Test Credentials

URLs (Endpoints)

For transaction types authorization and debit.

https://api-test.wirecard.com/engine/rest/paymentmethods/

Merchant Account ID (MAID)

068793d9-3f5b-4028-89b8-00e26a8c540d

Merchant Account Name

paydirekt Express Test Merchant

Username

16390-testing

Password

3!3013=D3fD8X7

Secret Key

e39945d1-9f42-4f3e-b873-09201d7cc95e

On paydirekt Environment

Login

WirecardPDExpress2

Password

WirecardPDExpress22$

Description

paydirekt Express enables payments to be made, with the shipping address being returned to the merchant. In this way, a purchase can be made without consumers having to enter their address on the merchant website or having to create a consumer account. To complete the payment and conclusively confirm it, the execute link must be called up after the consumer confirmation in the paydirekt system. Here, the consumer is typically redirected back to the shop and prompted to confirm the merchant’s general terms & conditions of business.

Configuration
There is no special flag to mark "Express" Checkout, this depends on merchant’s configuration.
paydirekt Express Checkout Workflow
Process Flow
  1. Consumer: Clicks EXPRESS Checkout Button in the Shop.

  2. Shop-System: Calls the checkout endpoint and submits all relevant order data to paydirekt.
    paydirekt: Returns the approve" link (paydirekt payment page) in the API Response.

  3. Shop-System: Redirects the Consumer to the approve link (paydirekt payment page).

  4. Consumer: Logs into his paydirekt account on the paydirekt payment page.

  5. paydirekt: Calls the shop-system’s callbackUrlCheckDestinations endpoint (the shop-system must provide this callback) after the consumer logs in and the shop-system provides all addresses available in the consumer’s paydirekt account in that call.
    Shop-System: Uses the addresses submitted from paydirekt and decides which addresses are allowed as invoice and/or delivery address. Furthermore the shop system needs to add the shipping options for each address and return this in the answer to the callback call.

  6. paydirekt: Displays the default addresses on the payment page (those addresses used most often by the consumer) along with the shipping options (that paydirekt received in step 5).

  7. Consumer: Chooses one of the shipping addresses. Alternatively, the consumer can choose any other address available in his/her paydirekt account (they all have shipping options associated due to the callback). The consumer may also add a new address. If the consumer adds a new address, a callback is issued similar to step 5, sending the new address to the merchant. Handling is the same as in step 5.
    paydirekt: While the consumer chooses a shipping option on the payment page, Wirecard recalculates/updates the totalAmount in the shopping cart.

  8. Consumer: Consumer clicks on the Jetzt kaufen link on the payment page.

  9. paydirekt: Redirects the user back to the shop (using the provided redirect URLS) depending on the status of the Directsale/Order actions.

  10. Shop-System: Queries (GET) the checkout. The checkout now contains the addresses the consumer selected along with the shipping options. The shop-system now has all relevant data.

  11. Shop-System: Shows the Final Order screen and Order Confirmation button (along with the data from step 10).

  12. Consumer: Clicks the Order Confirmation button

  13. Shop-System: Internally flags/stores the order as confirmed AND sends the execute request to paydirekt (for initiating all payment processes = getting the money).
    paydirekt: Will return the status of the execute call.

  14. Shop-System: Depending on the Status of Step 13:

    1. Show the "thank you page" and stores the payment information to the order. Or

    2. In case of an error, most likely presents the consumer with a page to choose a different payment method.

Samples

Go to Notification Examples, if you want to see corresponding notification samples.

authorization
authorization Request (Successful)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment">
    <merchant-account-id>c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <request-id>{{$guid}}</request-id>
    <transaction-type>authorization</transaction-type>
    <payment-methods>
        <payment-method name="paydirekt" />
    </payment-methods>
    <requested-amount currency="EUR">5.00</requested-amount>
    <order-number>180606120514730</order-number>
    <shipping>
        <first-name>John</first-name>
        <last-name>Doe</last-name>
        <address>
            <street1>Mullerstrase 16</street1>
            <city>Berlin</city>
            <postal-code>00010</postal-code>
            <country>DE</country>
        </address>
    </shipping>
 </payment>
authorization Response (Successful)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment" xmlns:ns2="http://www.elastic-payments.com/schema/epa/transaction">
    <merchant-account-id>c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <transaction-id>219166b2-d71d-4f05-b332-d87720929007</transaction-id>
    <request-id>c274df92-81a7-47e4-a1ee-7a6cc4285584</request-id>
    <transaction-type>authorization</transaction-type>
    <transaction-state>success</transaction-state>
    <completion-time-stamp>2018-06-06T10:05:15.000Z</completion-time-stamp>
    <statuses>
        <status code="201.0000" description="The resource was successfully created." severity="information" />
    </statuses>
    <requested-amount currency="EUR">5.00</requested-amount>
    <shipping>
        <first-name>John</first-name>
        <last-name>Doe</last-name>
        <address>
            <street1>Mullerstrase 16</street1>
            <city>Berlin</city>
            <country>DE</country>
            <postal-code>00010</postal-code>
        </address>
    </shipping>
    <order-number>180606120514730</order-number>
    <payment-methods>
        <payment-method url="https://sandbox.paydirekt.de/checkout/#/checkout/c092a6a6-c130-4fab-930c-c6a07eab66c9" name="paydirekt" />
    </payment-methods>
</payment>
In the following failure samples the failure is caused by a difference between requested amount and the total amount of the merchandise in the cart.
authorization Request (Failed)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment">
    <merchant-account-id>c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <request-id>{{$guid}}</request-id>
    <transaction-type>authorization</transaction-type>
    <payment-methods>
        <payment-method name="paydirekt" />
    </payment-methods>
    <requested-amount currency="EUR">250.60</requested-amount>
    <order-number>180606130133148</order-number>
    <order-items>
        <order-item>
            <name>Bobbycar</name>
            <article-number>800001303</article-number>
            <amount currency="EUR">25.99</amount>
            <quantity>3</quantity>
        </order-item>
        <order-item>
            <name>John</name>
            <article-number>800001304</article-number>
            <amount currency="EUR">22.03</amount>
            <quantity>1</quantity>
        </order-item>
    </order-items>
    <shipping>
        <first-name>Jane</first-name>
        <last-name>Doe</last-name>
        <address>
            <street1>Packstation 999</street1>
            <city>Schwaig</city>
            <postal-code>90402</postal-code>
            <country>DE</country>
        </address>
    </shipping>
</payment>
authorization Response (Failed)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment" xmlns:ns2="http://www.elastic-payments.com/schema/epa/transaction">
    <merchant-account-id>c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <transaction-id>d825ccbf-d58b-4790-8c3a-09718545bf0f</transaction-id>
    <request-id>9383db6a-7d3a-40ae-a541-6297362a301c</request-id>
    <transaction-type>authorization</transaction-type>
    <transaction-state>failed</transaction-state>
    <completion-time-stamp>2018-06-06T11:01:33.000Z</completion-time-stamp>
    <statuses>
        <status code="400.1186" description="Order items overall amount is different to requested amount. Please check your input and try again." severity="error" />
    </statuses>
    <requested-amount currency="EUR">250.60</requested-amount>
    <shipping>
        <first-name>Jane</first-name>
        <last-name>Doe</last-name>
        <address>
            <street1>Packstation 999</street1>
            <city>Schwaig</city>
            <country>DE</country>
            <postal-code>90402</postal-code>
        </address>
    </shipping>
    <order-number>180606130133148</order-number>
    <order-items>
        <order-item>
            <name>Bobbycar</name>
            <article-number>800001303</article-number>
            <amount currency="EUR">25.99</amount>
            <quantity>3</quantity>
        </order-item>
        <order-item>
            <name>John</name>
            <article-number>800001304</article-number>
            <amount currency="EUR">22.03</amount>
            <quantity>1</quantity>
        </order-item>
    </order-items>
    <payment-methods>
      <payment-method name="paydirekt" />
    </payment-methods>
</payment>
capture
capture-authorization Request (Successful)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment">
    <merchant-account-id>c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <request-id>{{$guid}}</request-id>
    <transaction-type>capture-authorization</transaction-type>
    <parent-transaction-id>784e748d-2a21-4212-9ab2-a82183b1cbdb</parent-transaction-id>
    <payment-methods>
        <payment-method name="paydirekt" />
    </payment-methods>
    <requested-amount currency="EUR">5.0</requested-amount>
    <custom-fields>
        <custom-field field-name="finalCapture" field-value="false" />
    </custom-fields>
</payment>
capture-authorization Response (Successful)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment" xmlns:ns2="http://www.elastic-payments.com/schema/epa/transaction" self="https://api-test.wirecard.com:443/engine/rest/merchants/c7f465c6-7982-4a58-a878-66265e75db50/payments/116ccd3b-bd76-4925-a3db-c85ec8be98bd">
    <merchant-account-id ref="https://api-test.wirecard.com:443/engine/rest/config/merchants/c7f465c6-7982-4a58-a878-66265e75db50">c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <transaction-id>116ccd3b-bd76-4925-a3db-c85ec8be98bd</transaction-id>
    <request-id>4884632c-d5ba-4315-b639-6ed58eceae0c</request-id>
    <transaction-type>capture-authorization</transaction-type>
    <transaction-state>success</transaction-state>
    <completion-time-stamp>2018-06-06T10:14:19.000Z</completion-time-stamp>
    <statuses>
        <status code="201.0000" description="paydirekt:The resource was successfully created." severity="information" />
    </statuses>
    <requested-amount currency="EUR">5.0</requested-amount>
    <parent-transaction-id>784e748d-2a21-4212-9ab2-a82183b1cbdb</parent-transaction-id>
    <shipping>
        <first-name>John</first-name>
        <last-name>Doe</last-name>
        <address>
            <street1>Mullerstrase 16</street1>
            <city>Berlin</city>
            <country>DE</country>
            <postal-code>00010</postal-code>
        </address>
    </shipping>
    <order-number>180606120514730</order-number>
    <custom-fields>
        <custom-field field-name="finalCapture" field-value="false"></custom-field>
    </custom-fields>
    <payment-methods>
        <payment-method name="paydirekt" />
    </payment-methods>
    <parent-transaction-amount currency="EUR">5.000000</parent-transaction-amount>
    <api-id>elastic-api</api-id>
</payment>
capture-authorization Request (Failed)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment">
    <merchant-account-id>c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <request-id>{{$guid}}</request-id>
    <transaction-type>capture-authorization</transaction-type>
    <parent-transaction-id>784e748d-2a21-4212-9ab2-a82183b1cbdb</parent-transaction-id>
    <payment-methods>
        <payment-method name="paydirekt" />
    </payment-methods>
    <requested-amount currency="EUR">100.00</requested-amount>
    <custom-fields>
        <custom-field field-name="finalCapture" field-value="false" />
    </custom-fields>
</payment>
capture-authorization Response (Failed)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment" xmlns:ns2="http://www.elastic-payments.com/schema/epa/transaction" self="https://api-test.wirecard.com:443/engine/rest/merchants/c7f465c6-7982-4a58-a878-66265e75db50/payments/efd3b24b-5b24-4822-9af6-0657915a044d">
    <merchant-account-id ref="https://api-test.wirecard.com:443/engine/rest/config/merchants/c7f465c6-7982-4a58-a878-66265e75db50">c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <transaction-id>efd3b24b-5b24-4822-9af6-0657915a044d</transaction-id>
    <request-id>5f8bf8a6-2fd9-4afc-9f75-2b93d05396e5</request-id>
    <transaction-type>capture-authorization</transaction-type>
    <transaction-state>failed</transaction-state>
    <completion-time-stamp>2018-06-06T10:12:44.000Z</completion-time-stamp>
    <statuses>
        <status code="400.1027" description="The Requested Amount exceeds the Parent Transaction Amount. Please check your input and try again." severity="error" />
    </statuses>
    <requested-amount currency="EUR">100.00</requested-amount>
    <parent-transaction-id>784e748d-2a21-4212-9ab2-a82183b1cbdb</parent-transaction-id>
    <shipping>
        <first-name>John</first-name>
        <last-name>Doe</last-name>
        <address>
            <street1>Mullerstrase 16</street1>
            <city>Berlin</city>
            <country>DE</country>
            <postal-code>00010</postal-code>
        </address>
    </shipping>
    <order-number>180606120514730</order-number>
    <custom-fields>
        <custom-field field-name="finalCapture" field-value="false"></custom-field>
    </custom-fields>
    <payment-methods>
        <payment-method name="paydirekt" />
    </payment-methods>
    <parent-transaction-amount currency="EUR">5.000000</parent-transaction-amount>
    <api-id>elastic-api</api-id>
</payment>
debit
debit Request (Successful)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment">
    <merchant-account-id>c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <request-id>{{$guid}}</request-id>
    <transaction-type>debit</transaction-type>
    <payment-methods>
        <payment-method name="paydirekt" />
    </payment-methods>
    <requested-amount currency="EUR">5.00</requested-amount>
    <order-number>180606130313945</order-number>
    <shipping>
        <first-name>John</first-name>
        <last-name>Doe</last-name>
        <address>
            <street1>Mullerstrase 16</street1>
            <city>Berlin</city>
            <postal-code>00010</postal-code>
            <country>DE</country>
        </address>
    </shipping>
</payment>
debit Response (Successful)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment" xmlns:ns2="http://www.elastic-payments.com/schema/epa/transaction">
    <merchant-account-id>c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <transaction-id>36309bca-edcb-4164-a15f-d7a0707b7d58</transaction-id>
    <request-id>c22b861d-4773-4ab2-9502-6b108e93a0d9</request-id>
    <transaction-type>debit</transaction-type>
    <transaction-state>success</transaction-state>
    <completion-time-stamp>2018-06-06T11:03:14.000Z</completion-time-stamp>
    <statuses>
        <status code="201.0000" description="The resource was successfully created." severity="information" />
    </statuses>
    <requested-amount currency="EUR">5.00</requested-amount>
    <shipping>
        <first-name>John</first-name>
        <last-name>Doe</last-name>
        <address>
            <street1>Mullerstrase 16</street1>
            <city>Berlin</city>
            <country>DE</country>
            <postal-code>00010</postal-code>
        </address>
    </shipping>
    <order-number>180606130313945</order-number>
    <payment-methods>
        <payment-method url="https://sandbox.paydirekt.de/checkout/#/checkout/ec40032d-d7f1-4922-947f-07e6c60f74dc" name="paydirekt" />
    </payment-methods>
</payment>
debit EXPRESS Checkout
debit Request (Express Checkout)
<?xml version="1.0" encoding="utf-8"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment">
    <merchant-account-id>068793d9-3f5b-4028-89b8-00e26a8c540d</merchant-account-id>
    <request-id>{{$guid}}</request-id>
    <transaction-type>debit</transaction-type>
    <payment-methods>
        <payment-method name="paydirekt" />
    </payment-methods>
    <requested-amount currency="EUR">10.00</requested-amount>
    <order-number>180618135629929</order-number>
    <order-items>
        <order-item>
            <name>Bobbycar</name>
            <article-number>800001303</article-number>
            <amount currency="EUR">2.50</amount>
            <quantity>3</quantity>
        </order-item>
        <order-item>
            <name>Helmet</name>
            <amount currency="EUR">2.50</amount>
            <quantity>1</quantity>
        </order-item>
    </order-items>
</payment>
debit Response (Express Checkout)
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment" xmlns:ns2="http://www.elastic-payments.com/schema/epa/transaction">
    <merchant-account-id>068793d9-3f5b-4028-89b8-00e26a8c540d</merchant-account-id>
    <transaction-id>a40a0951-9245-4046-9500-8b4cca1bb865</transaction-id>
    <request-id>a8707525-088d-4cbd-ab14-a7990188796a</request-id>
    <transaction-type>debit</transaction-type>
    <transaction-state>success</transaction-state>
    <completion-time-stamp>2018-06-18T11:56:30.000Z</completion-time-stamp>
    <statuses>
        <status code="201.0000" description="The resource was successfully created." severity="information" />
    </statuses>
    <requested-amount currency="EUR">10.00</requested-amount>
    <order-number>180618135629929</order-number>
    <order-items>
        <order-item>
            <name>Bobbycar</name>
            <article-number>800001303</article-number>
            <amount currency="EUR">2.50</amount>
            <quantity>3</quantity>
        </order-item>
        <order-item>
            <name>Helmet</name>
            <amount currency="EUR">2.50</amount>
            <quantity>1</quantity>
        </order-item>
    </order-items>
    <payment-methods>
        <payment-method url="https://sandbox.paydirekt.de/checkout/#/checkout/c615db87-a8e4-4c79-82f8-9e807cc3df2f" name="paydirekt" />
    </payment-methods>
</payment>
An Express Checkout request is a regular request (e.g. a regular debit) which does not include the shipping element or account-holder element. The payment response is a normal response with an 'approve' link.

The information about the Express Checkout transaction is available in the response as soon as the consumer

  1. has chosen the shipping/billing addresses.

  2. has finalized the payment.

  3. has clicked on the 'approve' link.

refund-request
refund-request Request
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<payment xmlns="http://www.elastic-payments.com/schema/payment">
    <merchant-account-id>c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <request-id>{{$guid}}</request-id>
    <transaction-type>refund-request</transaction-type>
    <parent-transaction-id>116ccd3b-bd76-4925-a3db-c85ec8be98bd</parent-transaction-id>
    <payment-methods>
        <payment-method name="paydirekt" />
    </payment-methods>
    <requested-amount currency="EUR">5.00</requested-amount>
</payment>
refund-request Response
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<payment xmlns="http://www.elastic-payments.com/schema/payment" self="https://api-test.wirecard.com:443/engine/rest/merchants/c7f465c6-7982-4a58-a878-66265e75db50/payments/d96a9499-8dea-4eba-8ba1-0dcd705c3580">
    <merchant-account-id ref="https://api-test.wirecard.com:443/engine/rest/config/merchants/c7f465c6-7982-4a58-a878-66265e75db50">c7f465c6-7982-4a58-a878-66265e75db50</merchant-account-id>
    <transaction-id>d96a9499-8dea-4eba-8ba1-0dcd705c3580</transaction-id>
    <request-id>c6ca1856-52b7-49cc-837b-272ee8ba9f57-refund-request</request-id>
    <transaction-type>refund-request</transaction-type>
    <transaction-state>success</transaction-state>
    <completion-time-stamp>2019-11-06T08:34:19.000Z</completion-time-stamp>
    <statuses>
        <status code="201.0000" description="paydirekt:The resource was successfully created." severity="information"/>
    </statuses>
    <requested-amount currency="EUR">5.00</requested-amount>
    <parent-transaction-id>116ccd3b-bd76-4925-a3db-c85ec8be98bd</parent-transaction-id>
    <shipping>
        <first-name>John</first-name>
        <last-name>Doe</last-name>
        <address>
            <street1>Mullerstrase 16</street1>
            <city>Berlin</city>
            <country>DE</country>
            <postal-code>00010</postal-code>
        </address>
    </shipping>
    <order-number>180606120514730</order-number>
    <payment-methods>
        <payment-method name="paydirekt"/>
    </payment-methods>
    <parent-transaction-amount currency="EUR">5.000000</parent-transaction-amount>
    <api-id>elastic-api</api-id>
    <cancel-redirect-url>https://demoshop-test.wirecard.com/demoshop/#/cancel</cancel-redirect-url>
    <fail-redirect-url>https://demoshop-test.wirecard.com/demoshop/#/error</fail-redirect-url>
    <success-redirect-url>https://demoshop-test.wirecard.com/demoshop/#/success</success-redirect-url>
    <locale>en</locale>
</payment>

Wirecard Payment Page v2

paydirekt is a payment method offered by Germany’s private banks and local cooperative banks. paydirekt is integrated into the systems of the participating banks and follows the strict requirements of the German banking industry. It offers an immediate payment guarantee, a simple interface, as well as high transaction security.

paydirekt is a type of Online Bank Transfer.

General Information

Here you find all the information for integrating paydirekt into your Hosted and Embedded Payment Page.

Want to know more about Wirecard Payment Page v2 (WPP v2)?
Visit one of our integration guides (Hosted Payment Page, Embedded Payment Page) for a quick explanation and a step-by-step guide.

All WPP v2 integrations share a common process flow for creating payments.

Below, we provide samples for the available transaction types authorization and debit, including field lists with short descriptions.

The samples provided below are designed for the testing environment and do not use real information. Please contact Merchant Support for production credentials.

For more details on the redirect-url, see the Configuring Redirects and IPNs for WPP v2 section.

For response verification examples, see the WPP v2 Security section.

Test Credentials

URL (Endpoint)

https://wpp-test.wirecard.com/api/payment/register

Merchant Account ID (MAID)

c7f465c6-7982-4a58-a878-66265e75db50

Username

16390-testing

Password

3!3013=D3fD8X7

Secret Key

30520cf9-8f5b-4b0b-9430-58a1223b79dc

Test Credentials for the paydirekt Environment

Login

WirecardPDExpress2

Password

WirecardPDExpress22$

Countries and Currencies

Countries

Germany

Currencies

Euro

Transaction Types

With paydirect you can use the transaction types authorization and debit.

A debit charges the specified amount from the account holder’s bank account and marks it for immediate transfer.

An authorization reserves the specified amount from the account holder’s bank account for a later transfer.

For a successful transaction:

  1. Create a payment session (initial request).

  2. Redirect the consumer to the payment page (initial response URL).

  3. Highly recommended: Parse and process the payment response.

Sample Workflow

We provide JSON examples for each step of this process. You can find them below.

Request Headers

Authorization

"Authorization"="Basic" + base64 (“username:password”). Use username and password as given in your Wirecard contract to base64-encode the authorization.

Content-Type

application/json

authorization and debit Sample
1. Create a Payment Session (Initial Request)

You can use the following sample for either transaction type. Please enter the desired value (debit or authorization) for transaction-type.

{
    "payment": {
        "merchant-account-id": {
            "value": "c7f465c6-7982-4a58-a878-66265e75db50"
        },
        "request-id": "{{$guid}}",
        "requested-amount": {
            "value": "1.01",
            "currency": "EUR"
        },
        "account-holder": {
            "first-name": "Paul",
            "last-name": "Peterson"
        },
        "order-number": "180606120514730",
        "transaction-type": "authorization", //or "debit"
        "shipping": {
            "first-name": "Paul",
            "last-name": "Peterson",
            "address": {
                "street1": "Muellerstraße 16",
                "city": "Berlin",
                "country": "DE",
                "postal-code": "00010"
            }
        },
        "payment-methods": {
            "payment-method": [
                {
                "name": "paydirekt"
                }
            ]
        },
        "success-redirect-url":"https://demoshop-test.wirecard.com/demoshop/#/success",
        "cancel-redirect-url": "https://demoshop-test.wirecard.com/demoshop/#/cancel",
        "fail-redirect-url": "https://demoshop-test.wirecard.com/demoshop/#/error"
    }
}
Field (JSON) Data Type Required/Optional Size Description

merchant-account-id

value

String

Required

36

A unique identifier assigned to every merchant account (by Wirecard).

request-id

String

Required

36

A unique identifier assigned to every request (by merchant). Used when searching for or referencing it later. {{$guid}} serves as a placeholder for a random request-id.
Allowed characters: [a-z0-9-_ ]

requested-amount

value

Numeric

Required

7,2

The full amount that is requested/contested in a transaction. 2 decimal places allowed. Use . (decimal point) as the separator.
Minimum is 0.01. Maximum is 50000.

currency

String

Required

3

The currency of the requested/contested transaction amount. For paydirekt payments, the currency must be set to EUR. Format: 3-character abbreviation according to ISO 4217.

account-holder

first-name

String

Optional

32

The first name of the consumer.

last-name

String

Optional

32

The last name of the consumer.

order-number

String

Required

20

The order number provided by the merchant.

transaction-type

String

Required

22

The requested transaction type. Available transaction types for paydirekt:

  • debit

  • authorization

shipping

first-name

String

Required

32

The consumer’s first name given for the shipping address.

last-name

String

Required

32

The consumer’s last name given for the shipping address.

address

street 1

String

Required

70

The first line of the consumer’s shipping address.

city

String

Required

32

City of the consumer’s shipping address.

country

String

Required

3

Country of the consumer’s shipping address.

postal-code

String

Required

16

The postal code or ZIP of the consumer’s shipping address.

payment-methods

payment-method

name

String

Required

9

The name of the payment method used. Set this value to paydirekt.

success-redirect-url

String

Required

2000

The URL to which the consumer is redirected after a successful payment, e.g. https://demoshop-test.wirecard.com/demoshop/#/success

cancel-redirect-url

String

Required

2000

The URL to which the consumer is redirected after having canceled a payment, e.g. https://demoshop-test.wirecard.com/demoshop/#/cancel

fail-redirect-url

String

Required

2000

The URL to which the consumer is redirected after a failed payment, e.g. https://demoshop-test.wirecard.com/demoshop/#/error

2. Redirect the Consumer to the Payment Page (Initial Response URL)
{
https://wpp-test.wirecard.com/processing?wPaymentToken=5H6lRQ4Us94_JHe6lmHMCUHItjCsn8vx9kjpUDJhW9k
}
Field (JSON) Data Type Description

payment-redirect-url

String

The URL which redirects to the payment form. Sent as a response to the initial request.

At this point, you need to redirect your consumer to payment-redirect-url (or render it in an iframe depending on your integration method).

Consumers are redirected to the payment form. There they enter their data and submit the form to confirm the payment.
Possible transaction results:

  • Successful (transaction-state: success)

  • Failed (transaction-state: failed)

  • Canceled (transaction-state: failed)

The transaction result is the value of transaction-state in the payment response. More details (including the status code) can also be found in the statuses object of the payment response. Canceled payments are returned as failed, but the status description indicates it was canceled.

In any case (unless the consumer cancels the transaction on a 3rd party provider page), a base64-encoded response containing payment information is sent to the configured redirection URL. See Configuring Redirects and IPNs for WPP v2 for more details on redirection targets after payment and transaction status notifications.

You can find a decoded payment response example below.

3. Parse and Process the Payment Response (Decoded Payment Response)
{
    "payment": {
        "order-number": "180606120514730",
        "transaction-id": "d3a74b61-e27d-4617-87db-fc555aeb006f",
        "request-id": "b8e047fb-8172-4027-b097-da4b3989fd67",
        "transaction-type": "authorization",
        "transaction-state": "success",
        "completion-time-stamp": "2019-07-05T10:51:13",
        "requested-amount": {
            "currency": "EUR",
            "value": 1.01
        },
        "statuses": {
            "status": [
                {
                    "description": "The resource was successfully created.",
                    "severity": "information",
                    "code": "201.0000"
                }
            ]
        },
        "parent-transaction-id": "c6d4ba4b-057f-47a6-8ec0-bdedea86a639",
        "success-redirect-url": "https://demoshop-test.wirecard.com/demoshop/#/success",
        "merchant-account-id": {
            "value": "c7f465c6-7982-4a58-a878-66265e75db50"
        },
        "cancel-redirect-url": "https://demoshop-test.wirecard.com/demoshop/#/cancel",
        "fail-redirect-url": "https://demoshop-test.wirecard.com/demoshop/#/error",
        "account-holder": {
            "account-info": {},
            "last-name": "Peterson",
            "first-name": "Paul"
        },
        "payment-methods": {
            "payment-method": [
                {
                    "payload": {},
                    "name": "paydirekt"
                }
            ]
        },
        "shipping": {
            "last-name": "Peterson",
            "first-name": "Paul",
            "address": {
                "country": "DE",
                "street1": "Mullerstraße 16",
                "city": "Berlin",
                "postal-code": "00010"
            }
        },
        "api-id": "wpp"
    }
}
Field (JSON) Data Type Description

order-number

String

The order number provided by the merchant.

transaction-id

String

A unique identifier assigned for every transaction. This information is returned in the response only.

request-id

String

A unique identifier assigned to every request (by merchant). Used when searching for or referencing it later.

transaction-type

String

The requested transaction type. For paydirekt payments, the transaction-type is either authorization or debit.

transaction-state

String

The current transaction state. Possible values:

  • in-progress

  • success

  • failed

Typically, a transaction starts with state in-progress and finishes with state either success or failed. This information is returned in the response only.

completion-time-stamp

YYYY-MM-DD-Thh:mm:ss

The UTC/ISO time-stamp documents the time and date when the transaction was executed.
Format: YYYY-MM-DDThh:mm:ss (ISO).

requested-amount

currency

String

The currency of the requested/contested transaction amount. For paydirekt payments, the currency must be set to EUR. Format: 3-character abbreviation according to ISO 4217.

value

Numeric

The full amount that is requested/contested in a transaction.

status

code

String

Status code of the status message.

description

String

The description of the transaction status message.

severity

String

The definition of the status message. Possible values:

  • information

  • warning

  • error

parent-transaction-id

String

The ID of the transaction being referenced as a parent.

merchant-account-id

value

String

A unique identifier assigned to every merchant account (by {payment-provider}).

account-holder

first-name

String

The first name of the account holder.

last-name

String

The last name of the account holder.

payment-method

payload

String

This field is used for certain payment methods and occurs in the response only. Irrelevant for paydirekt.

name

String

The name of the payment method used.

shipping

first-name

String

The first name of the shipping address.

last-name

String

The last name of the shipping address.

address

street 1

String

The first line of the shipping address.

city

String

The city of the shipping address.

country

String

The Country Id of the shipping address.

postal-code

String

The postal code or ZIP of the shipping address.

api-id

String

Identifier of the currently used API.

success-redirect-url

String

The URL to which the consumer is redirected after a successful payment, e.g. https://demoshop-test.wirecard.com/demoshop/#/success

cancel-redirect-url

String

The URL to which the consumer is redirected after having canceled a payment, e.g. https://demoshop-test.wirecard.com/demoshop/#/cancel

fail-redirect-url

String

The URL to which the consumer is redirected after a failed payment, e.g. https://demoshop-test.wirecard.com/demoshop/#/error

Optional fields

For a full list of optional fields, see the REST API paydirekt specification. Use the JSON structure of the paydirekt request below as a mapping reference.

Post-Processing Operations

WPP is best used to deal with one-off payments (e.g. regular, independent debit transactions) or the initial transaction in a chain of them (e.g. a first authorization in a chain of recurring transactions). However, when it comes to referencing a transaction for any kind of post-processing operation - such as a refund of one of your debit transactions - use our REST API directly.

Check the REST API paydirekt specification for details on paydirekt-specific post-processing operations.
JSON/NVP Field Reference

Here you can:

  • see the structure of an extended JSON request (XML-JSON mapping reference)

  • find the NVP equivalents for JSON fields (for migrating merchants)

JSON Structure of a paydirekt Request
{
    "payment": {
        "merchant-account-id": {
            "value": "String"
        },
        "request-id": "String",
        "transaction-type": "String",
        "requested-amount": {
            "value": "Numeric",
            "currency": "String"
        },
        "parent-transaction-id": "String",
        "account-holder": {
            "first-name": "String",
            "last-name": "String",
            "email": "String",
            "phone": "String",
            "address": {
                "city": "String",
                "country": "String",
                "postal-code": "String",
                "state": "String",
                "street1": "String",
                "street2": "String",
                "street3": "String"
            }
        },
        "shipping": {
            "first-name": "String",
            "last-name": "String",
            "phone": "String",
            "address": {
                "city": "String",
                "country": "String",
                "postal-code": "String",
                "state": "String",
                "street1": "String",
                "street2": "String",
                "street3": "String"
            }
        },
        "payment-methods": {
            "payment-method": [
                {
                    "name": "String"
                }
            ]
        },
        "bank-account": {
            "iban": "String"
        },
        "mandate": {
            "mandate-id": "String",
            "signed-date": "String"
        },
        "creditor-id": "String",
        "periodic": {
            "periodic-type": "String",
            "sequence-type": "String"
        },
        "descriptor": "String",
        "order-number": "String",
        "success-redirect-url": "String",
        "fail-redirect-url": "String",
        "cancel-redirect-url": "String"
    }
}
Optional Fields in a paydirekt Request
Field (NVP) Field (JSON) JSON Parent

bank_account_iban

iban

bank-account ({ })

cancel_redirect_url

cancel-redirect-url

payment ({ })

city

address ({ })/ city

account-holder ({ })

country

address ({ })/ country

account-holder ({ })

creditor_id

creditor-id

payment ({ })

descriptor

descriptor

payment ({ })

email

email

account-holder ({ })

fail_redirect_url

fail-redirect-url

payment ({ })

first_name

first-name

account-holder ({ })

last_name

last-name

account-holder ({ })

mandate_mandate_id

mandate-id

mandate ({ })

mandate_signed_date

signed-date

mandate ({ })

merchant_account_id

value

merchant-account-id ({ })

order_number

order-number

payment ({ })

payment_method

payment-method ([ ])/name

payment-methods ({ })

periodic_type

periodic-type

periodic ({ })

phone

phone

account-holder ({ })

postal_code

address ({ })/ postal-code

account-holder ({ })

request_id

request-id

payment ({ })

requested_amount

value

requested-amount ({ })

requested_amount_currency

currency

requested-amount ({ })

sequence_type

sequence-type

periodic ({ })

shipping_city

address ({ })/ city

shipping ({ })

shipping_country

address ({ })/ country

shipping ({ })

shipping_first_name

first-name

shipping ({ })

shipping_last_name

last-name

shipping ({ })

shipping_phone

phone

shipping ({ })

shipping_postal_code

address ({ })/ postal-code

shipping ({ })

shipping_state

address ({ })/ state

shipping ({ })

shipping_street1

address ({ })/ street1

shipping ({ })

shipping_street2

address ({ })/ street2

shipping ({ })

shipping_street3

address ({ })/ street3

shipping ({ })

state

address ({ })/ state

account-holder ({ })

street1

address ({ })/ street1

account-holder ({ })

street2

address ({ })/ street2

account-holder ({ })

street3

address ({ })/ street3

account-holder ({ })

success_redirect_url

success-redirect-url

payment ({ })

transaction_type

transaction-type

payment ({ })

Response-Only Fields for paydirekt
Field (NVP) Field (JSON) JSON Parent

api_id

api-id

payment ({ })

completion_time_stamp

completion-time-stamp

payment ({ })

instrument_country

instrument-country

payment ({ })

provider_transaction_id_n

status ([ { } ])/ provider-transaction-id

statuses ({ })

provider_transaction_reference_id

provider-transaction-reference-id

payment ({ })

status_code_n

status ([ { } ])/ code

statuses ({ })

status_description_n

status ([ {} ])/ description

statuses ({ })

status_severity_n

status ([ { } ])/ severity

statuses ({ })

transaction_id

transaction-id

payment ({ })

transaction_state

transaction-state

payment ({ })

Custom URL: