# Network Fee

A network fee is included in a transaction in order to have the transaction processed by a miner and confirmed by the network.

# Fee Types (strategies)

Type Description
normal Current minimal fee rate (by default)
priority An estimate with this parameter returns a higher fee-rate for a potential faster confirmation
custom Custom fee rate. For this fee type an additional parameter should be specified fee-rate and also priority-fee for Ethereum network
  • HTTP Method: GET
  • URL: https://apirone.com/api/v2/networks/{currency}/fee
Parameter Type Description Required
currency string Currency type

# Request example

curl 'https://apirone.com/api/v2/networks/btc/fee'

# Success response

[
  {
     "strategy": "normal",
     "rate": 1
  },
  {
     "strategy": "priority",
     "rate": 1
  }
]

# Error Response

  • HTTP Status Code: 400 500
  • Content Type: application/json

For custom fee type should be specified fee-rate and also priority-fee for Ethereum network.

# Fee Rate

Parameter Type Description
fee-rate integer The parameter is only used when fee is set as to custom fee. For example: for Bitcoin the value is specified in satoshi per byte (sat/byte). Example: fee-rate = 3 means 3 satoshi per byte. For Ethereum: the value is specified in gwei. Example: fee-rate = 20 means 20 gwei per gas (how the fee works in Ethereum and what it consists of you can see here (opens new window))

# Priority fee (for Ethereum network)

Parameter Type Description
priority-fee integer Defines the priority fee (also known as the "tip") that is paid directly to Ethereum validators to incentivize transaction inclusion. When this field is used, its value is added to the fee-rate. This field is only applicable when the fee-rate is specified.

Request example for custom fee in transfer for the Bitcoin network (fee-rate=5):

	"fee": "custom",
	"fee-rate": 5

Response for custom fee in transfer for the Bitcoin network (fee-rate=5):

	"fee": {
		"subtract-from-amount": false,
		"network": {
			"strategy": "custom",
			"amount": 830,
			"rate": 5.0
		}
	}

Request example for custom fee in transfer for the Ethereum network (fee-rate=5, priority-fee=3):

	"fee": "custom",
	"fee-rate": 5,
	"priority-fee": 3

Response for custom fee in transfer for the Ethereum network (fee-rate=5, priority-fee=3):

	"fee": {
		"subtract-from-amount": false,
		"network": {
			"strategy": "custom",
			"amount": 168000,
			"rate": 8
		}
	}

Playground