Submit Prepayment Balances
POST
https://api.vercel.com/v1/installations/{integrationConfigurationId}/billing/balanceSends the prepayment balances. The partner should do this at least once a day and ideally once per hour.
Use the
Use the
credentials.access_token we provided in the Upsert Installation body to authorize this request.https://api.vercel.com/v1/installations/{integrationConfigurationId}/billing/balance
const response = await fetch('https://api.vercel.com/v1/installations/integrationConfigurationId/billing/balance', { method: 'POST', headers: { 'Authorization': 'Bearer YOUR_ACCESS_TOKEN', 'Content-Type': 'application/json', }, body: JSON.stringify({ "timestamp": "2024-01-01T00:00:00Z", "balances": [ { "resourceId": "example_id", "credit": "string", "nameLabel": "Example Name", "currencyValueInCents": "123" } ] }),});
const data = await response.json();console.log(data);Response
{}AuthorizationbearerToken
Default authentication mechanism
integrationConfigurationIdstringRequired
This endpoint expects an object.
timestampstringRequired
Server time of your integration, used to determine the most recent data for race conditions & updates. Only the latest usage data for a given day, week, and month will be kept.
balancesarrayRequired