#native #cosmos #validation #cosmwasm #cw20 #contract #denominations

cw-denom

A package for validation and handling of cw20 and native Cosmos SDK denominations

8 releases (stable)

2.4.2 Jul 22, 2024
2.4.0 Jul 21, 2024
2.3.0 Oct 18, 2023
2.2.0 Jul 9, 2023
0.1.0 Sep 25, 2022

#3 in #cw20

Download history 62/week @ 2024-06-26 43/week @ 2024-07-03 128/week @ 2024-07-10 848/week @ 2024-07-17 529/week @ 2024-07-24 425/week @ 2024-07-31 416/week @ 2024-08-07 743/week @ 2024-08-14 136/week @ 2024-08-21 101/week @ 2024-08-28 236/week @ 2024-09-04 303/week @ 2024-09-11 195/week @ 2024-09-18 135/week @ 2024-09-25 80/week @ 2024-10-02 113/week @ 2024-10-09

560 downloads per month
Used in 26 crates (5 directly)

BSD-3-Clause

18KB
341 lines

CosmWasm Denom

This is a simple package for validating cw20 and Cosmos SDK native denominations. It proves the types, UncheckedDenom and CheckedDenom. UncheckedDenom may be used in CosmWasm contract messages and checked via the into_checked method.

To validate native denominations, this package uses the same rules as the SDK.

To validate cw20 denominations this package ensures that the specified address is valid, that the specified address is a CosmWasm contract, and that the specified address responds correctly to cw20 TokenInfo queries.

Dependencies

~4–6MB
~126K SLoC