API docs navigation
Getting Started
QuestionStock serves approved question content from its shared library. The first-party product also lets creators play and share quizzes online, but this guide is for API builders who want to own the runtime themselves. Use it to create API keys, validate auth, and make your first integration request.
QuestionStock includes first-party quiz play in its own product, but the Business API is a content API rather than a gameplay backend. It delivers question content and supporting metadata while your app remains responsible for players, attempts, submissions, timers, scores, leaderboards, multiplayer rooms, and session logic.
1. Create an API key
In the API console, open /account/api and create a key for your personal Business workspace. Key values are shown once and stored hashed. Keep them server-side only.
2. Check API status
Validate auth and entitlement before wiring full workflows.
Status check
bashcurl --request GET \
--url 'https://questionstock.com/api/v1/status' \
--header 'Authorization: Bearer qsk_v1_your_api_key'3. Deliver your first questions
Questions are already prepared and moderated. Delivery is designed to be immediate and returns full question content in one response.
Deliver questions
bashcurl --request POST \
--url 'https://questionstock.com/api/v1/questions' \
--header 'Authorization: Bearer qsk_v1_your_api_key' \
--header 'Content-Type: application/json' \
--data '{
"limit": 1,
"categoryIds": ["<category_id>"],
"difficulty": "mixed",
"imageRule": "optional",
"deliveryKey": "presentation_run_001"
}'4. Read the contract details
- Review Content Delivery before you wire scoring, answer reveal, repeat handling, or images.
- Review Production Readiness before launch so your retry and quota handling match the runtime.
5. Production checklist
- Keep keys server-side only and rotate regularly.
- Implement retries with jitter for
429and5xxresponses. - Treat
409 insufficient_stockas a constraint issue, not a hot-loop retry signal. - Poll async suggestion resources instead of blocking requests.
- Pin to `/api/v1/*` endpoints and monitor docs for updates.