Links

JSON RPC Methods

Polygon JSON-RPC Methods Documentation
The https://data.spiceai.io/polygon API is a Polygon JSON-RPC compatible endpoint that can be used with web3 clients like web.js, ether.js, and web3.py.
Both libraries have great documentation on individual methods and the complete list can be found in the specification.
Here is a drop-in provider for Ethers.js. Use the network name matic.
Spice supported methods are:
  • eth_protocolVersion
  • eth_gasPrice
  • eth_blockNumber
  • eth_call
  • eth_chainId
  • eth_getBalance
  • eth_getStorageAt
  • eth_getTransactionCount
  • eth_getBlockTransactionCountByHash
  • eth_getBlockTransactionCountByNumber
  • eth_getUncleCountByBlockHash
  • eth_getUncleCountByBlockNumber
  • eth_getCode
  • eth_estimateGas
  • eth_getBlockByHash
  • eth_getBlockByNumber
  • eth_syncing
  • eth_getTransactionByHash
  • eth_getTransactionByBlockHashAndIndex
  • eth_getTransactionByBlockNumberAndIndex
  • eth_getTransactionReceipt
  • eth_getUncleByBlockHashAndIndex
  • eth_getUncleByBlockNumberAndIndex
  • eth_getWork
  • eth_feeHistory
  • web3_clientVersion