curl --request POST \
--url https://api.zenamu.com/v1/clients/{clientId}/credits \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"customEntryCount": {
"count": 10,
"validityTimeValue": 1,
"validityTimeUnit": "month"
},
"currency": "CZK",
"price": 0,
"sendEmail": false
}
'import requests
url = "https://api.zenamu.com/v1/clients/{clientId}/credits"
payload = {
"customEntryCount": {
"count": 10,
"validityTimeValue": 1,
"validityTimeUnit": "month"
},
"currency": "CZK",
"price": 0,
"sendEmail": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
customEntryCount: {count: 10, validityTimeValue: 1, validityTimeUnit: 'month'},
currency: 'CZK',
price: 0,
sendEmail: false
})
};
fetch('https://api.zenamu.com/v1/clients/{clientId}/credits', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.zenamu.com/v1/clients/{clientId}/credits",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'customEntryCount' => [
'count' => 10,
'validityTimeValue' => 1,
'validityTimeUnit' => 'month'
],
'currency' => 'CZK',
'price' => 0,
'sendEmail' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.zenamu.com/v1/clients/{clientId}/credits"
payload := strings.NewReader("{\n \"customEntryCount\": {\n \"count\": 10,\n \"validityTimeValue\": 1,\n \"validityTimeUnit\": \"month\"\n },\n \"currency\": \"CZK\",\n \"price\": 0,\n \"sendEmail\": false\n}")
req, _ := http.NewRequest("POST", 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(string(body))
}HttpResponse<String> response = Unirest.post("https://api.zenamu.com/v1/clients/{clientId}/credits")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"customEntryCount\": {\n \"count\": 10,\n \"validityTimeValue\": 1,\n \"validityTimeUnit\": \"month\"\n },\n \"currency\": \"CZK\",\n \"price\": 0,\n \"sendEmail\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.zenamu.com/v1/clients/{clientId}/credits")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"customEntryCount\": {\n \"count\": 10,\n \"validityTimeValue\": 1,\n \"validityTimeUnit\": \"month\"\n },\n \"currency\": \"CZK\",\n \"price\": 0,\n \"sendEmail\": false\n}"
response = http.request(request)
puts response.read_body{
"statusCode": 200,
"message": "Success",
"data": {
"clientId": 123,
"numberOfCredits": 510,
"validTo": "2026-10-01"
}
}{
"statusCode": 400,
"error": "Error",
"message": "dateFrom parameter is required (format: YYYY-MM-DD)"
}{
"statusCode": 401,
"error": "Error",
"message": "Missing access token. You must send your access token in the request header ('Authorization: Bearer YOUR_ACCESS_TOKEN' )"
}{
"statusCode": 403,
"error": "Error",
"message": "The Zenamu API is only available on the Ultimate tariff."
}{
"statusCode": 404,
"error": "Error",
"message": "Client not found"
}{
"statusCode": 429,
"error": "Too Many Requests",
"message": "Rate limit exceeded: up to 100 requests per minute per endpoint."
}{
"statusCode": 500,
"error": "Internal Server Error",
"message": "We apologize, but there was an error on our end. If problems persist, please contact us at [email protected]"
}Grant credits to a client
Adds credits to one client’s account and returns their new balance. Use it for reactivation campaigns, loyalty rewards, or manual corrections.
The grant is written in a single transaction. Unless you set
sendEmail to false, the client receives a notification email.
See Granting credits and passes for the end-to-end flow.
curl --request POST \
--url https://api.zenamu.com/v1/clients/{clientId}/credits \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"customEntryCount": {
"count": 10,
"validityTimeValue": 1,
"validityTimeUnit": "month"
},
"currency": "CZK",
"price": 0,
"sendEmail": false
}
'import requests
url = "https://api.zenamu.com/v1/clients/{clientId}/credits"
payload = {
"customEntryCount": {
"count": 10,
"validityTimeValue": 1,
"validityTimeUnit": "month"
},
"currency": "CZK",
"price": 0,
"sendEmail": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
customEntryCount: {count: 10, validityTimeValue: 1, validityTimeUnit: 'month'},
currency: 'CZK',
price: 0,
sendEmail: false
})
};
fetch('https://api.zenamu.com/v1/clients/{clientId}/credits', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.zenamu.com/v1/clients/{clientId}/credits",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'customEntryCount' => [
'count' => 10,
'validityTimeValue' => 1,
'validityTimeUnit' => 'month'
],
'currency' => 'CZK',
'price' => 0,
'sendEmail' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.zenamu.com/v1/clients/{clientId}/credits"
payload := strings.NewReader("{\n \"customEntryCount\": {\n \"count\": 10,\n \"validityTimeValue\": 1,\n \"validityTimeUnit\": \"month\"\n },\n \"currency\": \"CZK\",\n \"price\": 0,\n \"sendEmail\": false\n}")
req, _ := http.NewRequest("POST", 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(string(body))
}HttpResponse<String> response = Unirest.post("https://api.zenamu.com/v1/clients/{clientId}/credits")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"customEntryCount\": {\n \"count\": 10,\n \"validityTimeValue\": 1,\n \"validityTimeUnit\": \"month\"\n },\n \"currency\": \"CZK\",\n \"price\": 0,\n \"sendEmail\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.zenamu.com/v1/clients/{clientId}/credits")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"customEntryCount\": {\n \"count\": 10,\n \"validityTimeValue\": 1,\n \"validityTimeUnit\": \"month\"\n },\n \"currency\": \"CZK\",\n \"price\": 0,\n \"sendEmail\": false\n}"
response = http.request(request)
puts response.read_body{
"statusCode": 200,
"message": "Success",
"data": {
"clientId": 123,
"numberOfCredits": 510,
"validTo": "2026-10-01"
}
}{
"statusCode": 400,
"error": "Error",
"message": "dateFrom parameter is required (format: YYYY-MM-DD)"
}{
"statusCode": 401,
"error": "Error",
"message": "Missing access token. You must send your access token in the request header ('Authorization: Bearer YOUR_ACCESS_TOKEN' )"
}{
"statusCode": 403,
"error": "Error",
"message": "The Zenamu API is only available on the Ultimate tariff."
}{
"statusCode": 404,
"error": "Error",
"message": "Client not found"
}{
"statusCode": 429,
"error": "Too Many Requests",
"message": "Rate limit exceeded: up to 100 requests per minute per endpoint."
}{
"statusCode": 500,
"error": "Internal Server Error",
"message": "We apologize, but there was an error on our end. If problems persist, please contact us at [email protected]"
}Authorizations
Your secret API key (zen_live_…), sent as Authorization: Bearer <key>. Backend-to-backend only — never expose it in a browser. See Authentication.
Path Parameters
The client's numeric id, taken from the id field of GET /v1/clients. This is not the opaque _id. Malformed values and numeric prefixes return 400.
x >= 1123
Body
How many credits or entries to grant, and for how long.
Show child attributes
Show child attributes
Currency code recorded on the grant. Send the studio's configured currency, typically an ISO 4217 code such as CZK, EUR, or USD. The value is stored as sent and its format is not validated, so a typo is recorded rather than rejected. Send price: 0 for a gift.
"CZK"
What the client paid. Send 0 for a gift or a reward.
x >= 0Set to false to grant silently, with no notification email.

