Przelewy24

Accept payments using Przelewy24, the most popular payment method in Poland.

To start accepting Przelewy24 payments, please contact your Customer Success manager.

Overview

Przelewy24 payments follow a two-step process:

  1. Request a payment
  2. Redirect the customer

Request a payment 

The POST request

Use the details below to set up your request.

Endpoints

https://api.checkout.com/payments
https://api.sandbox.checkout.com/payments

Header parameters

HeaderValue

Authorization

REQUIRED

secret key

Use the valid secret key of your Checkout.com account. You can find this in the Hub.

Content-Type

REQUIRED

application/json

Body parameters

The table below describes the minimum recommended fields. You can find the full list, as well as complete request and response examples, in our API reference.

Field nameDescription

amount

INTEGER

REQUIRED

The payment amount.

currency

STRING

REQUIRED

The currency in which the payment is being made (three-letter ISO 4217 code). Set this to PLN.

source

OBJECT

REQUIRED

Details about the payment source.

source.type

STRING

REQUIRED

The type of payment source. Set this to p24.

source.payment_country

STRING

REQUIRED

The country in which the payment instrument is issued/operated (two-letter ISO 3166 code). Set this to PL.

source.account_holder_name

STRING

REQUIRED

The account holder's name.

source.account_holder_email

STRING

REQUIRED

The account holder's email address.

source.billing_descriptor

STRING

OPTIONAL

Typically, the trading name of your company or the name of your service.

Request example

{
  "amount": 100,
  "currency": "PLN",
  "source": {
    "type": "p24",
    "payment_country": "PL",
    "account_holder_name": "Bruce Wayne",
    "account_holder_email":"bruce@wayne-enterprises.com",
    "billing_descriptor": "P24 Demo Payment"
  }
}

The POST response

If you receive a 202 Success response with a status field set to Pending, your request was successful.

Response example

{
  "id": "pay_yo7mr2qvrj5ubirhehlbjr4yda",
  "status": "Pending",
  "customer": {
    "id": "cus_dd7efezan2xexdfhtrhoz6tvam"
  },
  "_links": {
    "self": {
      "href": "https://api.sandbox.checkout.com/payments/pay_yo7mr2qvrj5ubirhehlbjr4yda"
    },
    "redirect": {
      "href": "https://r.girogate.de/ti/simp24?tx=431811890&rs=6FlzR3BeW8SvfX4U0H7weTEkDPSWJBVb&cs=dfcf0cab1a0522652133e8dc0302cdcae683ac07f1317b3db6450893ce007831"
    }
  }
}

Redirect the customer 

Redirect your customer to the redirect link’s href in the response. The customer will be redirected to a Przelewy24 page where they can authorize the payment, before being transferred to your predefined success or failure URL.

Get details about a payment

You can use the payment_id found in the payment response, or the cko-session-id from the success/failure URL (e.g., https://www.checkout.com/order/succeeded?cko-session-id=sid_vii64oquze5u3h2x6hh4rurc4y) to retrieve details about the payment.

The cko-session-id expires 15 minutes after being created.

The GET request

Endpoints

GEThttps://api.checkout.com/payments/{payment_id}
GEThttps://api.sandbox.checkout.com/payments/{payment_id}

Header and path parameters

HeaderValue

Authorization

REQUIRED

secret key

Use the valid secret key of your Checkout.com account. You can find this in the Hub.

Content-Type

REQUIRED

application/json
PathValue

payment_id

REQUIRED

The payment ID found in the response of the initial payment.

The GET response

Response example

{
  "id": "pay_yo7mr2qvrj5ubirhehlbjr4yda",
  "requested_on": "2019-08-08T06:48:21Z",
  "source": {
    "type": "p24",
    "p24_descriptor": "P24-H99-999-999 ABC1234 Dynamic"
  },
  "amount": 100,
  "currency": "PLN",
  "payment_type": "Regular",
  "status": "Captured",
  "approved": true,
  "risk": {
    "flagged": false
  },
  "customer": {
    "id": "cus_dd7efezan2xexdfhtrhoz6tvam"
  },
  "_links": {
    "self": {
      "href": "https://api.sandbox.checkout.com/payments/pay_yo7mr2qvrj5ubirhehlbjr4yda"
    },
    "actions": {
      "href": "https://api.sandbox.checkout.com/payments/pay_yo7mr2qvrj5ubirhehlbjr4yda/actions"
    },
    "refund": {
      "href": "https://api.sandbox.checkout.com/payments/pay_yo7mr2qvrj5ubirhehlbjr4yda/refunds"
    }
  }
}

Refund a payment

Przelewy24 supports both partial and full refunds. You can refund a payment through the Hub or using the refund API.

Testing Przelewy24

To start testing, you'll need to:

  • create a test account, and
  • contact your customer success manager or integrations engineer to activate Przelewy24 payments in the sandbox environment.
  1. Create a Przelewy24 transaction as above, following the redirect link in the response to Przelewy24's website.
  2. Leave the Bank name or BIC field blank and click Next.
  3. Leave the Account Number and PIN fields blank and then click Login.
  4. Leave the TAN field blank and click Make Payment.
  5. Click Back to where you came from to be redirected to your predefined success URL.

Can we help?

Thanks for using Checkout.com. If you need help or have a question, message our Support team at support@checkout.com.