List store credit ledger rows
GET
/api/subscriptions/credits/transactions
const url = 'https://api.usegro.co/api/subscriptions/credits/transactions';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/transactions \ --header 'Authorization: Bearer <token>' \ --header 'X-API-Key: <X-API-Key>'Every movement of store credit, newest first, with the balance after it, why and who made it. Amounts are in the currency’s main unit, not cents. Filter by profile_id or subscription_id, or leave both out for the whole store.
type: comma separatedearned,adjusted,redeemed(spent on a renewal),reversed.source: comma separatedreferral,loyalty_reward,playbook,manual,gro_agent,mcp,api,billing.page/limit: pagination (limitcapped at 100, default 25).
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”page
number
limit
number
profile_id
string
subscription_id
string
type
string
source
string
Responses
Section titled “Responses”Media typeapplication/json
object
data
required
Array<object>
object
id
required
string
created_at
string
type
required
string
currency_code
required
string
profile_id
required
string
profile
object
id
string
email
string
full_name
string
is_reversed
required
boolean
amount
required
number
balance_after
required
number
source
required
string
note
string
subscription_id
string
referral_id
string
earning_rule_id
string
shopify_order_id
string
reverses_transaction_id
string
actor_type
required
string
actor_name
string
subscription
object
number
string
id
string
order
object
number
number
id
string
meta
required
object
total
Total number of items
number
per_page
Items per page
number
current_page
Current page number
number
last_page
Last page number
number
first_page
First page number
number
first_page_url
URL for first page
string
last_page_url
URL for last page
string
next_page_url
URL for next page
string
previous_page_url
URL for previous page
string
Example
{ "data": [ { "type": "earned", "source": "referral", "reason": "goodwill", "actor_type": "user" } ]}