Crear Referencia
Changed onCrea una Referencia de pago en efectivo para que un Customer la pague en tienda.
Se usa para cobrar en efectivo en México: devuelve la Referencia que el Customer presenta en la caja de la cadena de tiendas y, cuando el proveedor lo entrega, la URL de su código de barras. El pago no queda registrado al crear la Referencia, sino cuando el proveedor notifica que se pagó en tienda.
El gateway es opcional: si no se envía, se usa el gateway por defecto de la Organization. Si la configuración de ese gateway es de Referencias de un solo uso, invoices es obligatorio y la Referencia queda por el total de esos Invoices.
Solo se puede crear una Referencia a la vez por Customer: si hay otra creación en curso para el mismo Customer, la solicitud se rechaza con HTTP 423 y se puede reintentar.
Request
- Base URLhttps://api.trytoku.com
- URLhttps://api.trytoku.com/reference
- AuthAPI key in header x-api-key
Request body
Example request
{
"account": "acc_Nkj5FQ4blAzg-ieIKeRpULgj4hjTf-UJ",
"customer": "cus_fLPjkiFoTCpGKFUIA52AqiOg8B4OdIWO",
"invoices": [
"in_K3a1P1_p_t5UHJHJXmpkQYmqXCHvXrNi"
]
}Response
Referencia creada. El Customer puede pagarla en tienda hasta que venza.
Changes
- breaking
request body became required
- breaking
the
request property type changed fromstringto no type - breaking
removed the media type
application/jsonfor the response with the status - breaking
removed the success response with the status
- warning
deleted the
headerrequest parameterx-api-key - info
api operation id
referenceremoved and replaced withpublic_start_create_cash_mx_reference - info
api tag
Efectivoadded - info
added the new optional request property
- info
added
subschema #2to therequest propertyanyOflist - info
the
request property default valuewas added - info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the success response with the status
- breaking