REST API and webhooks
Create API keys and webhooks in the dashboard under Integrations. Base URL: https://lumenaproductions.com/snaployaltykit/api/v1
Authentication
Send Authorization: Bearer slk_.... Keys are shown once and stored hashed.
Endpoints
| Request | What it does |
|---|---|
POST /members | Enroll a customer: {"program":"rewards","name":"Alex","email":"alex@example.com"}. Returns the code and wallet links. |
GET /members/{code} | Balance and rewards. |
POST /members/{code}/award | Stamps or points. Body: {"stamps":1}, {"points":50} or {"spend_cents":4200}. Requires an Idempotency-Key header; repeating a key returns the first result. |
POST /members/{code}/redeem | Redeem a reward. Body: {"reward":0} (index in the program's reward list). |
Webhooks
Events: member.enrolled</code>, <code>stamp.added</code>, <code>points.awarded</code>, <code>reward.earned</code>, <code>reward.redeemed. Each delivery is a JSON POST with headers X-SLK-Event, X-SLK-Timestamp and X-SLK-Signature: sha256=HMAC_SHA256(secret, timestamp + "." + body). Reply with any 2xx status; failures retry with increasing delays up to 6 attempts.
Zapier and Make: use the "Webhooks by Zapier" Catch Hook trigger (or Make "Custom webhook"), paste its URL as a webhook endpoint in Integrations, and choose the events you want.