Skip to content

Reference Script Functions Args

Kristopher Barrantes edited this page Nov 5, 2026 · 3 revisions

Arguments script functions

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.

A Run Python code step in the action editor

args.all

Gives you every variable of the running action at once, like user, message and rewardTitle.

Gives back: An object with every variable name and its value.

C#

var answer = await Cb.Call("args.all");

Python

answer = cb.args_all()

args.get

Reads one variable of the running action, like the user who triggered it.

Value In Python What to put in
name name The variable name without % signs, like "user".

Gives back: The value, or null when the action has no variable with that name.

C#

var answer = await Cb.Call("args.get", new { name = "user" });

Python

answer = cb.args_get(name="user")

args.resolve

Fills in %variables% and globals in a text, exactly like a step's settings are filled in. Handy for text you copied from a step.

Value In Python What to put in
text text The text, like "Thanks %user% for %bits% bits!".

Gives back: The text with the variables filled in. A %variable% that does not exist stays as it is.

C#

var answer = await Cb.Call("args.resolve", new { text = "Hi %user%" });

Python

answer = cb.args_resolve(text="Hi %user%")

args.set

Sets a variable of the running action. Later sub-actions can use it as %name%.

Value In Python What to put in
name name The variable name without % signs, like "winner".
value value The value to store: text, a number, true/false or a list. Leave it out to set it to empty (null).

Gives back: Nothing.

C#

var answer = await Cb.Call("args.set", new { name = "winner", value = "CoolViewer42" });

Python

answer = cb.args_set(name="winner", value="CoolViewer42")

Clone this wiki locally