Skip to main content
GET
/
v1
/
bonuses
Node.js
import { PriceOS } from "priceos";
import type { MyFeatures } from "./priceos.types";

const priceos = new PriceOS<MyFeatures>(process.env.PRICEOS_API_KEY!);

const result = await priceos.bonuses.list({
  customerId: "customer_123",
  featureKey: "api_calls",
});
{
  "bonuses": [
    {
      "bonusId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "featureKey": "<string>",
      "amount": 123,
      "remainingAmount": 123,
      "createdAt": 123,
      "updatedAt": 123,
      "expiresAt": 123,
      "reason": "<string>",
      "metadata": {}
    }
  ]
}

Headers

x-api-key
string
required

API key from your PriceOS dashboard.

Query Parameters

customerId
string
required

Internal customer ID.

featureKey
string | null

Optional feature key to filter bonuses.

Response

Bonus list

Bonus list.

bonuses
object[]
required

Bonuses.