Api
List Reward Terms
List the reward terms versions of a benefit rule, newest first. Needs the programs:read key permission.
Authorization
WorkspaceApiKey X-Api-Key<token>
Workspace-owned Better Auth API key of one environment (Sandbox or Live); it authorizes the Projects of that environment in its Workspace. A Project of the other environment returns 403 ENVIRONMENT_MISMATCH. Never expose it in the browser.
In: header
Path Parameters
ruleId*string
Match
\SLength
1 <= length <= 512Query Parameters
projectId*string
Length
1 <= length <= 128Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/v1/benefit-rules/string/terms?projectId=string"{ "success": true, "data": [ { "id": "string", "createdAt": "string", "updatedAt": "string", "projectId": "string", "ruleId": "string", "programId": "string", "beneficiaryRole": "referrer", "benefitKind": "cash", "version": -9007199254740991, "publishedAt": "string", "effectiveAt": "string", "enabled": true, "calculation": "fixed", "fixedAmountMinor": "string", "currency": "string", "currencyExponent": -9007199254740991, "rateBps": -9007199254740991, "durationMode": "once", "durationMonths": -9007199254740991, "customUnitId": "string", "unit": { "key": "string", "name": "string", "namePlural": "string" }, "quantity": -9007199254740991, "validityDays": -9007199254740991, "maxRewardsPerBeneficiary": -9007199254740991, "roundingPolicy": "half_up", "refundPolicy": "proportional", "author": "string", "changeNote": "string" } ]}