getFeeCalculatorForBlockhash - Solana

getFeeCalculatorForBlockhash. Retrieves the fee calculator associated with a specific blockhash

getFeeCalculatorForBlockhash - solana [Value: 11CU]
The method in Solana retrieves the fee calculator associated with a blockhash
Use cases

Use cases

  • Acquire fee calculations for specific Solana blockhashes
  • Determine transaction fees for financial planning
  • Evaluate fee structures for cost optimization strategies
Constraints

Constraints

  • Limited to specific blockhash data only
  • API call frequency limitations may apply
  • Potential latency in retrieving fee data
Get started
Unlock Access to 50+ chains
Boost your app's speed and reliability with dRPC - get your access API key

Language

Request
Examples
curl https://solana.drpc.org \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{"jsonrpc": "2.0","id": 1,"method": "getFeeCalculatorForBlockhash","params": ["6EUDAG2UBZ1J7CbpixutsELc5c6s4k8YzaWawyKH2Pit"]}'
Copy
Response
200
{
  "jsonrpc": "2.0",
  "result": {
    "context": {
      "slot": 98108954
    },
    "value": {
      "feeCalculator": {
        "lamportsPerSignature": 5000
      }
    }
  },
  "id": 1
}
Copy

Request params

idinteger
jsonrpcstring
methodstring
Parametersarray
array
minContextSlotobject
The minimum slot number at which the request can be evaluated.
blockhashstring
The blockhash for which the fee calculator should be retrieved.
commitmentstring
The level of commitment required for the query
  • finalized - The node will query the most recent block confirmed by supermajority of the cluster as having reached maximum lockout, meaning the cluster has recognized this block as finalized
  • confirmed - The node will query the most recent block that has been voted on by supermajority of the cluster
  • processed - The node will query its most recent block. Note that the block may not be complete

Response

200
Contains information about the fee calculator if the blockhash is valid, otherwise null.

Response params

object
idinteger
jsonrpcstring
resultobject
object
valueobject
A JSON object describing the cluster fee rate at the queried blockhash.
contextobject
object
apiVersionstring
The Solana RPC API version being used.
slotinteger
The slot number corresponding to the fee calculator information.