For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Help CenterAPI KeysStatusSign In
GuidesAPI ReferenceChangelog
GuidesAPI ReferenceChangelog
  • Introduction
    • Getting started
  • Email API
  • Transactional SMS
  • Transactional WhatsApp
  • Marketing Campaigns
  • Contact Management
  • Events
    • GETGet events
    • POSTCreate an event
    • POSTCreate events in batch
  • Object Management
  • Accounts and Settings
  • Sales CRM
  • Conversations
  • Ecommerce
  • Loyalty
      • GETGet balance definition list
      • POSTCreate balance definition
      • GETGet balance definition
      • PUTUpdate balance definition
      • DELDelete balance definition
      • POSTCreate balance limits
      • GETGet balance limits
      • DELDelete balance limit
      • PUTUpdates balance limit
      • GETGet subscription balances
      • POSTCreate subscription balances
      • GETGet balance list
      • POSTCreate new transaction
      • POSTComplete transaction
      • POSTCancel transaction
      • POSTCreate balance order
      • GETGet Active Balances API
      • GETGet Transaction History API
LogoLogo
Help CenterAPI KeysStatusSign In
LoyaltyBalance

Get balance list

GET
https://api.brevo.com/v3/loyalty/balance/programs/:pid/contact-balances
GET
/v3/loyalty/balance/programs/:pid/contact-balances
1import { BrevoClient } from "@getbrevo/brevo";
2
3async function main() {
4 const client = new BrevoClient({
5 apiKey: "YOUR_API_KEY_HERE",
6 });
7 await client.balance.getContactBalances("pid", {
8 balanceDefinitionId: "balanceDefinitionId",
9 });
10}
11main();
1{
2 "balanceDefinitionId": "string",
3 "balances": [
4 {
5 "contactId": 1,
6 "loyaltySubscriptionId": "string",
7 "updatedAt": "string",
8 "value": 1.1
9 }
10 ],
11 "count": 1,
12 "loyaltyProgramId": "string"
13}
Returns contact balances for a given balance definition across all subscriptions.
Was this page helpful?
Previous

Create new transaction

Next
Built with

Authentication

api-keystring

The API key should be passed in the request headers as api-key for authentication.

Path parameters

pidstringRequiredformat: "uuid"
Loyalty Program Id

Query parameters

includeInternalbooleanOptional
Include balances tied to internal definitions.
limitintegerOptional1-500
Limit the number of records returned
offsetintegerOptional>=0
Skip a number of records
sortenumOptional
Sort order
Allowed values:
sortFieldenumOptional
Field to sort by
Allowed values:
balanceDefinitionIdstringRequiredformat: "uuid"

Balance Definition ID (required)

Response

Successful retrieval of contact balance
balanceDefinitionIdstring
balanceslist of objects
countinteger
loyaltyProgramIdstring

Errors

401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
422
Unprocessable Entity Error
500
Internal Server Error