Skip to content

Mercado Pago - Create Payment

Creates a direct payment with a tokenized card in Mercado Pago. Allows processing credit or debit card payments using a token previously generated with the JavaScript SDK.

FieldTypeRequiredDescription
credentials_idcredentialYesMercado Pago credentials
transaction_amountnumberYesPayment amount
tokenstringYesCard token (generated with JS SDK)
payment_method_idstringYesPayment method (visa, master, etc.)
installmentsnumberNoNumber of installments (default: 1)
payer_emailstringYesPayer email
payer_first_namestringNoPayer first name
payer_last_namestringNoPayer last name
identification_typestringNoDocument type (DNI, CPF, etc.)
identification_numberstringNoDocument number
descriptionstringNoPayment description
external_referencestringNoExternal reference
notification_urlstringNoWebhook URL
statement_descriptorstringNoStatement descriptor
binary_modebooleanNoBinary mode (no pending)
idempotency_keystringNoIdempotency key

This module requires a mercadopago type credential with the following fields:

  • Access Token: Mercado Pago access token (obtained from the developer dashboard)
{
"success": true,
"payment": {
"id": 123456789,
"status": "approved",
"status_detail": "accredited",
...
},
"payment_id": 123456789,
"status": "approved",
"status_detail": "accredited",
"message": "Pago 123456789 creado (approved)"
}
{
"transaction_amount": 100.50,
"token": "ff8080814c11e237014c1ff593b57b4d",
"payment_method_id": "visa",
"installments": 3,
"payer_email": "cliente@email.com",
"description": "Compra de producto",
"external_reference": "ORDER-123"
}
  • The token must be previously generated using the Mercado Pago JavaScript SDK
  • The payment_method_id corresponds to the detected card type
  • An idempotency_key is automatically generated if not provided
  • Binary mode (binary_mode: true) rejects payments that would remain pending
  • MercadopagoGetPayments - Get payments
  • MercadopagoCreateRefund - Create refund
  • MercadopagoCreateCustomer - Create customer