Skip to main content
POST
/
api
/
v1
/
network
/
fees
Estimate network fees
curl --request POST \
  --url https://api.example.com/api/v1/network/fees \
  --header 'Content-Type: application/protobuf' \
  --data '"<string>"'
{
  "network": {
    "multiplier": 2,
    "subtotal": 1200
  },
  "node": {
    "base": 1000,
    "extras": [
      {
        "charged": 1,
        "count": 2,
        "fee_per_unit": 100,
        "included": 1,
        "name": "Signatures",
        "subtotal": 100
      }
    ]
  },
  "notes": [
    "Fallback to worst-case due to missing state"
  ],
  "service": {
    "base": 1000,
    "extras": [
      {
        "charged": 1,
        "count": 2,
        "fee_per_unit": 100,
        "included": 1,
        "name": "Signatures",
        "subtotal": 100
      }
    ]
  },
  "total": 1000
}

Query Parameters

mode
enum<string>
default:INTRINSIC

Estimate solely based on the transaction's inherent properties or use network state.

Available options:
INTRINSIC,
STATE

Body

A protobuf encoded HAPI Transaction

The body is of type file.

Response

OK

The response containing the estimated transaction fees.

network
object
required

The network fee component which covers the cost of gossip, consensus, signature verifications, fee payment, and storage.

node
object
required

The node fee component which is to be paid to the node that submitted the transaction to the network. This fee exists to compensate the node for the work it performed to pre-check the transaction before submitting it, and incentivizes the node to accept new transactions from users.

notes
string[]
required

An array of strings for any caveats.

Example:
[
"Fallback to worst-case due to missing state"
]
service
object
required

The service fee component which covers execution costs, state saved in the Merkle tree, and additional costs to the blockchain storage.

total
integer<int64>
required

The sum of the network, node, and service subtotals in tinycents.

Required range: x >= 0
Example:

1000