#
Mercado Pago Dinero en Cuenta
#
1. Generar link de pago
El método devuelve un link que redirige al medio de pago.
POST /pagos
REQUEST
provider: (Tipo de dato: string). Nombre del Servicio de Pagos ("mp"). Campo obligatorio.
action: (Tipo de dato: string). Tipo de acción a ejecutar ("create"). Campo obligatorio.
currency: (Tipo de dato: string). Tipo de moneda (ARS). Campo obligatorio.
amount: (Tipo de dato: float). Monto a cobrar con punto y dos decimales (Ejemplo: 1200.99). Campo obligatorio.
reference_id: (Tipo de dato: string). Id de la orden. Campo obligatorio.
email: (Tipo de dato: string). Email del comprador. Campo obligatorio.
card_doc_type: (Tipo de dato: string).Tipo de documento del usuario. Campo obligatorio.
card_doc_number: (Tipo de dato: string). Número de documento del usuario. Campo obligatorio.
return_url: (Tipo de dato: string). Url al la cual se desea retornar después de aprobado el pago. Campo obligatorio.
notification_url: (Tipo de dato: string). Url al la cual se va a notificar el resultado de la transacción. Campo obligatorio.
secret: (Tipo de dato: string). Token de MP. Campo obligatorio.
address: (Tipo de dato: objeto literal/hash). Contiene los campos de la dirección del usuario. Campo obligatorio.
address.first_name: (Tipo de dato: string) Nombre. Campo obligatorio.
address.last_name: (Tipo de dato: string) Apellido. Campo obligatorio.
address.street1: (Tipo de dato: string) Calle. Campo obligatorio.
address.number: (Tipo de dato: Number) Número de domicilio. Campo obligatorio.
address.postal_code: (Tipo de dato: String) Código postal. Campo obligatorio.
address.phone_number: (Tipo de dato: Number) Número de teléfono. Campo obligatorio.
{
"provider": "mp",
"action": "create",
"amount": 1200.99,
"reference_id": "5432",
"currency": "ARS",
"return_url": "http://template.pow.la/mercadopago/notification?oid=5432&source=balance",
"notification_url": "http://template.pow.la/mercadopago/mercadopago_confirmation_get?oid=5432",
"secret": "TEST-5464752066894872-022314-3b8c3a637e3cac9c3c8cdca5d90555ee__LC_LD__-185117396",
"card_doc_type": "DNI",
"card_doc_num": "29946689",
"email": "andres.jaromezuk@pow.la",
"address":{
"first_name": "Andrés",
"last_name": "Jaro",
"street1": "Valentín Gómez",
"number": "3550",
"postal_code": "1191",
"phone_number": "42423139"
}
}
RESPONSE
El método devuelve el link al que hay que redirigir al usuario para efectuar el pago.
{
"https://www.mercadopago.com.ar/checkout/v1/redirect?pref_id=281368640-1041b20d-758b-465d-9d87-7f479d65e503"
}
#
2. Obtener pagos realizado
POST /pagos
Es un endpoint solamente informativo. Permite obtener información de un pago.
REQUEST
provider: (Tipo de dato: string). Nombre del proveedor del servicio (mp). Campo obligatorio.
action: (Tipo de dato: string). Identificador de la acción a procesar (obtain_payment_info). Campo obligatorio.
payment_id: (Tipo de dato: string). id de Pago provisto por Mercado Pago. Campo obligatorio.
secret: (Tipo de dato: string). Token de MP. Campo obligatorio.
{
"provider": "mp",
"action": "obtain_payment_info",
"secret": "TEST-4916477523711007-062320-51cf8a77a52069602b5f7e327d7ddceb-281368640"
"payment_id": "3927044"
}
RESPONSE
Devuelve la información del pago.
{
"accounts_info": null,
"acquirer_reconciliation": [],
"additional_info": {
"authentication_code": null,
"available_balance": null,
"items": [
{
"category_id": "Orden",
"description": "Orden",
"id": null,
"picture_url": null,
"quantity": "1",
"title": "Orden 31042826",
"unit_price": "83700.0"
}
],
"nsu_processadora": null,
"payer": {
"address": {
"street_name": "Cacheuta",
"street_number": "4679",
"zip_code": "5016"
},
"first_name": "Catalina",
"last_name": "Alberto",
"phone": {
"number": "3515949245"
}
}
},
"authorization_code": null,
"binary_mode": false,
"brand_id": null,
"build_version": "3.51.3",
"call_for_authorize_id": null,
"captured": true,
"card": {},
"charges_details": [
{
"accounts": {
"from": "collector",
"to": "mp"
},
"amounts": {
"original": 3431.7,
"refunded": 0
},
"client_id": 0,
"date_created": "2024-05-14T06:40:51.000-04:00",
"id": "78067712849-001",
"last_updated": "2024-05-14T06:40:51.000-04:00",
"metadata": {},
"name": "mercadopago_fee",
"refund_charges": [],
"reserve_id": null,
"type": "fee"
},
{
"accounts": {
"from": "collector",
"to": "mp"
},
"amounts": {
"original": 418.5,
"refunded": 0
},
"client_id": 0,
"date_created": "2024-05-14T06:40:52.000-04:00",
"id": "78067712849-002",
"last_updated": "2024-05-14T06:40:52.000-04:00",
"metadata": {
"mov_detail": "tax_withholding",
"mov_financial_entity": "retencion_ganancias",
"mov_type": "expense",
"tax_id": 84509818834,
"tax_status": "applied",
"user_id": 1342599083
},
"name": "tax_withholding-retencion_ganancias",
"refund_charges": [],
"reserve_id": null,
"type": "tax"
},
{
"accounts": {
"from": "collector",
"to": "mp"
},
"amounts": {
"original": 418.5,
"refunded": 0
},
"client_id": 0,
"date_created": "2024-05-14T06:40:52.000-04:00",
"id": "78067712849-003",
"last_updated": "2024-05-14T06:40:52.000-04:00",
"metadata": {
"mov_detail": "tax_withholding",
"mov_financial_entity": "retencion_iva",
"mov_type": "expense",
"tax_id": 84509818836,
"tax_status": "applied",
"user_id": 1342599083
},
"name": "tax_withholding-retencion_iva",
"refund_charges": [],
"reserve_id": null,
"type": "tax"
},
{
"accounts": {
"from": "collector",
"to": "mp"
},
"amounts": {
"original": 502.2,
"refunded": 0
},
"client_id": 0,
"date_created": "2024-05-14T06:40:52.000-04:00",
"id": "78067712849-004",
"last_updated": "2024-05-14T06:40:52.000-04:00",
"metadata": {
"mov_detail": "tax_withholding_collector",
"mov_financial_entity": "debitos_creditos",
"mov_type": "expense",
"tax_id": 84509818838,
"tax_status": "applied",
"user_id": 1342599083
},
"name": "tax_withholding_collector-debitos_creditos",
"refund_charges": [],
"reserve_id": null,
"type": "tax"
},
{
"accounts": {
"from": "collector",
"to": "mp"
},
"amounts": {
"original": 3.35,
"refunded": 0
},
"client_id": 0,
"date_created": "2024-05-14T06:40:52.000-04:00",
"id": "78067712849-005",
"last_updated": "2024-05-14T06:40:52.000-04:00",
"metadata": {
"mov_detail": "tax_withholding_collector",
"mov_financial_entity": "iibb_tucuman",
"mov_type": "expense",
"tax_id": 84509818840,
"tax_status": "applied",
"user_id": 1342599083
},
"name": "tax_withholding_collector-iibb_tucuman",
"refund_charges": [],
"reserve_id": null,
"type": "tax"
},
{
"accounts": {
"from": "collector",
"to": "mp"
},
"amounts": {
"original": 418.5,
"refunded": 0
},
"client_id": 0,
"date_created": "2024-05-14T06:40:52.000-04:00",
"id": "78067712849-006",
"last_updated": "2024-05-14T06:40:52.000-04:00",
"metadata": {
"mov_detail": "tax_withholding_sirtac",
"mov_financial_entity": "cordoba",
"mov_type": "expense",
"tax_id": 84509818842,
"tax_status": "applied",
"user_id": 1342599083
},
"name": "tax_withholding_sirtac-cordoba",
"refund_charges": [],
"reserve_id": null,
"type": "tax"
}
],
"collector_id": 1342599083,
"corporation_id": null,
"counter_currency": null,
"coupon_amount": 0,
"currency_id": "ARS",
"date_approved": "2024-05-14T06:40:52.000-04:00",
"date_created": "2024-05-14T06:40:51.000-04:00",
"date_last_updated": "2024-05-14T06:40:54.000-04:00",
"date_of_expiration": null,
"deduction_schema": "AHORAADMIN_3",
"description": "Orden 31042826",
"differential_pricing_id": null,
"external_reference": "31042826",
"fee_details": [
{
"amount": 3431.7,
"fee_payer": "collector",
"type": "mercadopago_fee"
}
],
"financing_group": null,
"id": 78067712849,
"installments": 1,
"integrator_id": null,
"issuer_id": "2005",
"live_mode": true,
"marketplace_owner": null,
"merchant_account_id": null,
"merchant_number": null,
"metadata": {},
"money_release_date": "2024-06-01T06:40:52.000-04:00",
"money_release_schema": null,
"money_release_status": "pending",
"notification_url": "https://outlet.paulacahendanvers.com.ar/mercadopago/notification?oid=31042826&source=balance",
"operation_type": "regular_payment",
"order": {
"id": "18663951705",
"type": "mercadopago"
},
"payer": {
"email": "catalina.azcona@gmail.com",
"entity_type": null,
"first_name": null,
"id": "37677917",
"identification": {
"number": "14041791",
"type": "DNI"
},
"last_name": null,
"operator_id": null,
"phone": {
"number": null,
"extension": null,
"area_code": null
},
"type": null
},
"payment_method": {
"id": "account_money",
"issuer_id": "2005",
"type": "account_money"
},
"payment_method_id": "account_money",
"payment_type_id": "account_money",
"platform_id": null,
"point_of_interaction": {
"business_info": {
"branch": "PX",
"sub_unit": "checkout_pro",
"unit": "online_payments"
},
"transaction_data": {},
"type": "UNSPECIFIED"
},
"pos_id": null,
"processing_mode": "aggregator",
"refunds": [],
"shipping_amount": 0,
"sponsor_id": null,
"statement_descriptor": null,
"status": "approved",
"status_detail": "accredited",
"store_id": null,
"tags": null,
"taxes_amount": 0,
"transaction_amount": 83700,
"transaction_amount_refunded": 0,
"transaction_details": {
"acquirer_reference": null,
"external_resource_url": null,
"financial_institution": null,
"installment_amount": 0,
"net_received_amount": 78507.25,
"overpaid_amount": 0,
"payable_deferral_period": null,
"payment_method_reference_id": null,
"total_paid_amount": 83700
}
}
#
3. Devolución de pago
Se utiliza para hacer una devolución parcial de un pago.
POST /pagos
REQUEST
provider: (Tipo de dato: string). Nombre del Servicio de Pagos ("mp"). Campo obligatorio.
action: (Tipo de dato: string). Tipo de acción a ejecutar ("refund"). Campo obligatorio.
secret: (Tipo de dato: string). Token de MP. Campo obligatorio.
amount: (Tipo de dato: string). Monto a anular sin puntos ni decimales (Ejemplo: 1200). Campo obligatorio.
payment_id: (Tipo de dato: string). id de Pago provisto por Mercado Pago. Campo obligatorio.
{
"provider": "mp",
"action": "refund",
"secret": "TEST-4916477523711007-062320-51cf8a77a52069602b5f7e327d7ddceb-281368640",
"amount": "1200",
"payment_id": "649060"
}
RESPONSE
#
4. Cancelación de pago
Se utiliza para cancelar un pago pendiente.
POST /pagos
REQUEST
provider: (Tipo de dato: string). Nombre del Servicio de Pagos ("mp"). Campo obligatorio.
action: (Tipo de dato: string). Tipo de acción a ejecutar ("cancel"). Campo obligatorio.
secret: (Tipo de dato: string). Token de MP. Campo obligatorio.
payment_id: (Tipo de dato: string). id de Pago provisto por Mercado Pago. Campo obligatorio.
{
"provider": "mp",
"action": "cancel",
"secret": "TEST-4916477523711007-062320-51cf8a77a52069602b5f7e327d7ddceb-281368640",
"payment_id": "649060"
}
RESPONSE
#
4. Bucar por external reference (order_id)
Se utiliza para obtener un pago a partir de un número de orden.
POST /pagos
REQUEST
provider: (Tipo de dato: string). Nombre del Servicio de Pagos ("mp"). Campo obligatorio.
action: (Tipo de dato: string). Tipo de acción a ejecutar ("cancel"). Campo obligatorio.
secret: (Tipo de dato: string). Token de MP. Campo obligatorio.
reference_id: (Tipo de dato: string). Id de la orden. Campo obligatorio.
{
"provider": "mp",
"action": "obtain_payment_info_ext_ref",
"secret": "APP_USR-4071552333672282-041114-54fe6fdb05f694cf38a9b5236f941b79-1342599083",
"reference_id": "12345"
}
RESPONSE
Devuelve la información del pago.
{
"results": [
{
"metadata": {},
"corporation_id": null,
"operation_type": "regular_payment",
"point_of_interaction": {
"business_info": {
"unit": "online_payments",
"branch": "PX",
"sub_unit": "checkout_pro"
},
"transaction_data": {},
"type": "UNSPECIFIED"
},
"fee_details": [
{
"amount": 2515.9,
"fee_payer": "collector",
"type": "mercadopago_fee"
}
],
"notification_url": "https://www.paulacahendanvers.com.ar/mercadopago/notification?oid=31089341&source=balance",
"date_approved": "2024-05-15T17:31:30.000-04:00",
"money_release_schema": null,
"payer": {
"entity_type": null,
"identification": {
"number": "17154752",
"type": "DNI"
},
"phone": {
"number": null,
"extension": null,
"area_code": null
},
"operator_id": null,
"last_name": null,
"id": "64337862",
"type": null,
"first_name": null,
"email": "marcelajua@hotmail.com"
},
"transaction_details": {
"total_paid_amount": 90500,
"acquirer_reference": null,
"installment_amount": 0,
"financial_institution": null,
"net_received_amount": 86079.98,
"overpaid_amount": 0,
"external_resource_url": null,
"payable_deferral_period": null,
"payment_method_reference_id": null
},
"statement_descriptor": null,
"call_for_authorize_id": null,
"installments": 1,
"pos_id": null,
"external_reference": "31089341",
"date_of_expiration": null,
"charges_details": [
{
"refund_charges": [],
"last_updated": "2024-05-15T17:31:29.000-04:00",
"metadata": {},
"amounts": {
"original": 2515.9,
"refunded": 0
},
"date_created": "2024-05-15T17:31:29.000-04:00",
"name": "mercadopago_fee",
"reserve_id": null,
"accounts": {
"from": "collector",
"to": "mp"
},
"id": "78184967873-001",
"type": "fee",
"client_id": 0
},
{
"refund_charges": [],
"last_updated": "2024-05-15T17:31:29.000-04:00",
"metadata": {
"mov_type": "expense",
"user_id": 273369053,
"tax_status": "applied",
"mov_detail": "tax_withholding",
"mov_financial_entity": "retencion_ganancias",
"tax_id": 84498524601
},
"amounts": {
"original": 452.5,
"refunded": 0
},
"date_created": "2024-05-15T17:31:29.000-04:00",
"name": "tax_withholding-retencion_ganancias",
"reserve_id": null,
"accounts": {
"from": "collector",
"to": "mp"
},
"id": "78184967873-002",
"type": "tax",
"client_id": 0
},
{
"refund_charges": [],
"last_updated": "2024-05-15T17:31:29.000-04:00",
"metadata": {
"mov_type": "expense",
"user_id": 273369053,
"tax_status": "applied",
"mov_detail": "tax_withholding",
"mov_financial_entity": "retencion_iva",
"tax_id": 84498524603
},
"amounts": {
"original": 452.5,
"refunded": 0
},
"date_created": "2024-05-15T17:31:29.000-04:00",
"name": "tax_withholding-retencion_iva",
"reserve_id": null,
"accounts": {
"from": "collector",
"to": "mp"
},
"id": "78184967873-003",
"type": "tax",
"client_id": 0
},
{
"refund_charges": [],
"last_updated": "2024-05-15T17:31:29.000-04:00",
"metadata": {
"mov_type": "expense",
"user_id": 273369053,
"tax_status": "applied",
"mov_detail": "tax_withholding_collector",
"mov_financial_entity": "debitos_creditos",
"tax_id": 84498524605
},
"amounts": {
"original": 543,
"refunded": 0
},
"date_created": "2024-05-15T17:31:29.000-04:00",
"name": "tax_withholding_collector-debitos_creditos",
"reserve_id": null,
"accounts": {
"from": "collector",
"to": "mp"
},
"id": "78184967873-004",
"type": "tax",
"client_id": 0
},
{
"refund_charges": [],
"last_updated": "2024-05-15T17:31:29.000-04:00",
"metadata": {
"mov_type": "expense",
"user_id": 273369053,
"tax_status": "applied",
"mov_detail": "tax_withholding_collector",
"mov_financial_entity": "iibb_tucuman",
"tax_id": 84498524607
},
"amounts": {
"original": 3.62,
"refunded": 0
},
"date_created": "2024-05-15T17:31:29.000-04:00",
"name": "tax_withholding_collector-iibb_tucuman",
"reserve_id": null,
"accounts": {
"from": "collector",
"to": "mp"
},
"id": "78184967873-005",
"type": "tax",
"client_id": 0
},
{
"refund_charges": [],
"last_updated": "2024-05-15T17:31:29.000-04:00",
"metadata": {
"mov_type": "expense",
"user_id": 273369053,
"tax_status": "applied",
"mov_detail": "tax_withholding_sirtac",
"mov_financial_entity": "cordoba",
"tax_id": 84498524609
},
"amounts": {
"original": 452.5,
"refunded": 0
},
"date_created": "2024-05-15T17:31:29.000-04:00",
"name": "tax_withholding_sirtac-cordoba",
"reserve_id": null,
"accounts": {
"from": "collector",
"to": "mp"
},
"id": "78184967873-006",
"type": "tax",
"client_id": 0
}
],
"id": 78184967873,
"payment_type_id": "account_money",
"payment_method": {
"issuer_id": "2005",
"id": "account_money",
"type": "account_money"
},
"order": {
"id": "18720958001",
"type": "mercadopago"
},
"counter_currency": null,
"money_release_status": "pending",
"brand_id": null,
"status_detail": "accredited",
"tags": null,
"differential_pricing_id": null,
"additional_info": {
"authentication_code": null,
"nsu_processadora": null,
"available_balance": null,
"items": [
{
"quantity": "1",
"category_id": "Orden",
"picture_url": null,
"description": "Orden",
"id": null,
"title": "Orden 31089341",
"unit_price": "90500.0"
}
],
"payer": {
"address": {
"street_number": "2068",
"street_name": "Bv los granaderos ",
"zip_code": "5008"
},
"phone": {
"number": "3513577075"
},
"last_name": "juarez",
"first_name": "Marcela"
}
},
"live_mode": true,
"marketplace_owner": null,
"card": {},
"integrator_id": null,
"status": "approved",
"accounts_info": null,
"transaction_amount_refunded": 0,
"transaction_amount": 90500,
"description": "Orden 31089341",
"financing_group": null,
"money_release_date": "2024-05-17T17:31:30.000-04:00",
"merchant_number": null,
"refunds": [],
"expanded": {
"present_meta_data": "",
"gateway": null
},
"authorization_code": null,
"captured": true,
"collector_id": 273369053,
"merchant_account_id": null,
"taxes_amount": 0,
"date_last_updated": "2024-05-15T17:31:33.000-04:00",
"coupon_amount": 0,
"store_id": null,
"build_version": "3.51.3",
"date_created": "2024-05-15T17:31:29.000-04:00",
"acquirer_reconciliation": [],
"sponsor_id": null,
"shipping_amount": 0,
"issuer_id": "2005",
"payment_method_id": "account_money",
"binary_mode": false,
"platform_id": null,
"deduction_schema": "AHORAADMIN_6",
"processing_mode": "aggregator",
"currency_id": "ARS",
"shipping_cost": 0
}
],
"paging": {
"total": 1,
"limit": 30,
"offset": 0
}
}