v2025.6.2
All Bundles

Run

Represents an execution run on a thread

Operations

Create

Create a run

function : Create(assistant:API.OpenAI.Assistant, thread:API.OpenAI.Thread, token:String) ~ API.OpenAI.Run

Parameters

NameTypeDescription
assistantAPI.OpenAI.Assistantthe assistant to use to execute this run
threadAPI.OpenAI.Threadthread to run
tokenStringAPI token

Return

TypeDescription
API.OpenAI.Runnewly created Run

GetCreatedAt

Unix timestamp (in seconds) of when the object instance was created

method : public : GetCreatedAt() ~ Int

Return

TypeDescription
Inttime with the object instance was created

GetFunctionCall

Get function callback information

method : public : GetFunctionCall() ~ Collection.Tuple.Triplet<String,String,String>

Return

TypeDescription
CollectionTupleTriplet<String,String,String>pair function name and calling parameters in JSON format

GetId

Get object instance API ID

method : public : GetId() ~ String

Return

TypeDescription
Stringinstance ID

GetObject

Get the object type

method : public : GetObject() ~ String

Return

TypeDescription
Stringobject type

GetStatus

The status of the run, which can be either: 'queued', 'in_progress', 'requires_action', 'cancelling', 'cancelled', 'failed', 'completed', or 'expired'.

method : public : GetStatus() ~ String

IsFunctionCall

Get function callback information

method : public : IsFunctionCall() ~ Bool

Load

Loads a run

function : Load(id:String, thread:API.OpenAI.Thread, token:String) ~ API.OpenAI.Run

Parameters

NameTypeDescription
idStringrun ID
threadAPI.OpenAI.Threadinstance associated with run
tokenStringAPI token

Return

TypeDescription
API.OpenAI.Runloaded Run

Refresh

Refreshed the run's data such as status

method : public : Refresh(token:String) ~ Bool

Parameters

NameTypeDescription
tokenStringAPI token

Return

TypeDescription
Boolnewly created Run

SubmitToolOutputs

Submits a tool's response

method : public : SubmitToolOutputs(func_response_json:JsonElement, func_callback_id:String, token:String) ~ Bool

Parameters

NameTypeDescription
func_response_jsonJsonElementresponse in JSON format
func_callback_idStringfunction callback ID
tokenStringAPI token

Return

TypeDescription
Booltrue if successful, false otherwise

ToString

String representation of the object

method : public : ToString() ~ String

Return

TypeDescription
Stringstring representation