Points PRO
Your store needs loyalty points turned on. Points you give here show in the customer's history like any other.
Points of a customer
GET
/customers/{key}/pointsPath
| Name | Type | Required | Description |
|---|---|---|---|
key | string | Yes | Avatar UUID (key). |
Query
| Name | Type | Required | Description |
|---|---|---|---|
cursor | string | No | The next_cursor of the previous page. |
Example
bash
curl "https://api.fastyvendor.com/api/v1/customers/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/points" \
-H "Authorization: Bearer $FASTY_KEY"js
const res = await fetch('https://api.fastyvendor.com/api/v1/customers/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/points', {
headers: {
Authorization: `Bearer ${process.env.FASTY_KEY}`,
},
})
const data = await res.json()python
import os, requests
res = requests.get(
"https://api.fastyvendor.com/api/v1/customers/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/points",
headers={"Authorization": f"Bearer {os.environ['FASTY_KEY']}"},
)
data = res.json()lsl
llHTTPRequest(API + "/customers/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/points",
[HTTP_CUSTOM_HEADER, "Authorization", "Bearer " + KEY,
HTTP_BODY_MAXLENGTH, 16384],
"");Response: 200 OK
json
{
"avatar_key": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
"balance": 31,
"earned": 31,
"spent": 0,
"moves": [
{
"id": 21,
"delta": 10,
"kind": "adjust",
"note": "Won a round",
"sale_id": null,
"created_at": "2026-11-04T18:27:03.783Z"
}
],
"next_cursor": null
}Give or take points
POST
/customers/{key}/pointsFor example, points for winning a game. Taking more than the balance stops at zero.
Send a negative delta to take points. A customer with fewer points than you take ends at zero, and delta in the answer says what really changed.
Path
| Name | Type | Required | Description |
|---|---|---|---|
key | string | Yes | Avatar UUID (key). |
Body
| Name | Type | Required | Description |
|---|---|---|---|
delta | integer | Yes | Points to add (positive) or take (negative). From -1,000,000 to 1,000,000. |
note | string | No | A note, kept in the history. Up to 120 characters. |
Example
bash
curl -X POST "https://api.fastyvendor.com/api/v1/customers/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/points" \
-H "Authorization: Bearer $FASTY_KEY" \
-H "Idempotency-Key: my-unique-id-123" \
-H "Content-Type: application/json" \
-d '{"delta":10,"note":"Won a round"}'js
const res = await fetch('https://api.fastyvendor.com/api/v1/customers/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/points', {
method: 'POST',
headers: {
Authorization: `Bearer ${process.env.FASTY_KEY}`,
'Idempotency-Key': 'my-unique-id-123',
'Content-Type': 'application/json',
},
body: JSON.stringify({"delta":10,"note":"Won a round"}),
})
const data = await res.json()python
import os, requests
res = requests.post(
"https://api.fastyvendor.com/api/v1/customers/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/points",
headers={"Authorization": f"Bearer {os.environ['FASTY_KEY']}", "Idempotency-Key": "my-unique-id-123"},
json={"delta":10,"note":"Won a round"},
)
data = res.json()lsl
llHTTPRequest(API + "/customers/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/points",
[HTTP_METHOD, "POST",
HTTP_MIMETYPE, "application/json",
HTTP_CUSTOM_HEADER, "Authorization", "Bearer " + KEY,
HTTP_CUSTOM_HEADER, "Idempotency-Key", "my-unique-id-123"],
"{\"delta\":10,\"note\":\"Won a round\"}");Response: 200 OK
json
{
"avatar_key": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
"delta": 10,
"balance": 31
}