contract_call_raw_function_as_read_only
Execute a read-only function call on a NEAR smart contract to retrieve data without modifying its state. Specify contract ID, method name, and arguments.
Instructions
Call a function of a contract as a read-only call. This is equivalent to saying we are calling a view method of the contract.
Input Schema
Name | Required | Description | Default |
---|---|---|---|
args | Yes | The arguments to pass to the method. | |
contractId | Yes | The account id of the contract. | |
methodName | Yes | The name of the method to call. | |
networkId | No | mainnet |
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"args": {
"additionalProperties": {},
"description": "The arguments to pass to the method.",
"type": "object"
},
"contractId": {
"description": "The account id of the contract.",
"type": "string"
},
"methodName": {
"description": "The name of the method to call.",
"type": "string"
},
"networkId": {
"default": "mainnet",
"enum": [
"testnet",
"mainnet"
],
"type": "string"
}
},
"required": [
"contractId",
"methodName",
"args"
],
"type": "object"
}