99 android app-contacts app-more app-payments apple apps arrow-apple arrow-down arrow-right arrow-round-right arrow-round auto backspace Shape Created with Sketch. basket business browsers bubbles Group Created with Sketch. Page 1cart-4 Created with Sketch. Shopping cart 3 Created with Avocode. affiliate chart-line Page 1 Created with Sketch. Page 1 Created with Sketch. chat-bubbles Shape Created with Avocode. check-2 check chrome clock-thin clock cloud-2 Cloud V 3 Created with Avocode. Group 19 Created with Sketch. collapse coming-soon commerce-os-2 commerce-os credit-cards delete Recurso 1 desktop devices Group 26 Created with Sketch. api dots downloads Shape Created with Avocode. envelope-3 contact envelope expand f-2 f facebook-2 facebook-3 facebook-store-2 facebook-store facebook firefox folders free 4 Arrows 2 Created with Avocode. Settings 2 Created with Avocode. gears Created with Sketch. google-plus-2 grid help ? home ic-ads ic-api ic-app-market Apps / System / APPS 1 80x80@1x Created with Sketch. ic-banners ic-campaign ic-commerce-os ic-communication ic-contacts ic-finance-express ic-marketing ic-overlay ic-payever ic-payments ic-pos ic-products ic-santander ic-settings ic-shipping ic-statistics ic-store ic-support ic-transactions ic-trust ic-website icon-app-market Shape Created with Avocode. Beck_icons Created with Sketch. icon-chart-2 icon-chat Slice Created with Sketch. icon-check-24-2 icon-check-24 icon-close icon-dd Beck_icons Created with Sketch. icon-handshake icon-iphone icon-jtl icon-magento Shape Created with Avocode. icon-oxid Shape Created with Avocode. icon-play icon-pos icon-prestashop Shape Created with Avocode. Shape Created with Avocode. Beck_icons Created with Sketch. icon-shopify icon-shopware icon-small-business icon-store Shape Created with Avocode. Beck_icons Created with Sketch. icon-woo icon-x icon-xt icon_fn_btn ie in ipad iphone jtl Key 2 Created with Avocode. testing laptop light-bulb linkedin-2 linkedin list Location Created with Avocode. Lock square 2 Created with Avocode. login logo-installment logo-intercom logo-payment-more logo-sofort logo-telegram magento magnifier mailchimp marketing Group Created with Avocode. Group 22 Created with Sketch. Recurso 3 mobile Dollar coin 2 Created with Avocode. network no-hardware note-2 note notebook ok oxid page_developer_icon_01 page_developer_icon_02 page_developer_icon_03 page_developer_icon_04 page_developer_icon_05 page_developer_icon_06 paper payever-2 payever payment-options blog pencil-ruler Pencil 2 Created with Avocode. percentage pie-chart play-2 play-video play plugins Group 4 Created with Sketch. possiblities present-1 present presentation press question-mark-2 question-mark recycle refresh Shape Created with Avocode. replay safari santander-flame santander search settings-1 settings shield shopware sign simple-app-icon-ads simple-app-icon-app-market-2 simple-app-icon-app-market-3 simple-app-icon-app-market simple-app-icon-banners simple-app-icon-communication simple-app-icon-contacts simple-app-icon-facebook-2 simple-app-icon-facebook simple-app-icon-marketing simple-app-icon-mystores simple-app-icon-overlay simple-app-icon-payments simple-app-icon-pos simple-app-icon-products simple-app-icon-statistics simple-app-icon-transactions simple-icon-shipping simple-icon-support simple-icon-trust simple-payment-icon-santander smile news portal switch Recurso 2 tags Page 1 Created with Sketch. target timer toc tools-2 Page 1 Created with Sketch. trend-graph troubleshooting truck twitter profile-male Created with Sketch. user video wallet Watch 2 Created with Avocode. weebly woo world Wrench 3 Created with Avocode. write xt youtube

Filter by Payment:

API Documentation

payever provides an easy to integrate API for shopsystems we can´t provide a plugin for. Integrate the payment options by using the "Create" and "Retrieve" endpoints. Afterwards "List" will show you all transactions inside your shopsystem. Only invoice payment requires the further endpoints.

Overview

Authentication

Request:

# Method: POST
# Endpoint: /oauth/v2/token

curl -k https://mein.payever.de/oauth/v2/token \
  -d client_id="{client_id}" \
  -d client_secret="{client_secret}" \
  -d grant_type="http://www.payever.de/api/payment" \
  -d scope="API_CREATE_PAYMENT"
<?php

$curl = curl_init();

$params = array(
   'client_id' => '12345_client_id_string',
   'client_secret' => 'client_secret_string',
   'grant_type' => 'http://www.payever.de/api/payment',
   'scope' => 'API_CREATE_PAYMENT',
);
curl_setopt_array($curl, array(
   CURLOPT_URL => "https://mein.payever.de/oauth/v2/token",
   CURLOPT_RETURNTRANSFER => true,
   CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
   CURLOPT_POSTFIELDS => $params,
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
   echo "cURL Error #:" . $err;
} else {
   echo $response;
}

<?php

$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/oauth/v2/token');
$request->setMethod(HTTP_METH_POST);

$request->setQueryData(array(
  'client_id' => '12345_client_id_string',
  'client_secret' => 'client_secret_string',
  'grant_type' => 'http://www.payever.de/api/payment',
  'scope' => 'API_CREATE_PAYMENT'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

Response:

{
  "access_token": "NWNkODc3ZjFkZWUyZDM1Mzg2Njg2NzMzYjJkOTljYWExYzI3MDAwNzAzYTgyOWYyOWI2ZDc3Z jUxNmJhYTlmYw",
  "expires_in": 3600,
  "token_type": "bearer",
  "scope": "API_CREATE_PAYMENT",
  "refresh_token": "ZWIyZGU4ZDVjOTEwMjczM2FmNzA3ZWUyZGFlZGYzY2UyZjRhMmNkMTQ0NDhhMjc5ZmMzNGNh Mzg5YzFjZjQ4Mw"
}

The authentication to the payever API is done by providing one of your API keys in the request. You can manage your API keys from your account.

You can have multiple API keys active at one time. Your API keys carry many privileges, so be sure to keep them secret. All API requests must be made over HTTPS.

Calls made over plain HTTP will fail. You must authenticate for all requests.

Authentication token can be defined in the HTTP request header or in the URL:
Authentication: Bearer {access_code}
/api/payment?access_code={access_code}

Method
POST

Endpoint
/oauth/v2/token

Attribute required Description
client_id true Your payever client_id.
client_secret true Your payever client_secret
scope true The scope you want to access. Available are: API_CREATE_PAYMENT: create a new payment
grant_type true Grant type is always: http://www.payever.de/api/payment

Payments

Create payment

Request:

# Method: POST, Endpoint: /api/payment
curl -k https://mein.payever.de/api/payment
-X POST
-H "Authorization: Bearer {access_token}"
-d amount="100"
-d fee="10"
-d order_id="900001291100"
-d currency="USD"
-d cart=json_encode(
   array(
     array(
       'name' => 'Some article',
       'price' => '15',
       'quantity' => '3',
       'description' => 'The new article',
       'thumbnail' => 'https://someitem.com/thumbnail.jpg',
       'url' => 'URL to article'
     ),
     array(
       'name' => 'Some item',
       'price' => '15',
       'quantity' => '3',
       'description' => 'The new item in black',
       'thumbnail' => 'https://someitem.com/thumbnail',
       'url' => 'URL to article'
     )
   )
 )
 ,
-d salutation="mr"
-d first_name="John"
-d last_name="Doe"
-d city="New York"
-d zip="10019"
-d street="5th Ave, 342"
-d country="US"
-d email="john.doe@payever.de"
-d phone="+1 (800) 566756"
-d social_security_number="1234567890"
-d success_url="https://www.you.shop.tld/callback/success/--PAYMENT-ID--\call_id/--CALL-ID--"
-d failure_url="https://www.you.shop.tld/callback/failure/--PAYMENT-ID--\call_id/--CALL-ID--"
-d cancel_url="https://www.you.shop.tld/callback/notice/--PAYMENT-ID--\call_id/--CALL-ID--"
-d notice_url="https://www.you.shop.tld/callback/success/--PAYMENT-ID--\call_id/--CALL-ID--"
-d pending_url="https://www.you.shop.tld/callback/pending/--PAYMENT-ID--\call_id/--CALL-ID--"
-d x_frame_host="https://your.shop.tld"

<?php

$curl = curl_init();

$cart = array(
   array(
       'name' => 'Some article',
       'price' => '15',
       'priceNetto' => '15',
       'vatRate' => '10',
       'quantity' => '3',
       'description' => 'The new article',
       'thumbnail' => 'https://someitem.com/thumbnail.jpg',
       'sku' => '123',
   ),
   array(
       'name' => 'Some item',
       'price' => '15',
       'priceNetto' => '15',
       'vatRate' => '10',
       'quantity' => '3',
       'description' => 'The new item in black',
       'thumbnail' => 'https://someitem.com/thumbnail',
       'sku' => '124',
   )
);
$params = array(
   'channel' => 'other_shopsystem',
   'amount' => '100',
   'fee' => '10',
   'order_id' => '900001291100',
   'currency' => 'USD',
   'cart' => json_encode($cart),
   'salutation' => 'mr',
   'first_name' => 'John',
   'last_name' => 'Doe',
   'city' => 'New York',
   'zip' => '10019',
   'street' => '5th Ave, 342',
   'country' => 'US',
   'email' => 'john@payever.de',
   'phone' => '+1 (800) 123756',
   'success_url' => 'https://www.you.shop.tld/callback/success/--PAYMENT-ID--\call_id/--CALL-ID--',
   'failure_url' => 'https://www.you.shop.tld/callback/failure/--PAYMENT-ID--\call_id/--CALL-ID--',
   'cancel_url' => 'https://www.you.shop.tld/callback/notice/--PAYMENT-ID--\call_id/--CALL-ID--',
   'notice_url' => 'https://www.you.shop.tld/callback/success/--PAYMENT-ID--\call_id/--CALL-ID--',
   'pending_url' => 'https://www.you.shop.tld/callback/pending/--PAYMENT-ID--\call_id/--CALL-ID--',
   'x_frame_host' => 'https://your.shop.tld,',
);


curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/payment",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_POST => true,
  CURLOPT_POSTFIELDS => $params,
  CURLOPT_HTTPHEADER => array(
    "Authorization: Bearer <access_token>"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

<?php

$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/payment');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders(array(
  'content-type' => 'application/x-www-form-urlencoded',
));

$request->setContentType('application/x-www-form-urlencoded');

$cart = array(
   array(
       'name' => 'Some article',
       'price' => '15',
       'priceNetto' => '15',
       'vatRate' => '10',
       'quantity' => '3',
       'description' => 'The new article',
       'thumbnail' => 'https://someitem.com/thumbnail.jpg',
       'sku' => '123',
   ),
   array(
       'name' => 'Some item',
       'price' => '15',
       'priceNetto' => '15',
       'vatRate' => '10',
       'quantity' => '3',
       'description' => 'The new item in black',
       'thumbnail' => 'https://someitem.com/thumbnail',
       'sku' => '124',
   )
);

$request->setPostFields(array(
  'access_token' => 'MWVhZjZlMmVmMxNzIzZg',
  'channel' => 'other_shopsystem',
  'amount' => '100',
  'fee' => '10',
  'order_id' => '900001291100',
  'currency' => 'USD',
  'cart' => json_encode($cart),
  'salutation' => 'mr',
  'first_name' => 'John',
  'last_name' => 'Doe',
  'city' => 'New York',
  'zip' => '10019',
  'street' => '5th Ave, 342',
  'country' => 'US',
  'email' => 'john@payever.de',
  'phone' => '+1 (800) 123756',
  'success_url' => 'https://www.you.shop.tld/callback/success/--PAYMENT-ID--\call_id/--CALL-ID--',
  'failure_url' => 'https://www.you.shop.tld/callback/failure/--PAYMENT-ID--\call_id/--CALL-ID--',
  'cancel_url' => 'https://www.you.shop.tld/callback/notice/--PAYMENT-ID--\call_id/--CALL-ID--',
  'notice_url' => 'https://www.you.shop.tld/callback/success/--PAYMENT-ID--\call_id/--CALL-ID--',
  'pending_url' => 'https://www.you.shop.tld/callback/pending/--PAYMENT-ID--\call_id/--CALL-ID--',
  'x_frame_host' => 'https://your.shop.tld,',
));

try {
  $response = $request->send();
  echo $response->getBody();

} catch (HttpException $ex) {

  echo $ex;
}

Response:

{
  "call": {
    "id": "d0e7144fcdeac4dcfa7b4eed3206c9cf",
    "shop_id": "31012408fad6abc962c5af237e1bb930",
    "status": "new",
    "created_at": "2014-05-21T13:52:46+0200",
    "payment_id": "d44c2eb96a608dd61ed9cf7bafa8bd24 - // when payment object was created, means checkout form was submitted successfully",
    "amount": 100,
    "order_id": "900001291100",
    "currency": "USD",
    "cart": "Some Goods",
    "salutation": "SALUTATION_MR",
    "first_name": "John",
    "last_name": "Doe",
    "street": "5th Ave, 342",
    "zip": "10019",
    "city": "New York",
    "country": "US",
    "phone": " 1 (800) 566756",
    "email": "john.doe@payever.de",
    "success_url": "https://www.you.shop.tld/callback/success/--PAYMENT-ID--\call_id/--CALL-ID--",
    "failure_url": "https://www.you.shop.tld/callback/failure/--PAYMENT-ID--\call_id/--CALL-ID--",
    "cancel_url": "https://www.you.shop.tld/callback/notice/--PAYMENT-ID--\call_id/--CALL-ID--",
    "notice_url": "https://www.you.shop.tld/callback/success/--PAYMENT-ID--\call_id/--CALL-ID--",
    "pending_url": "https://www.you.shop.tld/callback/pending/--PAYMENT-ID--\call_id/--CALL-ID--",
    "“x_frame_host”": "https://www.you.shop.tld",

    "type": "create"
  },

  "redirect_url": "https://mein.payever.de/shop/payment/api/6f5ee0715cd35f212ec6cce0284aec35"
}
{
  "call": {
    "id": "dac34c66e54ad56c8",
    "status": "new",
    "created_at": "2016­06­20T16:13:15+02:00", "business_id": "super­shop",
    "channel": "o​ther_shopsystem",
    "amount": 100,
    "fee": 10,
    "order_id": "900001291100", "currency": "USD",
    "cart": "{}",
    "salutation": "SALUTATION_MR", "first_name": "John", "last_name": "Doe",
    "street": "5th Ave, 342",
    "zip": "10019",
    "city": "New York",
    "country": "US",
    "phone": "+1 (800) 123756",
    "email": "john@payever.de",

    "success_url": "https://www.you.shop.tld/callback/success/--PAYMENT-ID--\call_id/--CALL-ID--",
    "failure_url": "https://www.you.shop.tld/callback/failure/--PAYMENT-ID--\call_id/--CALL-ID--",
    "cancel_url": "https://www.you.shop.tld/callback/notice/--PAYMENT-ID--\call_id/--CALL-ID--",
    "notice_url": "https://www.you.shop.tld/callback/success/--PAYMENT-ID--\call_id/--CALL-ID--",
    "pending_url": "https://www.you.shop.tld/callback/pending/--PAYMENT-ID--\call_id/--CALL-ID--",
    "“x_frame_host”": "https://www.you.shop.tld",

    "payments": [],
    "type": "create"
  },

  "redirect_url": "https://mein.payever.de/pay/load­api/dac34c66c683ad56c8"
}

Method
POST

Endpoint
/api/payment

The create payment function generates an html snippet (redirect_url) which has to be placed within your checkout. On the snippet, a customer can choose his preferred payment method and finalizes the payment. Most of our attributes are optional but the more you send to our API the less your customer has to enter by himself. To use this function you have to generate an access token for the scope: API_CREATE_PAYMENT.

After the gateway is created you have to redirect the customer to the {redirect_url}.

You can do this either by a real redirect or inject the URL as an iFrame to your cart. We recomment to use the iframe solution.

After a successful transaction, the customer will be redirected to your provided success_url.

Attribute required type Description
channel true string Channel type, for example "shopware", "magento", "oxid" etc. Default value is shopware. Please take care, if you have, for example, only magento channel enabled, the use of default value will follow to an error response like "The channel shopware is not enabled". In most cases you will need "other_shopsystem".
channel_set_id false integer The channel set ID. If not given - the first channel set of the channel selected will be used.
amount true float Order amount
fee false float Shipping fee
order_id true string (50 symbols max). ID or reference to identify the order.

In case santander_installment payment option (Santander Germany) is forced – 35 symbols max (santander requirement).

Please note, if payment option is not forced (customer is free to choose any available payment options) and santander_installment was chosen manually in payment options list – the order_id will be cut out to 35 symbols automatically.
currency true string 3 Letter ISO currency code
cart true array Cart items with name, description, quantity, price, thumbnail and url to article
payment_method false string Select between cash, santander_installment, santander_ccp_installment, santander_installment_dk, santander_installment_no, santander_invoice_no, santander_installment_se, invoice, stripe, stripe_directdebit, sofort, paypal, payex_creditcard, payex_faktura, paymill_creditcard and paymill_directdebit.

If not specified, the payment page will contain a list of available payment options, and customer will be able to select one of them.
salutation false string The customer’s salutation, mr / mrs*
first_name false string The customer’s first name
last_name false string The customer’s last name
street false string The street of the customer’s shipping address
zip false string The zip of the customer’s shipping address
city false string The city of customer’s shipping address
country false string 2 Letter ISO country code
social_security_number false string Social Security Number. Currently supported Sweden social security numbers.
birthdate false DateTime The customer´s birthdate
phone false string The customer´s phone number
email false string The customer’s email address
success_url false string URL to redirect customer on successful transaction. You can add --PAYMENT-ID-- and --CALL-ID-- as a placeholder to catch the right payment on redirect. E.g. https://yourshop.com/success.php?payment_id=--PAYMENT-ID--&call_id=--CALL-ID--(query string parameters way)

or

https://yourshop.com/success.php/payment_id/--PAYMENT-ID--/call_id/--CALL-ID--

Please note, CALL_ID and PAYMENT_ID placeholders are not required to be used in the url, they are just a helpful information. For example, if you don’t have a way to identify your cart payment inside your system – use our CALL_ID. The PAYMENT_ID will return our payment transaction identifier, can be helpful to retrieve the full payment details via API later.
pending_url false string URL to redirect customer on failed transaction. You can add --PAYMENT-ID-- and --CALL-ID-- as a placeholder to catch the right payment on redirect. E.g. https://yourshop.com/failure.php?payment_id=--PAYMENT-ID--
failure_url false string URL to redirect customer on failed transaction. You can add --PAYMENT-ID-- and --CALL-ID-- as a placeholder to catch the right payment on redirect. E.g. https://yourshop.com/failure.php?payment_id=--PAYMENT-ID--
cancel_url false string URL to redirect customer on transaction that are on hold. You can add --PAYMENT-ID-- and --CALL-ID-- as a placeholder to catch the right payment on redirect. E.g. https://yourshop.com/pending.php?payment_id=--PAYMENT-ID--
notice_url false string URL for notifications about occured transactions. Any changes in transaction (mostly status changes) will be sent to this URL using POST request with JSON payload.
x_frame_host false string x_frame_host (required) false (type) string (description) "URL for `Content-Security-Policy` and `X-Frame-Options ALLOW_FROM` headers that will be added to the payment iframe. success/pending/notice/failure/cancel url will be used if x_frame_host was no sent. If no one callback url was provided `self` headers will be added: Content-Security-Policy frame-ancestors 'self' and X-Frame-Options SAMEORIGIN
plugin_version false string Just the statistical information about your code/plugin version

Retrieve payment

Request:

curl -k https://mein.payever.de/api/payment/{payment_id} 
-X GET
-H "Authorization: Bearer {access_token}"
<?php
$curl = curl_init();
$params = array(
    'access_token' => 'YjI5ZDYxMzBOTAwZA'
);

curl_setopt_array( $curl, array(
    CURLOPT_URL => "https://mein.payever.de/api/payment/153af899a8cb787e60caf",

    CURLOPT_POST => false,
    CURLOPT_HTTPHEADER => array( "Authorization: Bearer " ),

    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  )
);

$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

<?php
$request = new HttpRequest();
$request­>setUrl('https://mein.payever.de/api/payment/153af899a8cb787e60caf');
$request­>setMethod(HTTP_METH_GET);
$request­>setQueryData(array( 'access_token' => 'YjI5ZDYxMzBOTAwZA'));

try {

  $response = $request­>send();
  echo $response­>getBody();

} catch (HttpException $ex) {

  echo $ex;
}

Response:

{
  "call": {
    "id": "d8a6079d7e9ca4d164dc0ceacc5ca050",
    "shop_id": "31012408fad6abc962c5af237e1bb930",
    "status": "success",
    "created_at": "2014-05-21T14:52:02+0200",
    "payment_id": 0
  },
  "result": {
    "id": "d44c2eb96a608dd61ed9cf7bafa8bd24",
    "status": "STATUS_NEW",
    "merchant_name": "Martin Saigger",
    "customer_name": "John Doe",
    "payment_type": "santander_installment",
    "created_at": "2014-05-21T14:10:29+0200",
    "updated_at": "2014-05-21T14:10:29+0200",
    "reference": "900001291100",
    "amount": 1000,
    "fee": 99.9,
    "payment_details": {

    }
  }
}
{
  "call": {
    "id": "a12f1c87db06a173",
    "status": "success",
    "created_at": "2016­06­21T12:25:41+02:00",
    "business_id": "super­shop"
  },
  "result": {
    "id": "153af899a2787e60caf",
    "status": "STATUS_NEW",
    "color_state": "yellow",
    "merchant_name": "Super shop",
    "customer_name": "Roma",
    "payment_type": "paypal",
    "created_at": "2016­06­07T21:41:29+02:00",
    "updated_at": "2016­06­07T21:41:29+02:00",
    "channel": "store",
    "reference": "212ce8616fee0bfd",
    "amount": 4,
    "currency": "EUR",
    "fee": 0.43,
    "total": 4,
    "address": {
      "id": 74,
      "country": "DE",
      "country_name": "Germany",
      "city": "Men",
      "zip_code": "873",
      "street": "Graeg",
      "street_number": "75",
      "salutation": "SALUTATION_MR",
      "first_name": "Roman",
      "last_name": "Q",
      "type": "shipping"
    },
    "payment_details": {
      "prefilled": false
    }
  }
}

Method
GET

Endpoint
/api/payment/{id}

The retrieve payment function retrieves all information for a specific payment. You can use this function to update the status of a payment within your cart. To use this function you have to generate an access token.

Attribute required type Description
access_token true string To retrieve a payment you have to generate an access token
payment_id true string To retrieve a specific payment you have to provide its payment_id. You obtain the payment_id by creating our gateway or by retrieving a list of previous made payments.

List payments

Request:

curl -k https://mein.payever.de/api/payment?limit=50
-X GET
-H "Authorization: Bearer {access_token}"

<?php
$curl = curl_init();
$params = array(
  'limit' => '50 ',
  'access_token' => 'YTc2NjI4ZTYyM2Q5Mjk4ZQ',
  'payment_type' => 'paypal',
  'currency' => 'EUR',
  'state' => 'STATUS_NEW',
  'date' => '2016­06­20T16'
);
curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/payment",
  CURLOPT_POSTFIELDS => $params,
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_POST => true,
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
}
else {
  echo $response;
}

<?php
$request = new HttpRequest();
$request­ > setUrl('https://mein.payever.de/api/payment');
$request­ > setMethod(HTTP_METH_GET);
$request­ > setQueryData(array(
  'limit' => '50 ',
  'access_token' => 'YTc2NjI4ZTYyM2Q5Mjk4ZQ',
  'payment_type' => 'paypal',
  'currency' => 'EUR',
  'state' => 'STATUS_NEW',
  'date' => '2016­06­20T16'
));
try {
  $response = $request­ > send();
  echo $response­ > getBody();
}

catch(HttpException $ex) {
  echo $ex;
}

Response:

 {
  "call": {
    "id": "195b2548d02c32b3da928b60455e832f",
    "shop_id": "31012408fad6abc962c5af237e1bb930",
    "status": "success",
    "created_at": "2014-05-09T17:03:18+0200",
    "limit": 5
  },
  "result": [
    {
      "id": 157,
      "status": "STATUS_ACCEPTED",
      "merchant_name": "Some Merchant",
      "customer_name": "John Doe",
      "payment_type": "invoice",
      "last_action": "INVOICE_TRANSFER",
      "created_at": "2014-05-09T10:11:48+0200",
      "updated_at": "2014-05-09T14:54:35+0200",
      "reference": "900001291100",
      "amount": 100
    },
    {

    }
  ]
}
{
  "call": {
    "id": "ab8ae1fc1d287",
    "status": "success",
    "created_at": "2016­06­20T16:33:09+02:00",
    "business_id": "super­shop",
    "currency": "EUR",
    "state": "STATUS_NEW",
    "limit": 50
  },
  "result": [
    {
      "id": "153afe60caf",
      "status": "STATUS_NEW",
      "color_state": "yellow",
      "merchant_name": "Super shop",
      "customer_name": "Roman QA2",
      "payment_type": "paypal",
      "created_at": "2016­06­07T21:41:29+02:00",
      "updated_at": "2016­06­07T21:41:29+02:00",
      "channel": "store",
      "reference": "212ce8ee0bfd",
      "amount": 4,
      "currency": "EUR",
      "fee": 0.43,
      "total": 4,
      "address": {
        "id": 7444,
        "country": "DE",
        "country_name": "Germany",
        "city": "München",
        "zip_code": "8373",
        "street": "Grweg",
        "street_number": "745",
        "salutation": "SALUTATION_MR",
        "first_name": "Roman",
        "last_name": "QA2",
        "type": "shipping"
      }
    }
  ],
  "redirect_url": "https://mein.payever.de/shop/payment/api/6f5ee84aec35"
}

Method
GET

Endpoint
/api/payment

The list payment function responds an array with a specific set of transactions made with your account. To use this function you have to generate an access token.

Attribute required type Description
access_token true string To retrieve a payment, you have to generate an access_token.
payment_method false string Retrieve only transactions for the given payment_method. Available are cash, santander installment, invoice, paypal, stripe, direct debit and sofort.
date false DateTime Retrieve only transactions for the given date.
currency false string Retrieve only payments with the given currency.
state false string Retrieve only payments with the given state. These are the ones available: STATUS_NEW, STATUS_IN_PROCESS, STATUS_ACCEPTED, STATUS_FAILED, STATUS_DECLINED, STATUS_IN_COLLECTION and STATUS_LATEPAYMENT
limit false string Limit the output of retrieved transactions. By default the last 10 transactions matching the given values are responded.

Refund payment

Request:

 curl -k https://mein.payever.de/api/payment/refund/{payment_id} \
-X POST \
-H "Authorization: Bearer {access_token}" \
-d amount="50"
<?php

$curl = curl_init();
curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/payment/refund/153af899a81c2787e60caf",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_POST => true,
  CURLOPT_POSTFIELDS => "amount=50&access_token=MjE3MzExYjMWY2NzI1MQ",
  CURLOPT_HTTPHEADER => array(
    "Authorization: Bearer <access_token>"
  ) ,
));

$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
}
else {
  echo $response;
}

<?php
//'access_token' = 'MjE3MzExYjZiNWNzI1MQ'
$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/payment/refund/153af8960caf');
$request->setMethod(HTTP_METH_POST);
$request->setHeaders(array(
  'content-type' => 'application/x-www-form-urlencoded',
  'Authorization' => 'Bearer <access_token>'
));
$request->setContentType('application/x-www-form-urlencoded');
$request->setPostFields(array(
  'amount' => '50',

));
try {
  $response = $request->send();
  echo $response->getBody();
}

catch(HttpException $ex) {
  echo $ex;
}

Response:

{
  "call": {
    "id": "456d307932af3a099ec625132ee3ae9c",
    "shop_id": "31012408fad6abc962c5af237e1bb930",
    "status": "success",
    "created_at": "2014-06-04T10:47:06+02:00",
    "payment_id": "48b89a6f9c6f48fc765830a69032682e",
    "amount": 50,
    "type": "refund"
  },
  "result": {

  }
}
{
  "call": {
    "id": "fe1ae99f8ac0aa86ce5a8c",
    "status": "success",
    "created_at": "2016-06-22T17:38:23+02:00",
    "business_id": "super-shop",
    "payment_id": "153af899a81c2787e60caf",
    "amount": 50,
    "type": "refund"
  }
}

Method
POST

Endpoint
/api/payment/refund/{payment_id}

The refund payment method refunds a payment completely or partially. This function is only available for invoice payments. To use this function you have to generate an access token.

Attribute required type Description
amount false float Specify the refund amount. If no amount is set, the whole amount will be refunded. It depends on the payment method if you have to take further action like wire-transfer the amount to the customer for invoice payments.

Authorize payment

Request:

 curl -k https://mein.payever.de/api/payment/authorize/48b89a6f9c6f48fc765830a69032682e \
-X POST \
-H "Authorization: Bearer {access_token}" \
-d customer_id="328" \
-d invoice_id="1000098991" \
-d invoice_date="2014-05-21"
<?php
//'access_token' => 'ZGJmGRkYjAwZA',

$curl = curl_init();
$params = array(
  'customer_id' => '328',
  'invoice_id' => '100',
  'invoice_date' => '2016-05-21T00:00:00+02:00'
);

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/payment/authorize/6b8687b7b1edcfc",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_POST => true,
  CURLOPT_POSTFIELDS => $params,
  CURLOPT_HTTPHEADER => array(
    "Authorization: Bearer <access_token>"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

<?php

//'access_token' => 'ZGJmGRkYjAwZA',
$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/payment/authorize/6b8687be1edcfc');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders(array(
  'content-type' => 'application/x-www-form-urlencoded',
  'Authorization' => 'Bearer <access_token>'
));

$request->setContentType('application/x-www-form-urlencoded');
$request->setPostFields(array(
  'customer_id' => '328',
  'invoice_id' => '100',
  'invoice_date' => '2016-05-21T00:00:00+02:00'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

Response:

{
"call":
  {
    "id": "b58b1c28f14ddb625c0ffd2ceca75f6e",
    "shop_id": "31012408fad6abc962c5af237e1bb930",
    "status": "success",
    "created_at": "2014-06-04T11:37:02+02:00",
    "payment_id": "12926734411fa4a1b82b46e7194990f0",
    "customer_id": "328",
    "invoice_id": "100",
    "invoice_date": "2014-05-21T00:00:00+02:00",
    "type": "authorize"
  },
  "result": {}
}
{
  "call": {
    "id": "e98ff776106a3d7a00ee",
    "status": "success",
    "created_at": "2016-06-22T17:31:10+02:00",
    "business_id": "super-shop",
    "payment_id": "153af8991c2787e60caf",
    "customer_id": "328",
    "invoice_id": "100",
    "invoice_date": "2016-05-21T00:00:00+02:00",
    "type": "authorize"
  }
}

Method
POST

Endpoint
/api/payment/authorize/{payment_id}

Authorize a previously made payment. This function is only available for invoice payments.
To use this function you have to generate an access token.

Attribute required type Description
customer_id false string The customer ID from your System. If nothing is set we use our own customer ID.
invoice_id false string The invoice ID from your System. If nothing is set we use the generated payment_id.
invoice_date false dateTime The Date you generated and shipped the invoice. If nothing is set we use the current date.

Remind payment

Request:

curl -k https://mein.payever.de/api/payment/remind/12926734411fa4a1b82b46e7194990f0 \
-X POST \
-H "Authorization: Bearer {access_token}"
<?php
//'access_token' => 'N2ViNTEwZjM0NTiYmVhMg'
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/payment/remind/153af8991c2787e60caf",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_POST => true,
  CURLOPT_POSTFIELDS => "access_token=N2ViNTEw5NGI5ZTliYmVhMg",
  CURLOPT_HTTPHEADER => array(
    "Authorization: Bearer <access_token>"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

<?php

//'access_token' => 'N2ViNTEwZjM0NTiYmVhMg'
$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/payment/remind/153af899a8e60caf');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders(array(
  'content-type' => 'application/x-www-form-urlencoded',
  'Authorization' => 'Bearer <access_token>'
));

$request->setContentType('application/x-www-form-urlencoded');
$request->setPostFields(array(
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

Response:

{
"call":
  {
    "id": "b58b1c28f14ddb625c0ffd2ceca75f6e",
    "shop_id": "31012408fad6abc962c5af237e1bb930",
    "status": "success",
    "created_at": "2014-06-04T11:37:02+02:00",
    "payment_id": "12926734411fa4a1b82b46e7194990f0",
    "type": "remind"
  },
  "result": {}
}
{
  "call": {
    "id": "ca743b22893d830e69ebb",
    "status": "success",
    "created_at": "2016-06-22T17:43:37+02:00",
    "business_id": "super-shop",
    "payment_id": "153af89c2787e60caf",
    "type": "remind"
  }
}

Method
POST

Endpoint
/api/payment/remind/{payment_id}

With this function you can remind outstanding payments. The customer will receive an email from payever with your payment information. This function is only allowed if the payment is outstanding for more than 14 days after the generated invoice date. This function is only available for invoice payments.
To use this function you have to generate an access token.

Collect payments

Request:

 curl -k https://mein.payever.de/api/payment/collect/12926734411fa4a1b82b46e7194990f0 \
-X POST \
-H "Authorization: Bearer {access_token}"
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/payment/collect/153af8991c2787e60caf",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_POST => true,
  CURLOPT_POSTFIELDS => "access_token=N2ViNTEw5NGI5ZTliYmVhMg",
  CURLOPT_HTTPHEADER => array(
    "Authorization: Bearer <access_token>"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}


<?php

//'access_token' => 'N2ViNTEwZjM0NTiYmVhMg'
$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/payment/collect/153af899a8e60caf');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders(array(
  'content-type' => 'application/x-www-form-urlencoded',
  'Authorization' => 'Bearer <access_token>',
));

$request->setContentType('application/x-www-form-urlencoded');
$request->setPostFields(array(
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

Response:

{
"call":
  {
    "id": "b58b1c28f14ddb625c0ffd2ceca75f6e",
    "shop_id": "31012408fad6abc962c5af237e1bb930",
    "status": "success",
    "created_at": "2014-06-04T11:37:02+02:00",
    "payment_id": "12926734411fa4a1b82b46e7194990f0",
    "type": "collect"
  },
  "result": {}
}
{
  "call": {
    "id": "8d72c76922cbe49",
    "status": "success",
    "created_at": "2016-06-22T17:58:16+02:00",
    "business_id": "super-shop",
    "payment_id": "153af899787e60caf",
    "type": "collect"
  }
}

Method
POST

Endpoint
/api/payment/collect/{payment_id}`

With this function you can collect outstanding payments. This function is only allowed if the payment is outstanding for more than 14 days after the date of the invoice and you already sent a payment reminder. This function is only available for invoice payments.
To use this function you have to generate an access token.

Late payments

Request:

 curl -k https://mein.payever.de/api/late-payment/12926734411fa4a1b82b46e7194990f0 \
-X POST \
-H "Authorization: Bearer {access_token}"
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/payment/late-payment/153af8991c2787e60caf",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_POST => true,
  CURLOPT_POSTFIELDS => "access_token=N2ViNTEw5NGI5ZTliYmVhMg",
  CURLOPT_HTTPHEADER => array(
    "Authorization: Bearer <access_token>"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}


<?php
//'access_token' => 'N2ViNTEwZjM0NTiYmVhMg'

$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/payment/late-payment/153af899a8e60caf');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders(array(
  'content-type' => 'application/x-www-form-urlencoded',
  'Authorization' => 'Bearer <access_token>',
));

$request->setContentType('application/x-www-form-urlencoded');
$request->setPostFields(array());

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

Response:

{
"call":
  {
    "id": "b58b1c28f14ddb625c0ffd2ceca75f6e",
    "shop_id": "31012408fad6abc962c5af237e1bb930",
    "status": "success",
    "created_at": "2014-06-04T11:37:02+02:00",
    "payment_id": "12926734411fa4a1b82b46e7194990f0",
    "type": "late-payment"
  },
  "result": {}
}
{
  "call": {
    "id": "6e240e2258653f5",
    "status": "success",
    "created_at": "2016-06-22T18:08:21+02:00",
    "business_id": "super-shop",
    "payment_id": "153af87e60caf",
    "type": "late_payment"
  }
}

Method
POST

Endpoint
/api/payment/late-payment/{payment_id}

With this function you can notify any received late payments for all transactions you collected before with the “collect payment” function. This function is only allowed if the payment was set to “in collection” before. This function is only available for invoice payments.
To use this function you have to generate an access token.

Shipping goods payment

Request:

 curl -k https://mein.payever.de/api/shipping-goods/6ffd39faba130015e443d8b7d9e07995 \
-X POST \
-H "Authorization: Bearer {access_token}"
<?php

//'access_token' => 'ZGJmGRkYjAwZA',
$curl = curl_init();

$params = array(
  'customer_id' => '328',
  'invoice_id' => '100',
  'invoice_date' => '2016-05-21T00:00:00+02:00'
);

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/payment/shipping-goods/6b8687b7b1edcfc",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_POST => true,
  CURLOPT_POSTFIELDS => $params,
  CURLOPT_HTTPHEADER => array(
    "Authorization: Bearer <access_token>"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

<?php

$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/payment/shipping-goods/6b8687b7b1edcfc');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders(array(
  'content-type' => 'application/x-www-form-urlencoded',
  'Authorization' => 'Bearer <access_token>',
));

$request->setContentType('application/x-www-form-urlencoded');
$request->setPostFields(array(
  'customer_id' => '328',
  'invoice_id' => '100',
  'invoice_date' => '2016-05-21T00:00:00+02:00'
));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

Response:

{
"call":
  {
    "id": "b58b1c28f14ddb625c0ffd2ceca75f6e",
    "shop_id": "31012408fad6abc962c5af237e1bb930",
    "status": "success",
    "created_at": "2014-06-04T11:37:02+02:00",
    "payment_id": "12926734411fa4a1b82b46e7194990f0",
    "customer_id": "328",
    "invoice_id": "100",
    "invoice_date": "2014-05-21T00:00:00+02:00",
    "type": "shipping-goods"
  },
  "result": {}
}
{
  "call":{
    "business_id":"super-shop",
    "created_at":"2016-06-24T15:34:32+00:00",
    "id":"d8ef167e56a1",
    "payment_id":"15596b20532422bf",
    "status":"success",
    "type":"shipping_goods"
  },
  "result":{
    "address":{
      "city":"München",
      "country":"DE",
      "country_name":"Germany",
      "first_name":"R",
      "full_street":"Arnulfstraße 1",
      "id":362,
      "last_name":"Test",
      "salutation":"SALUTATION_MR",
      "street":"Arnulfstraße",
      "street_number":"1",
      "type":"billing",
      "zip_code":"12345"
    },
    "amount":123,
    "channel":"santander",
    "channel_set":{
      "configured":true,
      "created_at":"2015-07-28T15:22:17+00:00",
      "discr":"santander",
      "id":19,
      "name":"Default set",
      "slug":"31012c5af237e1bb930-2/santander/default-set",
      "updated_at":"2016-06-24T15:34:32+00:00"
    },
    "color_state":"yellow",
    "created_at":"2015-10-07T22:19:25+00:00",
    "currency":"EUR",
    "customer_name":"R Test",
    "fee":0,
    "id":"15599525c6b20532422bf",
    "items":[],
    "last_action":"INVOICE_TRANSFER",
    "merchant_name":"Test Test",
    "other_fees":0,
    "payever_commission":0,
    "payment_details": {
      "_e_u":[ 0, 3, 41, 6 ],
      "accept_terms_credit_europe":true,
      "application_no":"3500181007221900",
      "application_status":"IN_PROCESS",
      "bank_details_selection":"account_number_bank_code",
      "credit_accepts_requests_to_credit_agencies":false,
      "credit_calculation":{
        "bank_interest":34.259999999999998,
        "cpi_amount":30,
        "duration":6,
        "interest_rate":9.9000000000000004,
        "monthly_rate":26.210000000000001,
        "price":123,
        "rate_pa":7.7009999999999996,
        "total_amount":157.25999999999999
      },
      "credit_confirms_self_initiative":true,
      "credit_due_date":1,
      "credit_duration_in_months":6,
      "credit_protection_insurance":true,
      "delivery_fee":0,
      "discr":"santander_installment",
      "email":"r2@m.info",
      "employment_limited":false,
      "finance_id":"1140972",
      "freelancer":false,
      "id":2449,
      "initial_payment":0,
      "payment_fee":0,
      "personal_date_of_birth":"1990-02-01T00:00:00+00:00",
      "prefilled":false,
      "prev_address":false,
      "prev_employment_details":false,
      "specific_status":"STATUS_SANTANDER_IN_PROCESS"
    },
    "payment_type":"santander_installment",
    "reference":"sdf",
    "status":"STATUS_IN_PROCESS",
    "total":123,
    "updated_at":"2016-06-24T15:34:39+00:00"
  }
}

Method
POST

Endpoint
/api/payment/shipping-goods/{payment_id}

With this function you can notify that the goods were delivered. This function is only allowed to be send one time and it's only available for Santander payments.
To use this function you have to generate an access token.

Cancel payment

Request:

 curl -k https://mein.payever.de/api/cancel/95d9e75fecabfaf563c63ef5cf232830 \
-X POST \
-H "Authorization: Bearer {access_token}"
<?php

//'access_token' => 'N2ViNTEwZjM0NTiYmVhMg'
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/payment/cancel/153af8991c2787e60caf",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_POST => true,
  CURLOPT_POSTFIELDS => "access_token=N2ViNTEw5NGI5ZTliYmVhMg",
  CURLOPT_HTTPHEADER => array(
    "Authorization: Bearer <access_token>"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

<?php

$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/payment/cancel/153af899a8e60caf');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders(array(
  'content-type' => 'application/x-www-form-urlencoded',
  'Authorization' => 'Bearer <access_token>',
));

$request->setContentType('application/x-www-form-urlencoded');
$request->setPostFields(array());

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

Response:

{
    "call": {
        "id": "76f57db32417970ad0661de37d9b285a",
        "status": "success",
        "created_at": "2016-06-21T06:35:20+00:00",
        "business_id": "demoshop",
        "payment_id": "95d9e75fecabfaf563c63ef5cf232830",
        "type": "cancel"
    },
    "result": {
        "id": "95d9e75fecabfaf563c63ef5cf232830",
        "status": "STATUS_CANCELLED",
        "color_state": "red",
        "merchant_name": "Demoshop",
        "customer_name": "Artur Schlaht",
        "payment_type": "santander_installment_no",
        "last_action": "INVOICE_CANCELLATION",
        "created_at": "2016-04-03T18:07:57+00:00",
        "updated_at": "2016-06-21T06:35:24+00:00",
        "channel": "shopware",
        "channel_set": {
            "id": 2619,
            "name": "Shopware",
            "slug": "demoshop-norway/shopware/shopware",
            "configured": true,
            "created_at": "2016-03-14T08:40:32+00:00",
            "updated_at": "2016-06-21T06:35:20+00:00",
            "discr": "shopware"
        },
        "reference": "LEXINGTON (SW10016)",
        "items": [],
        "amount": 6990,
        "currency": "NOK",
        "fee": 0,
        "other_fees": 0,
        "payever_commission": 0,
        "total": 6990,
        "address": {
            "full_street": "Vitaminveien 7 - 9",
            "id": 8436,
            "country": "NO",
            "country_name": "Norway",
            "city": "Oslo",
            "zip_code": "0485",
            "street": "Vitaminveien",
            "street_number": "7 - 9",
            "salutation": "SALUTATION_MR",
            "first_name": "Artur",
            "last_name": "Schlaht",
            "type": "shipping"
        },
        "payment_details": {
            "specific_status": "CANCELLED",
            "id": 3368,
            "delivery_fee": 0,
            "payment_fee": 0,
            "email": "superpenguin@gmx.net",
            "prefilled": false,
            "student": false,
            "credit_type": "HANDLEKONTO",
            "campaign_code": "TWO_MONTH_199",
            "application_number": "152102",
            "monthly_amount": "0.00",
            "credit_duration_in_months": 0,
            "credit_calculation": {
                "product_type": "HANDLEKONTO",
                "campaign_code": "TWO_MONTH_199",
                "credit_duration": "0",
                "kid": "094027006991",
                "status_code": "PROCESSING",
                "status_description": "Under behandling",
                "approved": false,
                "decision_made": false,
                "final": false,
                "paid": false,
                "flow_status_code": "ERROR"
            },
            "discr": "santander_no_installment"
        }
    }
}

Method
POST

Endpoint
/api/payment/cancel/{payment_id}

With this function you can cancel the payment which wasn't failed or canceled previously.
To use this function you have to generate an access token

Additional Info

Retrieve API call

Method
GET

Endpoint
/api/<id>

Request:

curl -X GET https://mein.payever.de/api/66f692d79714c2545683d3ebe262013a
curl \
  -X GET https://mein.payever.de/api/66f692d79714c2545683d3ebe262013a?access_token=<access_token>
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/aba9f0d333c95da172",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

<?php

$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/aba9f0d333c95da172');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

Response:

{
  "id": "66f692d79714c2545683d3ebe262013a",
  "status": "success",
  "created_at": "2015-09-24T14:19:46+02:00",
  "shop_id": "your-shop-slug",
  "action": "list_channel_sets",
  "type": "list_channel_sets"
}
{
  "id": "aba9f0d333c95da172",
  "status": "success",
  "created_at": "2016-06-22T18:42:41+02:00",
  "business_id": "super-shop",
  "action": "list_channel_sets",
  "type": "list_channel_sets"
}

Returns serialized API call record. Can be used to retrieve payment create API call and read there status and payment failure message if payment was failed.

Important! This access point does not require authentication to retrieve API calls made to access points with public visibility, like /api/shop/<slug>/channel-sets.
For secured calls use access token: create a new one as in Authentication chapter or token used in the target api call.

List Channel sets

Request:

curl -X GET https://mein.payever.de/api/shop/<slug>/channel-sets
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/shop/super-shop/channel-sets",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

<?php

$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/shop/super-shop/channel-sets');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}

Response:


{
  "call": {
    "id": "66f692d79714c2545683d3ebe262013a",
    "status": "success",
    "created_at": "2015-09-24T14:19:46+02:00",
    "shop_id": "your-shop-slug"
  },
  "result": [
    {
      "channel_type": "shopware",
      "channel_sets": [
        {
          "id": 123,
          "name": "Default set",
          "slug": "your-shop-slug/shopware/default-set",
          "configured": true,
          "created_at": "2010-09-24T14:01:17+00:00",
          "updated_at": "2010-09-25T14:01:17+00:00"
        }
      ],
      "enabled": true
    }
  ]
}
{
  "call": {
    "id": "aba9f0d333c95da172",
    "status": "success",
    "created_at": "2016-06-22T18:42:41+02:00",
    "business_id": "super-shop"
  },
  "result": [
    {
      "id": 2307,
      "channel_type": "checkout",
      "channel_sets": [
        {
          "id": 1908,
          "name": "default",
          "slug": "super-shop/super-shop-checkout/super-shop-checkout-default",
          "configured": false,
          "created_at": "2016-01-28T08:03:16+01:00",
          "updated_at": "2016-06-07T21:39:33+02:00"
        }
      ],
      "enabled": true
    },
    {
      "id": 2308,
      "channel_type": "store",
      "channel_sets": [
        {
          "id": 2340,
          "name": "Store",
          "slug": "super-shop/store/store",
          "configured": true,
          "created_at": "2016-02-18T19:36:38+01:00",
          "updated_at": "2016-06-22T18:08:21+02:00",
          "store": {
            "id": 590,
            "name": "Store",
            "shipping_price": 0,
            "currency": "EUR",
            "live": false,
            "primary_language": "en",
            "languages": [
              "en",
              "de",
              "es"
            ],
            "hidden": false,
            "logo_url": null
          }
        }
      ],
      "enabled": true
    },
    {
      "id": 2309,
      "channel_type": "marketing",
      "channel_sets": [],
      "enabled": true
    },
    {
      "id": 4183,
      "channel_type": "pos",
      "channel_sets": [],
      "enabled": true
    },
    {
      "id": 6141,
      "channel_type": "magento",
      "channel_sets": [
        {
          "id": 3324,
          "name": "Magento",
          "slug": "super-shop/magento/magento",
          "configured": true,
          "created_at": "2016-06-20T16:10:31+02:00",
          "updated_at": "2016-06-22T14:43:47+02:00"
        }
      ],
      "enabled": true
    },
    {
      "id": 6142,
      "channel_type": "e-conomic",
      "channel_sets": [
        {
          "id": 3323,
          "name": "E-Conomic",
          "slug": "super-shop/e-conomic/e-conomic",
          "configured": false,
          "created_at": "2016-06-20T16:06:06+02:00",
          "updated_at": "2016-06-20T16:06:24+02:00"
        }
      ],
      "enabled": true
    },
    {
      "id": 6143,
      "channel_type": "other_shopsystem",
      "channel_sets": [
        {
          "id": 3325,
          "name": "Other ShopSystem",
          "slug": "super-shop/other-shopsystem/other-shopsystem",
          "configured": true,
          "created_at": "2016-06-20T17:59:11+02:00",
          "updated_at": "2016-06-22T17:30:22+02:00"
        }
      ],
      "enabled": true
    }
  ]
}

Method
GET

Endpoint
/api/shop/<slug>/channel-sets

Parameter Required Description
slug Required The shop slug, like shop-1

List Payment Options

Request:

curl -X GET https://mein.payever.de/api/shop/<slug>/payment-options
<?php
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://mein.payever.de/api/shop/super-shop/payment-options/other_shopsystem",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}

<?php

$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/shop/super-shop/payment-options/other_shopsystem');
$request->setMethod(HTTP_METH_GET);

try {
    $response = $request->send();

    echo $response->getBody();
}
catch (HttpException $ex) {
    echo $ex;
}

$curl = curl_init();

curl_setopt_array($curl, array(
    CURLOPT_URL => "https://mein.payever.de/api/shop/super-shop/payment-options/other_shopsystem",
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
));

$response = curl_exec($curl);
$err      = curl_error($curl);

curl_close($curl);

if ($err) {
    echo "cURL Error #:" . $err;
} else {
    echo $response;
}

<?php

$request = new HttpRequest();
$request->setUrl('https://mein.payever.de/api/shop/super-shop/payment-options/other_shopsystem');
$request->setMethod(HTTP_METH_GET);

try {
    $response = $request->send();
    echo $response->getBody();
}
catch (HttpException $ex) {
    echo $ex;
}

Response:

{
  "call": {
    "id": "callid",
    "status": "success | failed",
    "created_at": "20001-01-26T18:00:00+00:00",
    "shop_id": "shop-slug",
    "action": "list_payment_options",
    "channel": "shopware",
    "type": "shop_info_list_payment_options",
    "result": [
      {
        "id": "123221",
        "name": "Stripe",
        "status": "active",
        "variable_fee": 1.23,
        "fixed_fee": 2.34,
        "accept_fee": "boolean",
        "description_offer": "Lorem ipsum",
        "description_fee": "Lorem ipsum",
        "min": 0,
        "max": 100000,
        "payment_method": "stripe",
        "type": "payment",
        "slug": "stripe",
        "thumbnail1": "https://mein.payever.de/media/cache/payment_option.list_icon/207120b7bb406bc4024b68c3d0f7142a.png",
        "thumbnail2": "https://mein.payever.de/media/cache/payment_option.list_icon/207120b7bb406bc4024b68c3d0f7142a.png",
        "thumbnail3": "https://mein.payever.de/media/cache/payment_option.list_icon/207120b7bb406bc4024b68c3d0f7142a.png",
        "options": {
          "currencies": [
            "EUR",
            "GBP",
            "USD"
          ],
          "countries": [
            "DE",
            "AT",
            "ES"
          ],
          "actions": [
            "refund",
            "authorize",
            "remind",
            "collect",
            "late_payment"
          ]
        },
        "translations": [
          {
            "locale": "en",
            "field": "conditions",
            "content": "Lorem Ipsum"
          }
        ]
      }
    ]
  }
{
  "call": {
    "id": "aac8932020bcdf95ffc",
    "status": "success",
    "created_at": "2016-06-22T17:35:45+02:00",
    "business_id": "super-shop",
    "action": "list_payment_options",
    "channel": "other_shopsystem",
    "channel_set": {
      "id": 3325,
      "name": "Other ShopSystem",
      "slug": "super-shop/other-shopsystem/other-shopsystem",
      "configured": true,
      "created_at": "2016-06-20T17:59:11+02:00",
      "updated_at": "2016-06-22T17:30:22+02:00",
      "discr": "other_shopsystem"
    },
    "type": "shop_info_list_payment_options"
  },
  "result": [
    {
      "id": "12321",
      "name": "Stripe",
      "status": "active",
      "variable_fee": 1.23,
      "fixed_fee": 2.34,
      "accept_fee": "boolean",
      "description_offer": "Lorem ipsum",
      "description_fee": "Lorem ipsum",
      "min": 0,
      "max": 100000,
      "payment_method": "stripe",
      "type": "payment",
      "slug": "stripe",
      "thumbnail1": "https://mein.payever.de/media/cache/payment_option.list_icon/207120b7bb406bc4024b68c3d0f7142a.png",
      "thumbnail2": "https://mein.payever.de/media/cache/payment_option.list_icon/207120b7bb406bc4024b68c3d0f7142a.png",
      "thumbnail3": "https://mein.payever.de/media/cache/payment_option.list_icon/207120b7bb406bc4024b68c3d0f7142a.png",
      "options": {
        "currencies": [
          "EUR",
          "GBP",
          "USD"
        ],
        "countries": [
          "DE",
          "AT",
          "ES"
        ],
        "actions": [
          "refund",
          "authorize",
          "remind",
          "collect",
          "late_payment"
        ]
      },
      "translations": [
        {
          "locale": "en",
          "field": "conditions",
          "content": "Lorem Ipsum"
        }
      ]
    }
  ]
}

Method
GET

Endpoint
/api/shop/<slug>/payment-options/<channel>

With this function you can get payment options accessible in the shop.
Since payment options are public information, there are no security headers required.

Parameter Required Description
slug Required The shop slug, like shop-1
channel Optional Channel type. Default value is shopware, first channel set will be used

Or, another way, experimental:

Method
GET

Endpoint
/api/shop/<slug>/payment-options/<channel-set-id>

Parameter Required Description
slug Required The shop slug
channel-set-id Optional Channel set ID. Since the access point url is the same as previous, by default will be used first channel set of shopware channel

Changelog

Changelog Version 1.3

September 24, 2015

  • Add channel and channel_set_id attributes to Payment Create
  • Add endpoint: list payment options per channel set
  • Add endpoint: list shop channel sets
  • Add endpoint: retrieve API call

Changelog Version 1.2

Fixes in payment options list:

  • attribute fix_fee renamed to fixed_fee
  • added accept_fee attribute

Fixes in create payment call:

  • added new attribute plugin_version

Changelog Version 1.1

Implementation of the following API functions:

  • refund
  • authorize
  • remind
  • collect
  • late-payment

Response value changed for create payment function:

{redirect_url} will now give the complete redirect_url. It is no longer necessary to add the host https://mein.payever.de in front of the received redirect_url.

Changelog Version 1.0

Implementation of the following API functions:

  • authenticate
  • create payment
  • retrieve payment
  • list payments