Documentación / API / Saldo y facturación

Transacciones de saldo

GEThttps://api.cfdi.express/v1/billing/transactionsAPI key

El ledger completo de tu saldo: cada recarga, consumo, reembolso y ajuste con el saldo resultante.

Cada movimiento incluye deltaCentavos (positivo o negativo) y balanceAfterCentavos, para que puedas auditar el saldo sin recalcular nada.

Paginación por cursor: toma el id del último elemento y pásalo como starting_after mientras has_more sea true.

Autenticación
Authorization: Bearer sk_test_... | sk_live_...

Parámetros

Query string

CampoTipoDescripción
limitintegerElementos por página. Entre 1 y 100. Default 10.
starting_afterstringId de la última transacción de la página anterior (cursor).
typestringFiltra por tipo: purchase, consume, refund, recharge, adjustment o seed.

Ejemplos

cURL
curl "https://api.cfdi.express/v1/billing/transactions?limit=2&type=consume" \
  -H "Authorization: Bearer sk_live_..."

Respuesta

200 OK
{
  "object": "list",
  "data": [
    {
      "id": "txn3k9x2m6q4v1p8d7n5c0br",
      "object": "transaction",
      "livemode": true,
      "type": "consume",
      "deltaCentavos": -100,
      "balanceAfterCentavos": 48200,
      "referenceType": "invoice",
      "referenceId": "inv7k3q9x2m4v1t8p6d0n5cb",
      "note": null,
      "createdAt": "2026-08-18T17:42:11.918Z"
    },
    {
      "id": "txn8m2x6q4k1v3p9d7n5c0bt",
      "object": "transaction",
      "livemode": true,
      "type": "purchase",
      "deltaCentavos": 50000,
      "balanceAfterCentavos": 48300,
      "referenceType": "purchase",
      "referenceId": "pur5m9x2q7v1p8d3t6n0c4br",
      "note": "Stripe checkout",
      "createdAt": "2026-08-17T09:05:44.201Z"
    }
  ],
  "has_more": true
}

Errores

StatuscodeCuándo aparece
401unauthorizedFalta el header Authorization o la llave es inválida.
429rate_limitedExcediste el límite de requests por minuto de tu cuenta (300 por default). La respuesta incluye Retry-After.

Continuar