Additional and optional configurations that could be used in different cases

Preselect payment method (CoDi/SPEI)

This option let you declare the target_flow field at the moment of the creation of the session. The value of this field set the session to start with a specific payment method.

target_flow Payment method

Posibles values for target_flow: codi | spei

EXAMPLE:

{
		//BASE PROCESS FIELDS
    "merchant_code": "your_merchant_code",
    "merchant_api_token": "your_merchant_api_token",
    "merchant_order_id": "your_order_id",
    "order_amount": 39,
		//PRESELECT PAYMENT METHOD
		"target_flow": "codi"
}

Preselect email / phone number

This option let you declare the customer_email and customer_phone fields at the moment of the creation of the session. The value of this fields set the session to start with email or phone preselected from the commerce checkout depending on the selected payment method (CoDi/SPEI).

customer_email User email
customer_phone User phone

EJEMPLO:

{
		//BASE PROCESS FIELDS
    "merchant_code": "your_merchant_code",
    "merchant_api_token": "your_merchant_api_token",
    "merchant_order_id": "your_order_id",
    "order_amount": 39,
		//PRESELECT EMAIL/PHONE
		"customer_email": "[email protected]"
		"customer_phone": "9616689020" //10 numbers
}

Dynamic redirect / webhook

This option will allow you at the moment of the session creation to declare URLs for the redirect or the webhook on a dynamic way. For this you need to declare the next variables:

| payment_completed_url | Success payment URL URL que se tomará para la redirección de un pago exitoso. | | --- | --- | | payment_cancellation_url | Error Payment URL URL que se tomará para la redirección de un pago cancelado. | | payment_webhook_url | Webhook URL URL que se tomará para la notificación de estados de pago. | | concat | Use to concatenate a value to the URL, on this case is needed because will be send the JWT on the URL |

Every one of these fields are optional and they’re not linked each other, therefore if you only need to modify one URL just only need add that one field to the request.

EXAMPLE:

{
		//BASE PROCESS FIELDS
    "merchant_code": "your_merchant_code",
    "merchant_api_token": "your_merchant_api_token",
    "merchant_order_id": "your_order_id",
    "order_amount": 1000,
		//DYNAMIC REDIRECT FIELDS
		"payment_completed_url": "<https://domain.com/etpay/success>",
    "payment_cancellation_url": "<https://domain.com/etpay/error>",
		"payment_webhook_url": "<https://domain.com/etpay/webhook>",
    "concat":"&",
}

Metadata