use std::string;
use std::type_name;
use sui::coin;
use sui::event;
use sui::sui;
use sage_admin::admin;
use sage_admin::apps;
Explore this module further in the Mover Registry: @sage/channel
Structs
ChannelFees
Holds the fee amounts for Channel
actions.
public struct ChannelFees has key
id: sui::object::UID,
add_channel_moderator_fee_custom: u64,
add_channel_moderator_fee_sui: u64,
app: address,
create_channel_fee_custom: u64,
create_channel_fee_sui: u64,
custom_coin_type: std::type_name::TypeName,
join_channel_fee_custom: u64,
join_channel_fee_sui: u64,
leave_channel_fee_custom: u64,
leave_channel_fee_sui: u64,
post_to_channel_fee_custom: u64,
post_to_channel_fee_sui: u64,
remove_channel_moderator_fee_custom: u64,
remove_channel_moderator_fee_sui: u64,
update_channel_fee_custom: u64,
update_channel_fee_sui: u64
Events
ChannelFeesCreated
Emitted when a new ChannelFees
is created.
public struct ChannelFeesCreated has copy, drop
app_id: address,
channel_fees_id: address,
add_channel_moderator_fee_custom: u64,
add_channel_moderator_fee_sui: u64,
create_channel_fee_custom: u64,
create_channel_fee_sui: u64,
custom_coin_type: std::type_name::TypeName,
join_channel_fee_custom: u64,
join_channel_fee_sui: u64,
leave_channel_fee_custom: u64,
leave_channel_fee_sui: u64,
post_to_channel_fee_custom: u64,
post_to_channel_fee_sui: u64,
remove_channel_moderator_fee_custom: u64,
remove_channel_moderator_fee_sui: u64,
update_channel_fee_custom: u64,
update_channel_fee_sui: u64
ChannelFeesUpdated
Emitted when a ChannelFees
is updated.
public struct ChannelFeesUpdated has copy, drop
channel_fees_id: address,
add_channel_moderator_fee_custom: u64,
add_channel_moderator_fee_sui: u64,
create_channel_fee_custom: u64,
create_channel_fee_sui: u64,
custom_coin_type: std::type_name::TypeName,
join_channel_fee_custom: u64,
join_channel_fee_sui: u64,
leave_channel_fee_custom: u64,
leave_channel_fee_sui: u64,
post_to_channel_fee_custom: u64,
post_to_channel_fee_sui: u64,
remove_channel_moderator_fee_custom: u64,
remove_channel_moderator_fee_sui: u64,
update_channel_fee_custom: u64,
update_channel_fee_sui: u64
Constants
Incorrect coin type passed in for the custom_coin
.
const EIncorrectCoinType: u64 = 370;
Incorrect amount of custom_coin
.
const EIncorrectCustomPayment: u64 = 371;
Incorrect amount of sui_coin
.
const EIncorrectSuiPayment: u64 = 372;