> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.perkss.io/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.perkss.io/_mcp/server.

# List loyalty programs

GET https://api-gateway.perkss.io/api/v1/loyalty-programs

Returns the company's loyalty program(s) with their type-specific parameters. Companies run a single active program today (the list shape is future-proofing): `type` tells you whether customers earn cashback or stamps, and exactly one of `cashback`/`stamps` carries the configuration. Read it once at integration setup to know which loyalty-state fields matter.

Reference: https://docs.perkss.io/api-reference/perkss-partner-api/loyalty-programs/loyalty-programs-list

## Authentication

- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Response

### 200

- `items` (list of LoyaltyProgram, required) — The company's loyalty programs (unpaginated).

## Errors

### 401 Unauthorized Error

Missing, invalid, expired, or revoked access token. Codes: `AUTH.MISSING_BEARER_TOKEN`, `AUTH.INVALID_TOKEN`, `API_AUTH.TOKEN_REVOKED`. Obtain a fresh token at `POST /api/v1/auth/token`.

- `error` (ErrorBody, required)

### 429 Too Many Requests Error

`RATE_LIMIT.EXCEEDED` — reads 600/min per API key (default). Honour `Retry-After` before retrying.

- `error` (ErrorBody, required)

### 503 Service Unavailable Error

`API_AUTH.DENYLIST_UNAVAILABLE` — transient auth-infrastructure outage; retry after `Retry-After` seconds.

- `error` (ErrorBody, required)

## Types

### LoyaltyProgram

- `id` (string, required)
- `type` (enum, required) — Program kind — determines which config block is set and how loyalty state fields behave.
  - Allowed values: `cashback`, `stamps`
- `createdAt` (string, required) — ISO 8601 creation timestamp.
- `cashback` (CashbackProgramConfig, required, nullable) — Set when `type` is 'cashback'; null otherwise.
- `stamps` (StampProgramConfig, required, nullable) — Set when `type` is 'stamps'; null otherwise.

### ErrorBody

- `code` (string, required) — Machine-readable code, namespaced `<DOMAIN>.<NAME>`. Stable: branch on this, never on `message`.
- `message` (string, required) — Human-readable explanation. Not stable across releases — never branch on it.
- `requestId` (string, required) — Correlation id for this request — quote it when contacting support.
- `httpStatus` (double, required) — The response's HTTP status, mirrored into the body.
- `context` (map from string to any, optional) — Optional structured detail — e.g. `validation` messages on a 400, `failureReason` on a 422 rejected write.

### CashbackProgramConfig

- `percent` (double, required) — Cashback earned per purchase, as a percentage of the amount.
- `welcomeCashback` (double, required) — Welcome bonus credited on enrollment, in cents.
- `milestoneCents` (double, required) — Spend milestone (cents) that unlocks redemption on gated programs; 0 = open mode (any-amount redemption).
- `redemptionMode` (enum, required) — Gated mode only: 'chunks' or 'partial'; empty string for open mode.
  - Allowed values: `chunks`, `partial`, ``

### StampProgramConfig

- `stampGoal` (double, required) — Stamps that complete a card and bank one reward.
- `welcomeStamps` (double, required) — Welcome stamps credited on enrollment.
- `rewardName` (string, required)
- `rewardDescription` (string, required)

## Examples

**Request**

```json
{}
```

**Response**

```json
{
  "items": [
    {
      "id": "2f7e4c9a-1d5b-4a8e-9c3f-6b0d8e2a5c14",
      "type": "cashback",
      "createdAt": "2026-05-12T09:00:00.000Z",
      "cashback": {
        "percent": 5,
        "welcomeCashback": 500,
        "milestoneCents": 20000,
        "redemptionMode": "chunks"
      },
      "stamps": null
    }
  ]
}
```

**SDK Code**

```python
import requests

url = "https://api-gateway.perkss.io/api/v1/loyalty-programs"

payload = {}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.get(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api-gateway.perkss.io/api/v1/loyalty-programs';
const options = {
  method: 'GET',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api-gateway.perkss.io/api/v1/loyalty-programs"

	payload := strings.NewReader("{}")

	req, _ := http.NewRequest("GET", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api-gateway.perkss.io/api/v1/loyalty-programs")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://api-gateway.perkss.io/api/v1/loyalty-programs")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api-gateway.perkss.io/api/v1/loyalty-programs', [
  'body' => '{}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api-gateway.perkss.io/api/v1/loyalty-programs");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api-gateway.perkss.io/api/v1/loyalty-programs")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```