API docs

Everything you can read, change and listen to in StreamNeeds, with examples you can copy.

Getting started

Authentication

Send your key in the Authorization header as a Bearer token. Each key only sees your own data, and only for the permissions you ticked when you made it.

Authorization: Bearer bh_sk_your_api_key_here

Each endpoint also follows the plan of the feature it touches. If your plan doesn't include that feature you get a 402 with code feature_locked.

Base URL

https://streamneeds.com

Pagination

List endpoints return newest first with a nextCursor. Pass it back as ?cursor= to get the next page; when it is null you have everything. Use ?since= to fetch only what changed after a time.

Rate limits

Requests are limited per key. A 429 carries Retry-After plus X-RateLimit headers; wait that long before trying again. Send an idempotency key with money and points writes so a retry is always safe.

For uptime checks call /api/v1/health: it needs no key and costs nothing. Never poll a data endpoint to see if we are up.

Viewer identifiers

Wherever an endpoint takes a viewer, you can pass a Discord ID, a Kick username (or kick-id:12345) or a StreamNeeds viewer ID. We work out which it is.

  • 123456789012345678 · Discord ID
  • kick-id:12345 · kickusername · Kick
  • a1b2c3d4-e5f6-7890-abcd-ef1234567890 · Viewer ID

Permissions

Each key only does what you ticked when you made it. Every endpoint below names the permission it needs; a key with none of them gets a 403.

General

  • readRead general data
  • writeWrite general data

Bonus hunts

  • hunts:readRead this account's bonus-hunt feed
  • hunts:writeCreate hunts, add slots and log results
  • guesses:readRead this account's Guess the Balance results (guesses, winners, points)
  • guesses:writeOpen, close and settle Guess the Balance

Slot requests

  • slot-requests:readRead this account's slot-request feed
  • slot-requests:writeAdd, update and remove slot requests

Points

  • points:readRead point balances
  • points:writeAward/remove points

Viewers & identity

  • users:readRead user profiles (incl. casinos)
  • identity:writeExternal identity link (auto-merge Discord + Kick pushed from your own site)

Store & payouts

  • store:readRead shop catalogue
  • store:purchaseRecord shop purchases
  • store:manageAdd, edit and remove store items
  • payouts:readRead payouts you owe and have paid
  • payouts:writeCreate unpaid store payouts

Raffles

  • raffles:readRead raffles + ticket totals
  • raffles:purchaseBuy raffle tickets
  • raffles:awardAward free raffle tickets
  • raffles:manageCreate, edit, remove and draw raffles

Giveaways

  • giveaways:readRead giveaways, entrants and winners
  • giveaways:writeStart, end and draw giveaways

Polls and wheels

  • polls:readRead polls and their results
  • polls:writeStart and end polls

Clips and campaigns

  • clips:readRead clips and marked moments
  • clips:writeMark clip moments
  • campaigns:readRead sponsor campaigns and deliverable progress

Stream & overlays

  • stream:readRead your live status, streams, stream events and tips
  • alerts:writeFire overlay alerts (Twitch / YouTube / white-label)
  • casino:writeCasino extension live feed (game/balance/chat → hunt)
  • overlays:writeSwitch overlay scenes
  • pad:writePress Stream Pad buttons

Leaderboards

  • leaderboards:readRead wager leaderboard standings

Bonus hunts

Read and run your bonus hunts. Writes behave exactly like the dashboard: totals recompute from the entries, overlays and the live hunt page update instantly, Discord announcements and chat points fire as usual. Money amounts are plain numbers in the hunt's currency.

Guess the Balance

Viewers guess a hunt's final balance in chat. Guessing is one switch on your account that applies to your live hunt. Twitch and YouTube viewers are never named in API responses or webhooks — they come back as a stable `anonId` instead.

Slot requests

The games your viewers call in chat. Statuses: `pending` (queued), `added` (on the hunt), `played`, `skipped`, `archived`.

Payouts

Everything on Store → Payouts: raffle winners (`source: raffle`), giveaway winners (`source: giveaway`) and manual payouts (`source: manual` — added by hand, through the API, or by a feature such as a wheel, a wager race or Clip Rewards; that feature is in `origin`). A payout is a record of what you owe — marking it paid never moves money or points.

Store

Your points shop: the catalogue, buying on a viewer's behalf, orders and refunds. Prices and balances are in points. Orders made in chat (!buy), on your store page, in Discord or through the API all fire `store.purchase`.

Raffles

Numbered-ticket raffles. Every ticket gets a sequential number; the draw picks one ticket at random across the whole pool. Raffles can be drawn before their draw date (plans with early draws).

Points

Viewer point balances and movements. A balance is the viewer's unified total (their linked Discord and Kick balances included). Award / remove / set accept an idempotency key — send one per logical operation and a retry replays the first result (header Idempotency-Replay: true) instead of applying twice. Keys last 7 days; the same key with a different body is a 422, and one still in flight is a 409.

Viewers

A viewer is one person across Discord, Kick, Twitch and YouTube. Look them up by any linked account, or link accounts from your own site.

Giveaways

Chat giveaways (viewers type a command on Kick, Twitch, YouTube or Hype to enter) and the giveaways your bot runs in Discord. Starting, drawing and rerolling behave exactly like the dashboard: the overlay plays the draw, chat gets the winner callout and points prizes are credited straight away.

Polls

Two kinds: chat polls (the Poll overlay widget — viewers vote by typing an option number) and community polls (players with numbers, a free first vote per viewer and paid extra votes in points). Your key always sees the real counts, even while results are hidden on stream.

Stream

Your streams and what happened on them. A stream is one sitting: if you simulcast to Kick and Twitch, it is one stream with one leg per platform — the same numbers as your stream history on the dashboard. Webhooks: stream.online when you go live, stream.offline when a stream ends.

Tips and gifts

Money your viewers sent, across Kick, Twitch and YouTube. Amounts are in each platform's own unit: KICKS on Kick, BITS on Twitch and the viewer's currency for Super Chats. Anonymous supporters keep their amount but never their name. Webhooks: support.tip and support.gifted_subs as they arrive.

Clips

Your clip library and win moments. A moment is a mark on the stream ("that was a moment") — a big win, a tagged press, a sponsor deliverable. A clip is the video saved for a moment. Webhook: clip.created when a clip is saved.

Campaigns

Your sponsor campaigns and how far along each deliverable is. done is a live count — presses for count and mention deliverables, bonuses opened on the partner's games for auto_games — the same number your Stream Pad tiles and sponsor reports show.

Overlays and Stream Pad

Switch overlay scenes and press Stream Pad buttons from your own tools — the same thing a Stream Deck button does.

Wager leaderboards

Your wager races. Standings come from the casino on each board's refresh schedule; hidden players are always removed. Webhook: wager_leaderboard.updated after each refresh, with the top 10.

Casino extension

What the StreamNeeds casino extension sends while you play. Pairing the extension creates its own key with the casino:write permission, so you only need these to build your own reader. Every call works on your current live hunt.

Health

Errors

400
{
  "error": "amount: Expected number, received string",
  "code": "invalid_body"
}
401
{
  "error": "Invalid or missing API key"
}
402
{
  "error": "Feature not available on the resource owner's plan",
  "code": "feature_locked",
  "feature": "raffles_payouts"
}
403
{
  "error": "API key needs one of these scopes: payouts:read"
}
404
{
  "error": "Payout not found",
  "code": "not_found"
}
409
{
  "ok": false,
  "error": "no_open_hunt",
  "message": "No live hunt — start one first."
}
429
{
  "error": "Rate limit exceeded",
  "retryAfter": 2
}
503
{
  "error": "Service temporarily overloaded, retry shortly",
  "retryAfter": 2
}

Coming soon

These features are being built now and get their API when they launch:

  • Quests and the viewer portal
  • Game trackers and game nights
  • Lobby codes
API Documentation — StreamNeeds REST API and webhooks · StreamNeeds