Ir al contenido
UnoPagoDocumentación
Referencia de la APICustomer dataImports

Import debts

POST
/v1/invoices/debt-import

Issues one invoice per student and due date, dropping the pairs an earlier import already issued, and answers the issued and skipped counts.

Autorización

bearerAuth
headerAutorizaciónBearer <token>

Your API key, created in Configuración → Claves API. The key alone, without the Bearer prefix, is accepted too.

application/json
  1. body
importId*string
Patrón^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatouuid
currency*string
Valor en"VES""USD""EUR"
notifyNotYetDue*boolean
rows*array<>
Elementos1 <= items

Cuerpo de la respuesta

Successful response

application/json
  1. response
issuedCount*integer
Rango0 <= value <= 9007199254740991
alreadyIssuedCount*integer
Rango0 <= value <= 9007199254740991
problems*array<>
Ejemplo de solicitud
curl -X POST 'https://api.unopago.com/v1/invoices/debt-import' \  -H 'Content-Type: application/json' \  -d '{  "importId": "84402506-7f34-4409-8ec1-a4e0ffb6b608",  "currency": "VES",  "notifyNotYetDue": true,  "rows": [    {      "sourceRow": 1,      "name": "string",      "concept": "string",      "dueDate": "2019-08-24",      "amount": 0.01    }  ]}'
Ejemplo de respuesta
{  "issuedCount": 0,  "alreadyIssuedCount": 0,  "problems": [    {      "sourceRow": 1,      "name": "string",      "resolution": {        "status": "notFound"      }    }  ]}