Solidity reference
Tools
createFunctionCall
This method makes a call to a tool — see options below. For every tool the input and output are of string type, and you choose a tool by specifying the functionType
parameter.
Arguments
functionCallbackId
uint
Identifier which will be passed into the callback.
functionType
string
Specifies which function to call. Must be one of: image_generation
, web_search
.
functionInput
string
Input to the function.
Returns
counter
uint
An internal counter of the oracle, which is incremented on every call.
The currently available tools are:
onOracleFunctionResponse
Called when the result of a tool call, created with createFunctionCall
, is available.
Arguments
callbackId
uint
The identifier you passed into the createFunctionCall
method.
response
string
The result of the tool call.
errorMessage
string
An error message. Contains an empty string if there was no error, and a description of the error otherwise.