Step 1

Add your private key and API version.

You need your private test key. You can find it in your admin.

Step 2

Create an order

Creating an ordergenerates a charge to your client. If you do not want to create a charge immediately, you can prepare an order and generate the charge later by sending the charges array information.

The minimum required fields are shown in the example, if you want to know more about the order object, review our REST API documentation.

Step 3

Process the response

Once you have created an order and a charge, you must process the response and present a SPEI pay stub.

Remember that the order response is in JSON format.

Step 4

Display payment instructions

Use a pay stub, like this one, to give your client their payment reference and necessary steps to complete their purchase.

SPEI Pay Stub

A set of sample instructions are provided below. SPEI is a common payment method in Mexico, particularly for B2B, however it is important to explain that the deposit can only be performed once, and for the exact amount, otherwise the payment will be rejected.

Include a SPEI pay stub in your checkout or send it by email to offer a better experience.

Review our repo on Github.

Step 5

Process payment webhooks

You will receive payment notifications asyncronously in a JSON format via an HTTP POST call to your servers. To receive these notifications you will first need to configure a Webhook in your Conekta Admin.

Use public URLs: If you do not have a public IP or domain, you can use services like ultrahook or localtunnel.

Webhooks reference

Step 6

Notify your client

Step 7

Test your webhook

In your Conekta Admin you can test the funcionality of your webhook.

You will need: The URL of your webhook and access to Conekta Admin.

That's it! Please remember to exchange your sandbox keys for the production keys.