Get Product Accounts
GET/api/products/:product/accounts
The GL account one product posts to for each account type, and where it comes from — product override, account rule or company default.
accounting:readGrant this scope to your token under Settings → Developer → Personal Access Tokens.
Authentication: Requires Bearer token with the accounting:read scope.
Each account type (sales, cogs, inventory, inventory_in_transit, accrued_purchases, discount) returns:
account—{id, code, name, type, is_archived}the product posts to at product level, ornull.source— why:product_override(the product's own account),rule(an account rule),company_default, orunmapped(no account).rule—{id, name}of the rule that matched for this type, ornull.override_account_id— the product's own override, whether or not it won.rule_would_apply— a rule sets this type for the product (so clearing the override would hand it to that rule);rule_accountis that rule's account.detail— an explanatory note, e.g. that a sales channel can still set its own Sales, COGS or Discount account for orders on that channel.
Request
Responses
- 200
- 401
- 403
- 404
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Not Found
Response Headers
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.