curl --request POST \
--url https://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"tier": "gold"
}'import requests
url = "https://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier"
payload = { "tier": "gold" }
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({tier: 'gold'})
};
fetch('https://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier', 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://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier",
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([
'tier' => 'gold'
]),
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://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier"
payload := strings.NewReader("{\n \"tier\": \"gold\"\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://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"tier\": \"gold\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier")
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 \"tier\": \"gold\"\n}"
response = http.request(request)
puts response.read_body{
"lifted": true,
"rewards": {
"customer": "user-1842",
"xp": 20000,
"tier": {
"id": "gold",
"name": "Gold",
"xp": 20000
},
"next_tier": {
"id": "emerald",
"name": "Emerald",
"xp": 100000,
"xp_needed": 80000
},
"next_milestone": {
"xp": 40000,
"xp_needed": 20000,
"pack_type": "silver",
"pack_name": "Silver"
},
"unopened_reward_packs": 9
}
}{
"error": "tier must be one of bronze, silver, gold, emerald, diamond, sapphire, ruby, obsidian",
"code": "BAD_TIER"
}{
"error": "Missing or malformed API key"
}{
"error": "Rewards are not turned on for this program. Ask your CatchBack contact.",
"code": "REWARDS_NOT_ENABLED"
}{
"error": "Too many requests. Slow down.",
"code": "RATE_LIMITED",
"retry_after_seconds": 23
}{
"error": "Something went wrong. Retrying is safe: send the same Idempotency-Key if the request had one."
}{
"error": "Could not load the partner program; try again."
}Set a customer's tier
non-crypto programs with rewards on only. Rate limit: 30 a minute, shared with Create an order, Sell back a customer’s card and Create a customer shipment. Customer rewards.
Starts a customer at a tier, for your own VIPs. Upward only: the customer’s XP rises to the tier’s floor, and they get every tier and milestone pack up to it, the tier itself included, as if they had climbed there (lifting to Gold grants 9 reward packs, each with its own reward.granted webhook). Each pack is charged only when opened. Their next rewards come from there. Works before their first order. A customer already at or above the tier is unchanged (lifted: false) and gets nothing more. The lift itself charges nothing.
curl --request POST \
--url https://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"tier": "gold"
}'import requests
url = "https://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier"
payload = { "tier": "gold" }
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({tier: 'gold'})
};
fetch('https://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier', 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://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier",
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([
'tier' => 'gold'
]),
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://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier"
payload := strings.NewReader("{\n \"tier\": \"gold\"\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://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"tier\": \"gold\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.catchbackcards.com/api/partner/v2/customers/{customer}/tier")
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 \"tier\": \"gold\"\n}"
response = http.request(request)
puts response.read_body{
"lifted": true,
"rewards": {
"customer": "user-1842",
"xp": 20000,
"tier": {
"id": "gold",
"name": "Gold",
"xp": 20000
},
"next_tier": {
"id": "emerald",
"name": "Emerald",
"xp": 100000,
"xp_needed": 80000
},
"next_milestone": {
"xp": 40000,
"xp_needed": 20000,
"pack_type": "silver",
"pack_name": "Silver"
},
"unopened_reward_packs": 9
}
}{
"error": "tier must be one of bronze, silver, gold, emerald, diamond, sapphire, ruby, obsidian",
"code": "BAD_TIER"
}{
"error": "Missing or malformed API key"
}{
"error": "Rewards are not turned on for this program. Ask your CatchBack contact.",
"code": "REWARDS_NOT_ENABLED"
}{
"error": "Too many requests. Slow down.",
"code": "RATE_LIMITED",
"retry_after_seconds": 23
}{
"error": "Something went wrong. Retrying is safe: send the same Idempotency-Key if the request had one."
}{
"error": "Could not load the partner program; try again."
}Authorizations
Your API key, sent as a bearer token, with the scope nft:orders. A production key starts cb_live_ and works only at https://catchbackcards.com; a sandbox key starts cb_test_ and works only at https://sandbox.catchbackcards.com (production refuses one with 401 SANDBOX_KEY). Keep it on your servers: never in a browser, app or wallet. Use a separate key per environment. A request from a country on our sanctions list gets a 403 with Access denied, whether or not it has a valid key. See Authentication and keys.
Path Parameters
Your own id for the customer, as you sent it as customer on Create an order. 1-128 characters of A-Za-z0-9_.:-, not dots alone; never personal data. Case-sensitive.
Your own id for a customer on a non-crypto program, 1-128 characters of A-Za-z0-9_.:-, not dots alone. Use something stable that is not personal data (your internal user id, never an email address or phone number). Ids are yours alone. Leading and trailing spaces are trimmed, and ids are case-sensitive (User-1 and user-1 are two customers).
^(?!\.+$)[A-Za-z0-9_.:-]{1,128}$"user-1842"

