Get a customer's store credit balances
GET
/api/subscriptions/credits/balances
const url = 'https://api.usegro.co/api/subscriptions/credits/balances?profile_id=example';const options = { method: 'GET', headers: {Authorization: 'Bearer <token>', 'X-API-Key': '<X-API-Key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api.usegro.co/api/subscriptions/credits/balances?profile_id=example' \ --header 'Authorization: Bearer <token>' \ --header 'X-API-Key: <X-API-Key>'One balance per currency the customer has ever held credit in, in the currency’s main unit (not cents). Credit comes off their subscription renewals automatically.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”profile_id
required
string
Responses
Section titled “Responses”Media typeapplication/json
object
data
Array<object>
object
data
required
object
updated_at
string
currency_code
required
string
balance
required
number
max_per_order
number
Example generated
{ "data": [ { "data": { "updated_at": "example", "currency_code": "example", "balance": 1, "max_per_order": 1 } } ]}