SmartGare
API referenceEndpoints

Record how a payout was paid

Attests that the exact payout was paid outside SmartGare by bank transfer or wallet, with the outside reference and the moment it was paid, under one stable payment reference. The amount, currency and carrier are the payout's. The payout then reads paid; the same reference with the same facts answers the payment kept, anything else on a paid payout is refused. **Required permission:** `billing.payout:pay`

POST/billing/v1/payouts/{id}/payment

Attests that the exact payout was paid outside SmartGare by bank transfer or wallet, with the outside reference and the moment it was paid, under one stable payment reference. The amount, currency and carrier are the payout's. The payout then reads paid; the same reference with the same facts answers the payment kept, anything else on a paid payout is refused.

Required permission: billing.payout:pay

AuthorizationBearer <token>

In: header

Path Parameters

id*string

Payout id

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

body*RecordPayoutPaymentRequest

Response Body

*/*

*/*

*/*

curl -X POST "https://example.com/billing/v1/payouts/string/payment" \  -H "Content-Type: application/json" \  -d '{    "external_reference": "string",    "method": "CASH",    "paid_at": "2019-08-24T14:15:22Z",    "payment_reference": "string"  }'
{  "amount": 0,  "carried_count": 0,  "carried_total": 0,  "carrier_id": "string",  "charges": [    {      "amount": 0,      "bases": [        "string"      ],      "charge_id": "string",      "charge_revision": 0,      "closed_at": "2019-08-24T14:15:22Z",      "departure_at": "2019-08-24T14:15:22Z",      "departure_id": "string",      "vehicle_cycle_id": "string",      "vehicle_id": "string",      "vehicle_plate": "string"    }  ],  "charges_count": 0,  "charges_total": 0,  "corrections": [    {      "amount": 0,      "approved_at": "2019-08-24T14:15:22Z",      "approved_by": "string",      "charge_id": "string",      "correction_request_id": "string",      "reason": "string",      "vehicle_cycle_id": "string"    }  ],  "corrections_count": 0,  "corrections_total": 0,  "currency": "string",  "evidence_kind": "string",  "external_reference": "string",  "id": "string",  "late_refunds_count": 0,  "late_refunds_total": 0,  "late_sales_count": 0,  "late_sales_total": 0,  "paid_at": "2019-08-24T14:15:22Z",  "payment_method": "string",  "payment_recorded_at": "2019-08-24T14:15:22Z",  "payment_recorded_by": "string",  "payment_reference": "string",  "payment_register_id": "string",  "period_ends_at": "2019-08-24T14:15:22Z",  "period_id": "string",  "period_reference": "string",  "period_starts_at": "2019-08-24T14:15:22Z",  "produced_at": "2019-08-24T14:15:22Z",  "produced_by": "string",  "proofs_not_kept": [    "string"  ],  "refunds_count": 0,  "refunds_total": 0,  "sales_count": 0,  "sales_total": 0,  "statement_number": "string",  "status": "string"}