> For the complete documentation index, see [llms.txt](https://documentation.script.tv/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://documentation.script.tv/for-users/blockchain-integration/call-smart-contract.md). Agents can also search and read this documentation through its [MCP server](https://documentation.script.tv/~gitbook/mcp).

# Call Smart Contract

This API simulates the smart contract execution locally without submitting the smart contract transaction to the blockchain. It is useful to evaluate the execution result, calculate the gas cost, etc.

**RPC Method:** script.CallSmartContract

**Query Parameters**

sctx\_bytes: the signed transaction bytes

**Returns**

vm\_return: the return of the virtual machine

contract\_address: the address of the corresponding smart contract

gas\_used: amount of gas used for the smart contract execution

vm\_error: error returned by the virtual machine if any
