Quick Start
From zero to your first API call in 4 steps. Total time: ~5 minutes.
1
Create an API Key
Go to the API Keys page and create a new key. Pick the scopes you need — the one-click "Read-only" preset (includes metrics:read) is the safest start for AI/Claude use; add write scopes only when you need them. Copy the key immediately — it is shown only once.
2
Make Your First API Call
Use the key to list your stores. Replace the placeholder with your actual API key.
curl -X GET https://flash.socialhub.ai/api/v2/stores \
-H "Authorization: Bearer fl_live_your_key_here" \
-H "Content-Type: application/json"
# Expected response:
# { "stores": [...], "total": 2 }3
Query a Member
Fetch the list of loyalty members. Add query parameters to filter by status or paginate results.
curl -X GET "https://flash.socialhub.ai/api/v2/members?status=active&limit=5" \
-H "Authorization: Bearer fl_live_your_key_here"
# Expected response:
# {
# "members": [
# { "id": "m_abc123", "name": "Alice", "status": "active", "points_balance": 1200 }
# ],
# "total": 42
# }4
Award Points
Use a POST request to award loyalty points to a member. The response includes the new balance.
curl -X POST https://flash.socialhub.ai/api/v2/members/m_abc123/points \
-H "Authorization: Bearer fl_live_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"amount": 500,
"description": "Welcome bonus"
}'
# Expected response:
# { "transactionId": "txn_xyz", "balance": 1700 }What's next?
- API Reference — Explore all 25 endpoints with parameters and response schemas.
- MCP Guide — Connect SocialHub to Claude Code, Claude Desktop, or Cursor for AI-powered management and natural-language metric queries.
- OpenAPI Spec — Download the machine-readable JSON specification.