Static
argsStatic
envsStatic
errorExits the process with a bytes encoded result. This sets Data Request execution result to the bytes
Bytes encoded result, which will be sent back to the contract
Optional
code: number = POSIX_ERROR_CODEcode Exit code, defaults to 1 (POSIX compatible, 0 is success, >= 1 is error)
const error = "Failed to fetch data from https://example.com";
Process.error(Bytes.fromUtf8String(error));
Static
exitStatic
getStatic
getStatic
isStatic
isStatic
successExits the process with a bytes encoded result. This sets Data Request execution result to the bytes
Bytes encoded result, which will be sent back to the contract
const result = "{\"price\": \"10.23\"}";
Process.success(Bytes.fromUtf8String(result));
A set of methods to interact with the process in which the Oracle Program is running.