Repository navigation
Reference Script Functions Streamelements
Also on the Cuebot Docs site.
Functions for C# (Cb.Call) and Python (a cb method each, or cb.call). See Script functions for how to use them.
Gives a viewer StreamElements loyalty points. Use a minus number to take points away. Needs your StreamElements token; fails with an error otherwise.
| Value | In Python | What to put in |
|---|---|---|
user |
user |
The viewer's name, like "CoolViewer". Needed. |
amount |
amount |
How many points to add, like 100. Use a minus number, like -50, to take points away. |
Gives back: The viewer's new points total.
C#
var answer = await Cb.Call("streamelements.addUserPoints", new { user = "CoolViewer", amount = 100 });Python
answer = cb.streamelements_add_user_points(user="CoolViewer", amount=100)Gets the viewers with the most StreamElements loyalty points. Needs your StreamElements token; fails with an error otherwise.
| Value | In Python | What to put in |
|---|---|---|
count |
count |
Optional. How many people to get. Default 5. |
Gives back: A list of the viewers with the most points. Each has user and points.
C#
var answer = await Cb.Call("streamelements.getPointsLeaderboard", new { count = 10 });Python
answer = cb.streamelements_get_points_leaderboard(count=10)Gets the viewers who tipped you the most on StreamElements. Needs your StreamElements token; fails with an error otherwise.
| Value | In Python | What to put in |
|---|---|---|
count |
count |
Optional. How many people to get. Default 5. |
Gives back: A list of the top tippers. Each has user and total (how much they tipped).
C#
var answer = await Cb.Call("streamelements.getTipLeaderboard", new { count = 3 });Python
answer = cb.streamelements_get_tip_leaderboard(count=3)Gets your latest StreamElements tips. Needs your StreamElements token; fails with an error otherwise.
| Value | In Python | What to put in |
|---|---|---|
count |
count |
Optional. How many tips to get. Default 5. |
Gives back: A list of tips. Each has user, amount, currency, formattedAmount (like "$5.00"), message and createdAt.
C#
var answer = await Cb.Call("streamelements.getTips", new { count = 5 });Python
answer = cb.streamelements_get_tips(count=5)Looks up how many StreamElements loyalty points a viewer has. Needs your StreamElements token on the Donations page; fails with an error otherwise.
| Value | In Python | What to put in |
|---|---|---|
user |
user |
The viewer's name, like "CoolViewer". A leading @ is fine. Needed. |
Gives back: user, points (now), pointsAllTime and rank.
C#
var answer = await Cb.Call("streamelements.getUserPoints", new { user = "CoolViewer" });Python
answer = cb.streamelements_get_user_points(user="CoolViewer")Checks whether Cuebot is connected to StreamElements right now.
Gives back: true while connected, otherwise false.
C#
var answer = await Cb.Call("streamelements.isConnected");Python
answer = cb.streamelements_is_connected()Fakes a StreamElements event inside Cuebot, so you can test your triggers. Nothing is sent to StreamElements and it works without a connection.
| Value | In Python | What to put in |
|---|---|---|
kind |
kind |
Optional. Which event: "tip", "merch" or "redemption". Default "tip". |
Gives back: true when the test event was sent, false when the kind is unknown.
C#
var answer = await Cb.Call("streamelements.sendTestEvent", new { kind = "tip" });Python
answer = cb.streamelements_send_test_event(kind="tip")Cuebot by Tech Daddy Digital · MIT license · Privacy
Cuebot Docs (the same pages, nicer to read)
- Home
- Start here
-
Guides
- Chat commands
- Overlays and alerts
- Writing your own overlay widgets
- Text-to-speech
- Music and now playing
- Points, store and giveaways
- Subathons and goals
- Stream apps and devices
- VTuber apps
- Stream Deck
- The phone app
- Donations and integrations
- Discord bot
- The setup assistant and AI tools
- The assistant on your own computer
- Moving from Streamer.bot
- Cuebot's servers
- Writing code (C# and Python)
- Python in detail
- Using your own code editor
- Controlling Cuebot from other programs
- Backups and your data
- Linux
- Command-line options
- Troubleshooting
- What's experimental
- Reference
