38 major breaking releases

new 41.0.0 Jul 15, 2025
40.0.0 Apr 3, 2025
39.1.0 Mar 27, 2025
38.0.0 Sep 26, 2024
0.0.0 Nov 21, 2022

#6 in #calculated

Download history 4748/week @ 2025-03-25 4545/week @ 2025-04-01 4489/week @ 2025-04-08 3827/week @ 2025-04-15 6241/week @ 2025-04-22 4425/week @ 2025-04-29 3595/week @ 2025-05-06 3007/week @ 2025-05-13 2981/week @ 2025-05-20 2554/week @ 2025-05-27 2783/week @ 2025-06-03 2773/week @ 2025-06-10 3660/week @ 2025-06-17 3370/week @ 2025-06-24 3803/week @ 2025-07-01 2220/week @ 2025-07-08

13,568 downloads per month
Used in 87 crates (6 directly)

Apache-2.0

3MB
46K SLoC

pallet-asset-tx-payment

Asset Transaction Payment Pallet

This pallet allows runtimes that include it to pay for transactions in assets other than the native token of the chain.

Overview

It does this by extending transactions to include an optional AssetId that specifies the asset to be used for payment (defaulting to the native token on None). It expects an OnChargeAssetTransaction implementation analogously to pallet-transaction-payment. The included FungiblesAdapter (implementing OnChargeAssetTransaction) determines the fee amount by converting the fee calculated by pallet-transaction-payment into the desired asset.

Integration

This pallet wraps FRAME's transaction payment pallet and functions as a replacement. This means you should include both pallets in your construct_runtime macro, but only include this pallet's TransactionExtension (ChargeAssetTxPayment).

License: Apache-2.0

Dependencies

~25–41MB
~672K SLoC