Constructs a new CurveFinanceTask.
Optionalproperties: ICurveFinanceTaskProperties to set
Required. Specifies which blockchain to use when reading information from Curve Finance.
The number of decimal places to include in the returned price value.
The on-chain address of the Curve Finance pool to fetch pricing data from.
Optional. The RPC endpoint to use for blockchain requests. If not specified, a default RPC will be used which may have rate limits.
Converts this CurveFinanceTask to JSON.
JSON object
StaticcreateCreates a new CurveFinanceTask instance using the specified properties.
Optionalproperties: ICurveFinanceTaskProperties to set
CurveFinanceTask instance
StaticdecodeDecodes a CurveFinanceTask message from the specified reader or buffer.
Reader or buffer to decode from
Optionallength: numberMessage length if known beforehand
CurveFinanceTask
StaticdecodeDecodes a CurveFinanceTask message from the specified reader or buffer, length delimited.
Reader or buffer to decode from
CurveFinanceTask
StaticencodeEncodes the specified CurveFinanceTask message. Does not implicitly {@apilink oracle_job.OracleJob.CurveFinanceTask.verify|verify} messages.
CurveFinanceTask message or plain object to encode
Optionalwriter: WriterWriter to encode to
Writer
StaticencodeEncodes the specified CurveFinanceTask message, length delimited. Does not implicitly {@apilink oracle_job.OracleJob.CurveFinanceTask.verify|verify} messages.
CurveFinanceTask message or plain object to encode
Optionalwriter: WriterWriter to encode to
Writer
StaticfromCreates a CurveFinanceTask message from a plain object. Also converts values to their respective internal types.
Plain object
CurveFinanceTask
StaticgetGets the default type url for CurveFinanceTask
OptionaltypeUrlPrefix: stringyour custom typeUrlPrefix(default "type.googleapis.com")
The default type url
StatictoCreates a plain object from a CurveFinanceTask message. Also converts values to other types if specified.
CurveFinanceTask
Optionaloptions: IConversionOptionsConversion options
Plain object
StaticverifyVerifies a CurveFinanceTask message.
Plain object to verify
null if valid, otherwise the reason why it is not
Fetch pricing information from Curve Finance pools.
Input: None
Returns: The current price/exchange rate from the specified Curve pool.
Example: Fetch the price from a Curve pool on Ethereum
Example: Fetch the price using a custom RPC provider