diff --git a/types/msg.go b/types/msg.go index 9f22d300c..60a6e8751 100644 --- a/types/msg.go +++ b/types/msg.go @@ -125,6 +125,8 @@ type IBCMsg struct { SendPacket *SendPacketMsg `json:"send_packet,omitempty"` WriteAcknowledgement *WriteAcknowledgementMsg `json:"write_acknowledgement,omitempty"` CloseChannel *CloseChannelMsg `json:"close_channel,omitempty"` + PayPacketFee *PayPacketFeeMsg `json:"pay_packet_fee,omitempty"` + PayPacketFeeAsync *PayPacketFeeAsyncMsg `json:"pay_packet_fee_async,omitempty"` } type GovMsg struct { @@ -255,6 +257,34 @@ type CloseChannelMsg struct { ChannelID string `json:"channel_id"` } +type PayPacketFeeMsg struct { + // The channel id on the chain where the packet is sent from (this chain). + ChannelID string `json:"channel_id"` + Fee IBCFee `json:"fee"` + // The port id on the chain where the packet is sent from (this chain). + PortID string `json:"port_id"` + // Allowlist of relayer addresses that can receive the fee. This is currently not implemented and *must* be empty. + Relayers Array[string] `json:"relayers"` +} + +type PayPacketFeeAsyncMsg struct { + // The channel id on the chain where the packet is sent from (this chain). + ChannelID string `json:"channel_id"` + Fee IBCFee `json:"fee"` + // The port id on the chain where the packet is sent from (this chain). + PortID string `json:"port_id"` + // Allowlist of relayer addresses that can receive the fee. This is currently not implemented and *must* be empty. + Relayers Array[string] `json:"relayers"` + // The sequence number of the packet that should be incentivized. + Sequence uint64 `json:"sequence"` +} + +type IBCFee struct { + AckFee Array[Coin] `json:"ack_fee"` + ReceiveFee Array[Coin] `json:"receive_fee"` + TimeoutFee Array[Coin] `json:"timeout_fee"` +} + type StakingMsg struct { Delegate *DelegateMsg `json:"delegate,omitempty"` Undelegate *UndelegateMsg `json:"undelegate,omitempty"` diff --git a/types/queries.go b/types/queries.go index 748003bee..a3fe0bcf4 100644 --- a/types/queries.go +++ b/types/queries.go @@ -171,9 +171,19 @@ type AllDenomMetadataResponse struct { // IBCQuery defines a query request from the contract into the chain. // This is the counterpart of [IbcQuery](https://github.com/CosmWasm/cosmwasm/blob/v0.14.0-beta1/packages/std/src/ibc.rs#L61-L83). type IBCQuery struct { - PortID *PortIDQuery `json:"port_id,omitempty"` - ListChannels *ListChannelsQuery `json:"list_channels,omitempty"` - Channel *ChannelQuery `json:"channel,omitempty"` + PortID *PortIDQuery `json:"port_id,omitempty"` + ListChannels *ListChannelsQuery `json:"list_channels,omitempty"` + Channel *ChannelQuery `json:"channel,omitempty"` + FeeEnabledChannel *FeeEnabledChannelQuery `json:"fee_enabled_channel,omitempty"` +} + +type FeeEnabledChannelQuery struct { + ChannelID string `json:"channel_id"` + PortID string `json:"port_id,omitempty"` +} + +type FeeEnabledChannelResponse struct { + FeeEnabled bool `json:"fee_enabled"` } type PortIDQuery struct{}