Syscoin Core Developer Portal

Comprehensive guides and documentation to help you start working with Syscoin as quickly as possible, and support if you get stuck.

Get Started

Auxiliary Fees (aux_fees)

Auxiliary Fees lets you define a custom fee structure for your token. These transaction fees are calculated according to the specified structure and paid to the designated Syscoin address in the form of the transacted SPT. Standard network fees paid in SYS still apply.

Understanding aux_fees

'{"address": "tsys1qm9xqng9xnx5dax2uws7tumn8trx830nxmvv6ms", "fee_struct": [[0,0.01],[10,0.004],[250",0.002],[2500,0.0007],[25000,0.00007],[250000,0.000007]]}'

address: where transaction fees will be sent.
fee_struct: the first integer represents a range boundary pertaining to amount. The second is the fee percentage multiplier for that range. Multiple ranges can be defined in order from least to greatest boundary integer.

Calculation is cumulative across the amount boundaries.

For example, the auxiliary fee for a transaction of 251 tokens with the above fee structure would be calculated as follows:

(10 * 0.01) + (240 * 0.004) + (1 * 0.002) = 1.062 total tokens


The aux_fees structure can be defined within the RPC parameters of assetnew and assetupdate.

assetnew "tsys1qw8664cuus4wwefcsem7ecak2s2c5z8t8r8rgj9" "AUXF" "Aux_fees Test Token" "" 8 1000000 1000000 31 '{"address": "tsys1qm9xqng9xnx5dax2uws7tumn8trx830nxmvv6ms", "fee_struct": [[0,0.01],[10,0.004],[250",0.002],[2500,0.0007],[25000,0.00007],[250000,0.000007]]}' ""


aux_fees structure is stored in the public_value field

and corresponds to update_flags bitmask 0x10(2)

Updated 2 months ago

Auxiliary Fees (aux_fees)

Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.