Get available plans

Credentials

Retrieve the plans available to the authenticated partner. Only plans that are currently offered for selection are returned; retired plans are not.

Parameters

This endpoint takes no path, query or header parameters.

Code samples

curl

curl -X GET 'https://<partner_domain>.keep.co.il/api/public/plans' \
  -H 'Authorization: Bearer <YOUR_TOKEN>'

Node.js

const response = await fetch("https://<partner_domain>.keep.co.il/api/public/plans", {
  method: "GET",
  headers: {
    "Authorization": "Bearer <YOUR_TOKEN>",
  },
});

console.log(await response.text());

Python

import requests

response = requests.get(
    "https://<partner_domain>.keep.co.il/api/public/plans",
    headers={
        "Authorization": "Bearer <YOUR_TOKEN>",
    },
)

print(response.text)

PHP

<?php

$ch = curl_init('https://<partner_domain>.keep.co.il/api/public/plans');
curl_setopt_array($ch, [
    CURLOPT_CUSTOMREQUEST => 'GET',
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer <YOUR_TOKEN>',
    ],
]);

$response = curl_exec($ch);
curl_close($ch);

echo $response;

Responses

200 — Plans retrieved successfully (success)

Field Type Description
payload object
payload.items array
payload.items[].id string Unique identifier for the plan
payload.items[].name string Display name of the plan
payload.items[].price number Plan price in the partner's currency
{
  "payload": {
    "items": [
      {
        "id": "90abd0eb-c374-4a2b-829e-681fba0cdbee",
        "name": "PaturBasic",
        "price": 39.9
      },
      {
        "id": "29b1f228-c779-4de3-bb99-aa8e34f29ddc",
        "name": "PaturPremium",
        "price": 105
      },
      {
        "id": "3d653770-6376-40a5-b98e-17c598f1d7d8",
        "name": "MursheBasic",
        "price": 39.9
      },
      {
        "id": "c2249657-fe98-49ae-950a-3bdf28cdbfee",
        "name": "MurshePremium",
        "price": 228
      }
    ]
  }
}

401 — Unauthorized (error)

Field Type Description
statusCode integer
message string
{
  "statusCode": 401,
  "message": "Unauthorized"
}