Command variable usage
Command variables are placeholders in a custom command response. When someone uses the command, Synchra replaces each variable with live data.
Syntax
Section titled “Syntax”Variables use curly braces:
Some variables only display data. Others update state, set defaults, or read command input. Check each variable page for the exact behavior.
Example command
Section titled “Example command”Command name:
Command response:
When someone types !countdown, the bot replies with the remaining time until the event.
Common variables
Section titled “Common variables”| Variable | Use | Example command response |
|---|---|---|
{user} | Mention the target user or the sender. | Hello, {user}! |
{sender} | Mention the person who triggered the command. | Requested by {sender}. |
{countdown <iso_date>} | Show time left until a date. | Only {countdown 2026-07-01T18:00:00+02:00} left. |
{random.int 1 100} | Generate a random number. | Your roll: {random.int 1 100} |
{spotify.song_name} | Show the current Spotify song. | Now playing: {spotify.song_name} |
Activity variables
Section titled “Activity variables”Activity variables only work when a command is run by an activity trigger. If the same response runs from a chat message trigger, activity variables are left unchanged.
Example response:
| Variable | Use |
|---|---|
{activity.viewer_display_name} | Viewer display name. |
{activity.viewer_name} | Viewer username. |
{activity.type_display_name} | Activity type display name. |
{activity.type} | Raw activity type, such as resub or sub_gift. |
{activity.sub_type_display_name} | Activity subtype display name. |
{activity.sub_type} | Raw activity subtype. |
{activity.count} | Raw numeric activity count. |
{activity.amount} | Count adjusted for decimal places and currency. |
{activity.count_name} | Count unit, such as months, subs, or bits. |
{activity.message} | User-entered activity message text, assembled from message parts when available. |
{activity.system_message} | Platform-generated activity message, when available. |
{activity.recipient_display_name} | First gift recipient display name, when available. |
{activity.provider} | Activity provider, such as twitch or youtube. |
{activity.provider_message_id} | Provider message ID for the activity. |
{activity.created_at} | Activity time as an ISO timestamp. |
system_message comes from the platform and can differ by provider.
Reference
Section titled “Reference”| Page | Includes |
|---|---|
| Account age | Account creation age, date, and date-time |
| Activity | Activity trigger data |
| Category | Read or update the stream category |
| Channel | Channel name |
| Count | Named counters |
| Countdown | Time remaining until a date |
| Faceit | Faceit ELO and level |
| Followage | Follow duration and follow date |
| Games | Slots and roulette |
| Permit manager | Temporary link permits |
| Points | Points balances and leaderboard data |
| Quotes | Quote management and display |
| Random | Random numbers and choices |
| Sender | Command sender |
| Spotify | Song and playlist data |
| Time | Current time by timezone |
| Title | Read or update stream title |
| Uptime | Current stream uptime |
| User | Target user or sender fallback |
| Viewer stats | Watchtime and stream history |
| Weather | Weather lookup data |