getMinimumBalanceForRentExemption

Returns minimum balance required to make account rent exempt.

Parameters


  • <usize> - account data length
  • <object> - (optional)
    • commitment: (optional) Configures the commitment level of the blocks queried
      Accepts one of the following strings: ["finalized", "confirmed", "processed"]
      For more info, refer to this doc.

Returns


  • <u64> - minimum lamports required in an account

Example


Request


curl --location --request POST 'https://solana-mainnet.g.alchemy.com/v2/demo/' \
--header 'Content-Type: application/json' \
--data-raw '{
    "jsonrpc": "2.0",
    "id": 1,
    "method": "getMinimumBalanceForRentExemption",
    "params": [
        50
    ]
}'

Response


{
    "jsonrpc": "2.0",
    "result": 1238880,
    "id": 1
}
Language
URL
ReadMe