# Reward Balance

Reward Balances summarizes the Rewards in someone's account.

## List reward balances

> Looks up the balance for all rewards of the same type and units.

```json
{"openapi":"3.1.0","info":{"title":"impact.com API - Reward Balance","version":"1.0.0"},"tags":[{"name":"Reward Balance","description":"Reward Balances summarizes the Rewards in someone's account."}],"servers":[{"url":"https://app.referralsaasquatch.com/api/v1"}],"security":[{"APIKey":[]},{"UserJWT":[]}],"components":{"securitySchemes":{"APIKey":{"type":"http","scheme":"basic","description":"Authorize your requests using a tenant's API Key. Use this method of security only in server-to-server interactions."},"UserJWT":{"type":"apiKey","in":"header","name":"X-SaaSquatch-User-Token","description":"Authorize your requests using a JWT (JSON Web Token) for a given user. Useful for client-server authorization, such as the Mobile and Web SDKs. Used in Open Endpoints."}},"schemas":{"RewardBalance":{"description":"Details of the balance of several individual rewards.","properties":{"type":{"type":"string","description":"The type of reward.","enum":["PCT_DISCOUNT","CREDIT","FUELTANK"]},"unit":{"type":"string","description":"An identifier for the unit of the reward. E.g. `\"CENTS\"`, `\"freemb\"`, `\"freemonth\"`. For `PCT_DISCOUNT` this is `\"%\"`.`"},"count":{"type":"integer","description":"\"The number of rewards earned. Usually is equal to the number of successful referrals made. E.g. An account has $80 of credit due to the referral program. $60 from making referrals, $20 from being referred. The count would be 4 rewards, each worth $20. Only works for `CREDIT`\""},"totalAssignedCredit":{"type":"integer","description":"The total assignedCredit for all reward credits of the same unit type. Only works with types: `CREDIT`"},"totalRedeemedCredit":{"type":"integer","description":"The total redeemedCredit for all reward credits of the same unit type. Only works with types: `CREDIT`"},"totalPendingCredit":{"type":"integer","description":"The total credit that is pending and not yet available. Only works with types: `CREDIT`"},"totalExpiredCredit":{"type":"integer","description":"The total credit that has expired. Only works with types: `CREDIT`"},"totalCancelledCredit":{"type":"integer","description":"The total credit that has been cancelled. Only works with types: `CREDIT`"},"totalDiscountPercent":{"type":"integer","description":"The total discountPercent from all rewards. Only works with types: `PCT_DISCOUNT`"},"referredDiscountPercent":{"type":"integer","description":"The total discountPercent from rewards with `rewardSource = REFERRED` Only works with types: `PCT_DISCOUNT`"},"referrerDiscountPercent":{"type":"integer","description":"The total discountPercent from rewards with `rewardSource = FRIEND_SIGNUP` Only works with types: `PCT_DISCOUNT`"},"totalFuelTankCodes":{"type":"integer","description":"The number of earned fueltank rewards. Only works with type: `FUELTANK`"}}},"Error":{"properties":{"statusCode":{"description":"The HTTP status code of the error","type":"integer","format":"int32"},"message":{"description":"The human-readable description of what went wrong. Use this to help you debug.","type":"string"},"apiErrorCode":{"description":"A machine-readable error code","type":"string"},"rsCode":{"description":"A secondary machine-readable error code","type":"string"}}}},"responses":{"GeneralError":{"description":"Unexpected Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"paths":{"/{tenant_alias}/reward/balance":{"get":{"summary":"List reward balances","description":"Looks up the balance for all rewards of the same type and units.","operationId":"listRewardBalances","tags":["Reward Balance"],"parameters":[{"name":"tenant_alias","in":"path","description":"Tenant being referenced. E.g. `\"aboih12h16t\"` or `\"test_abo912126tastastt\"`","required":true,"schema":{"type":"string"}},{"name":"accountId","in":"query","description":"The ID of the account to look up.","required":true,"schema":{"type":"string"}},{"name":"userId","in":"query","description":"Filters rewards by `user.id`.","schema":{"type":"string"}},{"name":"rewardTypeFilter","in":"query","description":"Filters rewards by `type`.","schema":{"type":"string","enum":["PCT_DISCOUNT","CREDIT","FUELTANK"]}}],"responses":{"200":{"description":"A list of reward balances","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RewardBalance"}}}}},"default":{"$ref":"#/components/responses/GeneralError"}}}}}}
```

## Debit a reward balance

> Used to redeem the credit earned from a referral program. Permanently debits an account balance. Works with: \`CREDIT\`.

```json
{"openapi":"3.1.0","info":{"title":"impact.com API - Reward Balance","version":"1.0.0"},"tags":[{"name":"Reward Balance","description":"Reward Balances summarizes the Rewards in someone's account."}],"servers":[{"url":"https://app.referralsaasquatch.com/api/v1"}],"security":[{"APIKey":[]},{"UserJWT":[]}],"components":{"securitySchemes":{"APIKey":{"type":"http","scheme":"basic","description":"Authorize your requests using a tenant's API Key. Use this method of security only in server-to-server interactions."},"UserJWT":{"type":"apiKey","in":"header","name":"X-SaaSquatch-User-Token","description":"Authorize your requests using a JWT (JSON Web Token) for a given user. Useful for client-server authorization, such as the Mobile and Web SDKs. Used in Open Endpoints."}},"schemas":{"RewardBalanceDebitRequest":{"description":"A request to debit a Reward Balance","required":["accountId","unit","amount"],"properties":{"accountId":{"type":"string","description":"The ID of the account to be debitted."},"unit":{"type":"string","description":"The type of credit to be debitted. E.g. \"free-months\" or \"cents\""},"amount":{"type":"integer","description":"The amount of credit to be debitted."}}},"RewardDebitResponse":{"description":"Details about a successful Reward Balance Debit transaction.","properties":{"creditRedeemed":{"type":"integer","description":"The amount of credit that was just debitted."},"creditAvailable":{"type":"integer","description":"The remaining credit in this account of the same unit type."},"unit":{"type":"string","description":"The type of credit that was just debitted."}}},"Error":{"properties":{"statusCode":{"description":"The HTTP status code of the error","type":"integer","format":"int32"},"message":{"description":"The human-readable description of what went wrong. Use this to help you debug.","type":"string"},"apiErrorCode":{"description":"A machine-readable error code","type":"string"},"rsCode":{"description":"A secondary machine-readable error code","type":"string"}}}},"responses":{"GeneralError":{"description":"Unexpected Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"paths":{"/{tenant_alias}/credit/bulkredeem":{"post":{"summary":"Debit a reward balance","description":"Used to redeem the credit earned from a referral program. Permanently debits an account balance. Works with: `CREDIT`.","operationId":"debitRewardBalance","tags":["Reward Balance"],"parameters":[{"name":"tenant_alias","in":"path","description":"Tenant being referenced. E.g. `\"aboih12h16t\"` or `\"test_abo912126tastastt\"`","required":true,"schema":{"type":"string"}}],"requestBody":{"description":"Details of the debit","required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RewardBalanceDebitRequest"}}}},"responses":{"200":{"description":"Balance debitted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RewardDebitResponse"}}}},"default":{"$ref":"#/components/responses/GeneralError"}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://integrations.impact.com/brand-api-reference/advocate-api-reference-v1/reference/reward-balance-overview/reward-balance.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
