English
Modules

Checkout

15min



Simple Checkout creation flow
Simple Checkout creation flow

POST
Request
Header Parameters
x-api-key
required
String
API key of your application.
x-access-token
required
String
Access token to your entity.
content-type
required
String
application/json
Body Parameters
total
required
Number
Amount of the transaction. Format XXX.xx where the DOT is the decimal separator..
description
required
String
Description of the operation that will be shown in the checkout when entering.
currency
required
String
Currency of the operation. Admitted value "ARS".
reference
required
String
Invoice, Receipt or reference of the payment to be made. It can be an identifier from an external system for tracking. This identifier belongs to your system but must be unique for each operation. Mobbex does not allow 2 transactions in Paid status with the same reference.
test
optional
Boolean
Allows you to place the checkout in test mode and perform operations with Mobbex test cards.
return_url
optional
String
URL to which the user will be sent upon payment finish.
webhook
optional
String
URL to which the payment will be reported via WebHooks (POST)
items
optional
Array
List of elements belonging to the payment with checkout and that will be shown when entering it as part of the payment description. To generate a checkout associated to a subscription it must be configured in this array. See the example on this node included below this documentation.
options
optional
Object
Allows you to define options for the created checkout.
sources
optional
Array
Allows the limitation of the accepted sources. Thus, only the sources defined here can be used at checkout.
installments
optional
Array
Allows the limitation of the Active Plans when paying the order. To perform this limitation you must send an array of plan references. Examples can be found below in the documentation.
customer
required
Object
Object with customer data.
split
optional
Array
Allows to split the checkout collection in several Mobbex entities. For more details see the section "Marketplace, Split, Commission Collection".
timeout
optional
Number
Lifetime in minutes of the checkout during which it can be used, after this time the checkout will not be valid. Default is 60 minutes.
intent
optional
String
Type of operation. See documentation on operation in 2 steps.
multicard
optional
Boolean
Allows the transaction to be paid at checkout with multiple cards. It is not compatible with SPLIT type transactions.
addresses
optional
Array
Customer Addresses.
addresses[$].type
optional
String
Address type. Allowed values: "billing", "shipping".
addresses[$].country
optional
String
Country. Admitted values: See Table of Countries in Complements.
addresses[$].street
optional
String
Address without door number.
addresses[$].streetNumber
optional
String
Address door number
addresses[$].streetNotes
optional
String
Notes references to address, second line of address, Floor, Department, Office, etc.
addresses[$].zipCode
optional
String
Zip Code.
addresses[$].city
optional
String
City.
addresses[$].state
optional
String
State (ISO 3166). See Cod. of Argentine Provinces in the Complements section.
webhooksType
optional
String
Allows you to enable or disable certain types of Webhooks. By default this option will be "all". Possible options: "all", "none", "final", "intermediateAndFinal". See explanation below.




Examples of node items:

JSON


Clarification: Images must support HTTPS, otherwise they will not be displayed. To place subscriptions inside the checkout, an object must be added to the items array with the type "subscription" and as reference the UID of the subscription to which the subscriber will be associated.



Examples of node sources:

JSON




Examples of node installments:

There are 3 ways to Limit Plans:

  • Hide certain plans from the entire set of existing plans:
JSON

  • Limit the Plans selected in the Array:
JSON

  • Show special plans based on Advanced Rules:
JSON

Document image


For available payment sources and installment plans, see Payment methods and installments Payment Methods and Installments.

Important

Checkout Duration

The created checkout can only be used for 60 (or the time defined in the Timeout variable) minutes, after that it will expire. If the customer tries to pay after this period he will be redirected to the url declared in return_url with status 401 (Expired).

"Reference" attribute

This attribute is used to avoid duplicate payments. It must be unique for each payment transaction to be identified, as Mobbex will NOT allow 2 transactions in "Paid" status with the same reference.

2-Step Transaction

The checkout module is enabled to use the 2-step transaction or "Authorization and Capture". This special type of operation requires previous authorization of the merchant to be able to use it. Documentation on the transaction flow and implementation details can be found at the following link.

Postman

Response and WebHooks

Completed Transaction

By defining the return_url parameter the service will redirect to the URL provided by HTTP Get once the transaction is completed. To this url will be added the status of the transaction through the status parameter, the type of transaction generated by the user through the type parameter (cash/card) and the transaction identifier through the transactionId parameter.

Example:

https://mobbex.com/thank_you?status=200&type=cash&transactionId=NfkvurRUX

Cancelled Transaction

If the user cancels the transaction status will be 0 and type will be none. This as noted indicates that the user did not finish the operation and decided to return to the site.

Example:

https://mobbex.com/thank_you?status=0&type=none&transactionId=-1

Possible status reference

It is very important to review the documentation on status and types of documentation as the handling of these will be used during the Mobbex trade approval. This documentation can be found in the following link: Statuses and Transaction Types.



Checkout Expiration

To avoid that a Checkout remains pending of payment after a certain time, they have a default time limit of 60 minutes that can be customized via the "timeout" parameter when creating the checkout by sending the maximum number of minutes you want the checkout to remain active. The minimum number of minutes is 1 minute.

When a Checkout Expires or Expires the service automatically sends a notification via Webhook. This Webhook has a special form described below. It should be noted that this Webhook is not similar to the operative Webhooks.

JSON


Once this Webhook is received, it is understood that the Checkout can no longer be paid and it is recommended to return the Stock or take the necessary actions from your Backend.

The "data" field will be sent when there have been unsuccessful payment attempts, this field serves as a control of the operation.

JSON


This special webhook will NOT be sent when there is an operation in the following states:

  • 200
  • 3
  • 210
  • 300
  • 301
  • 2
  • 100

Parámetro WebhooksType

This parameter should be used to limit the Webhooks received, for example when we only want to be notified when a transaction reaches a final status but not when there are unsuccessful payment attempts.

Webhook Type Options:

  • all: This is the default option and the service will send any transaction attempt made by the customer during Checkout payment.
  • final: Webhooks will only be sent when the customer reaches a final status, such as an Approved payment. All other statuses will not be sent although the checkout status will be sent in the Expiration Webhook discussed above. States that will be notified: 200, 3, 300, 301, 2.
  • intermediateAndFinal: Intermediate statuses will be sent to the previous option, e.g. a transaction under review for fraud. Additional states to the "final" type that will be sent: 100, 210.
  • none: In this option no checkout will be sent even if the url of the checkout is defined. Only use this option in special cases. If you use this option you must get the status of the checkout via API using the defined "reference".

If the checkout expires and the operation changes status, for example from "On Hold (2)" to "Rejected (400)" the notification will be sent in "all", "final" and "intermediateAndFinal" types, only it will not be sent in "none" type.



This will allow you to delete a checkout created before the default 60 minutes duration.
DELETE
Request
Query Parameters
ID
required
String
ID of the Checkout to be deleted.
Header Parameters
x-api-key
required
String
API key of your application.
x-access-token
required
String
Access Token to the entity.