Package-level declarations

Types

Link copied to clipboard
interface DtmfTool : ToolWithParameters
Link copied to clipboard
interface EndCallTool : ToolWithParameters
Link copied to clipboard
interface ExternalTool : ToolWithParameters
Link copied to clipboard
interface GhlTool : ToolWithMetaData
Link copied to clipboard
interface MakeTool : ToolWithMetaData
Link copied to clipboard
interface ManualTool : ToolWithParameters
Link copied to clipboard
@Target(allowedTargets = [AnnotationTarget.VALUE_PARAMETER])
annotation class Param(val description: String)
Link copied to clipboard
interface Parameter

This is a parameter that the function accepts.

Link copied to clipboard
interface Parameters

These are the parameters the functions accepts, described as a JSON Schema object.
See the OpenAI guide for examples, and the JSON Schema reference for documentation about the format.
Omitting parameters defines a function with an empty parameter list.

Link copied to clipboard
interface Server : ServerProperties

This is the server that will be hit when this tool is requested by the model.
All requests will be sent with the call object among other things. You can find more details in the Server URL documentation.
This overrides the serverUrl set on the org and the phoneNumber. Order of precedence: highest tool.server.url, then assistant.serverUrl, then phoneNumber.serverUrl, then org.serverUrl.

Link copied to clipboard
@Target(allowedTargets = [AnnotationTarget.FUNCTION, AnnotationTarget.PROPERTY_GETTER, AnnotationTarget.PROPERTY_SETTER])
annotation class ToolCall(val description: String = "", val name: String = "")
Link copied to clipboard
interface ToolCondition

This is a condition that the tool call arguments must meet in order for a message to be triggered.

Link copied to clipboard
interface ToolMessageComplete : ToolMessageCompleteProperties

This message is triggered when the tool call is complete.
This message is triggered immediately without waiting for your server to respond for async tool calls.
If this message is not provided, the model will be requested to respond.
If this message is provided, only this message will be spoken and the model will not be requested to come up with a response. It's an exclusive OR

Link copied to clipboard
interface ToolMessageDelayed : ToolMessageDelayedProperties

This message is triggered when the tool call is delayed.

  • The user talks with the assistant while your server is processing the request. Default is "Sorry, a few more seconds."
  • The server doesn't respond within timingMilliseconds.
  • This message is never triggered for async tool calls.

  • Link copied to clipboard
    interface ToolMessageFailed : ToolMessageFailedProperties

    This message is triggered when the tool call fails.
    This message is never triggered for async tool calls.
    If this message is not provided, the model will be requested to respond.
    If this message is provided, only this message will be spoken and the model will not be requested to come up with a response. It's an exclusive OR.

    Link copied to clipboard
    Link copied to clipboard
    interface ToolMessageStart : ToolMessageStartProperties

    This message is triggered when the tool call starts.
    This message is never triggered for async tools.
    If this message is not provided, one of the default filler messages "Hold on a sec", "One moment", "Just a sec", "Give me a moment" or "This'll just take a sec" will be used.

    Link copied to clipboard
    Link copied to clipboard
    interface Tools
    Link copied to clipboard

    This is the destination you'd like the call to be transferred to.

    Link copied to clipboard
    interface TransferTool : ToolWithServer
    Link copied to clipboard
    interface VoiceMailTool : ToolWithParameters