neutron_std/types/osmosis/tokenfactory/
mod.rs

1pub mod v1beta1;
2use neutron_std_derive::CosmwasmExt;
3/// WhitelistedHook describes a beforeSendHook which is allowed to be added and executed
4/// SetBeforeSendHook can only be called on denoms where the denom creator and
5/// code_id for the `contract_addr` match a WhitelistedHook
6#[allow(clippy::derive_partial_eq_without_eq)]
7#[derive(
8    Clone,
9    PartialEq,
10    Eq,
11    ::prost::Message,
12    ::serde::Serialize,
13    ::serde::Deserialize,
14    ::schemars::JsonSchema,
15    CosmwasmExt,
16)]
17#[proto_message(type_url = "/osmosis.tokenfactory.WhitelistedHook")]
18pub struct WhitelistedHook {
19    #[prost(uint64, tag = "1")]
20    #[serde(alias = "codeID")]
21    #[serde(
22        serialize_with = "crate::serde::as_str::serialize",
23        deserialize_with = "crate::serde::as_str::deserialize"
24    )]
25    pub code_id: u64,
26    #[prost(string, tag = "2")]
27    pub denom_creator: ::prost::alloc::string::String,
28}
29/// Params defines the parameters for the tokenfactory module.
30#[allow(clippy::derive_partial_eq_without_eq)]
31#[derive(
32    Clone,
33    PartialEq,
34    Eq,
35    ::prost::Message,
36    ::serde::Serialize,
37    ::serde::Deserialize,
38    ::schemars::JsonSchema,
39    CosmwasmExt,
40)]
41#[proto_message(type_url = "/osmosis.tokenfactory.Params")]
42pub struct Params {
43    /// DenomCreationFee defines the fee to be charged on the creation of a new
44    /// denom. The fee is drawn from the MsgCreateDenom's sender account, and
45    /// transferred to the community pool.
46    #[prost(message, repeated, tag = "1")]
47    pub denom_creation_fee: ::prost::alloc::vec::Vec<super::super::cosmos::base::v1beta1::Coin>,
48    /// DenomCreationGasConsume defines the gas cost for creating a new denom.
49    /// This is intended as a spam deterrence mechanism.
50    ///
51    /// See: <https://github.com/CosmWasm/token-factory/issues/11>
52    #[prost(uint64, tag = "2")]
53    #[prost(optional)]
54    #[serde(
55        serialize_with = "crate::serde::option_as_str::serialize",
56        deserialize_with = "crate::serde::option_as_str::deserialize"
57    )]
58    pub denom_creation_gas_consume: ::core::option::Option<u64>,
59    /// FeeCollectorAddress is the address where fees collected from denom creation
60    /// are sent to
61    #[prost(string, tag = "3")]
62    pub fee_collector_address: ::prost::alloc::string::String,
63    /// whitelisted_hooks is the list of hooks which are allowed to be added and executed
64    #[prost(message, repeated, tag = "4")]
65    pub whitelisted_hooks: ::prost::alloc::vec::Vec<WhitelistedHook>,
66}