AssistantRequestUtils

Utility functions for assistant requests.

Properties

Link copied to clipboard
val JsonElement.controlUrl: String

Extract the controlUrl value from a JsonElement.

Link copied to clipboard
val JsonElement.functionName: FunctionName

Extract the function name from a function call from a JsonElement.

Link copied to clipboard
val JsonElement.functionParameters: JsonElement

Extract the function parameters from a function call from a JsonElement.

Link copied to clipboard
val JsonElement.id: String

Extract the id from a JsonElement.

Link copied to clipboard
val JsonElement.listenUrl: String

Extract the listenUrl value from a JsonElement.

Link copied to clipboard
val JsonElement.messageCallId: String

Extract the message call id from a JsonElement.

Link copied to clipboard
val JsonElement.phoneNumber: String

Extract the phone number from a JsonElement.

Link copied to clipboard
val JsonElement.requestType: String

Extract the request type from a JsonElement.

Link copied to clipboard
val JsonElement.statusUpdateError: String

Extract the assistant request error message from a status update message.

Link copied to clipboard
val JsonElement.toolCallArguments: JsonElement

Extract the tool call arguments from a JsonElement.

Link copied to clipboard
val JsonElement.toolCallName: FunctionName

Extract the tool call name from a JsonElement.

Link copied to clipboard
val JsonElement.webCallUrl: String

Extract the webCallUrl value from a JsonElement.

Functions

Link copied to clipboard
fun JsonElement.hasStatusUpdateError(): Boolean

Check if the JsonElement has a status update error message.

Link copied to clipboard
fun JsonElement.isAssistantIdResponse(): Boolean

Check if the JsonElement is an assistant id response.

Link copied to clipboard
fun JsonElement.isAssistantResponse(): Boolean

Check if the JsonElement is an assistant response.

Link copied to clipboard
fun JsonElement.isSquadIdResponse(): Boolean

Check if the JsonElement is a squad id response.

Link copied to clipboard
fun JsonElement.isSquadResponse(): Boolean

Check if the JsonElement is a squad response.