interchainjs
Version:
InterchainJS is a JavaScript library for interacting with Cosmos SDK based blockchains.
152 lines (151 loc) • 5.49 kB
TypeScript
import { Coin, CoinAmino } from "../../../../cosmos/base/v1beta1/coin";
import { BinaryReader, BinaryWriter } from "../../../../binary";
import { DeepPartial } from "../../../../helpers";
/**
* Allocation defines the spend limit for a particular port and channel
* @name Allocation
* @package ibc.applications.transfer.v1
* @see proto type: ibc.applications.transfer.v1.Allocation
*/
export interface Allocation {
/**
* the port on which the packet will be sent
*/
sourcePort: string;
/**
* the channel by which the packet will be sent
*/
sourceChannel: string;
/**
* spend limitation on the channel
*/
spendLimit: Coin[];
/**
* allow list of receivers, an empty allow list permits any receiver address
*/
allowList: string[];
/**
* allow list of memo strings, an empty list prohibits all memo strings;
* a list only with "*" permits any memo string
*/
allowedPacketData: string[];
}
export interface AllocationProtoMsg {
typeUrl: "/ibc.applications.transfer.v1.Allocation";
value: Uint8Array;
}
/**
* Allocation defines the spend limit for a particular port and channel
* @name AllocationAmino
* @package ibc.applications.transfer.v1
* @see proto type: ibc.applications.transfer.v1.Allocation
*/
export interface AllocationAmino {
/**
* the port on which the packet will be sent
*/
source_port: string;
/**
* the channel by which the packet will be sent
*/
source_channel: string;
/**
* spend limitation on the channel
*/
spend_limit: CoinAmino[];
/**
* allow list of receivers, an empty allow list permits any receiver address
*/
allow_list: string[];
/**
* allow list of memo strings, an empty list prohibits all memo strings;
* a list only with "*" permits any memo string
*/
allowed_packet_data: string[];
}
export interface AllocationAminoMsg {
type: "cosmos-sdk/Allocation";
value: AllocationAmino;
}
/**
* TransferAuthorization allows the grantee to spend up to spend_limit coins from
* the granter's account for ibc transfer on a specific channel
* @name TransferAuthorization
* @package ibc.applications.transfer.v1
* @see proto type: ibc.applications.transfer.v1.TransferAuthorization
*/
export interface TransferAuthorization {
$typeUrl?: "/ibc.applications.transfer.v1.TransferAuthorization";
/**
* port and channel amounts
*/
allocations: Allocation[];
}
export interface TransferAuthorizationProtoMsg {
typeUrl: "/ibc.applications.transfer.v1.TransferAuthorization";
value: Uint8Array;
}
/**
* TransferAuthorization allows the grantee to spend up to spend_limit coins from
* the granter's account for ibc transfer on a specific channel
* @name TransferAuthorizationAmino
* @package ibc.applications.transfer.v1
* @see proto type: ibc.applications.transfer.v1.TransferAuthorization
*/
export interface TransferAuthorizationAmino {
/**
* port and channel amounts
*/
allocations: AllocationAmino[];
}
export interface TransferAuthorizationAminoMsg {
type: "cosmos-sdk/TransferAuthorization";
value: TransferAuthorizationAmino;
}
/**
* Allocation defines the spend limit for a particular port and channel
* @name Allocation
* @package ibc.applications.transfer.v1
* @see proto type: ibc.applications.transfer.v1.Allocation
*/
export declare const Allocation: {
typeUrl: string;
aminoType: string;
is(o: any): o is Allocation;
isAmino(o: any): o is AllocationAmino;
encode(message: Allocation, writer?: BinaryWriter): BinaryWriter;
decode(input: BinaryReader | Uint8Array, length?: number): Allocation;
fromPartial(object: DeepPartial<Allocation>): Allocation;
fromAmino(object: AllocationAmino): Allocation;
toAmino(message: Allocation): AllocationAmino;
fromAminoMsg(object: AllocationAminoMsg): Allocation;
toAminoMsg(message: Allocation): AllocationAminoMsg;
fromProtoMsg(message: AllocationProtoMsg): Allocation;
toProto(message: Allocation): Uint8Array;
toProtoMsg(message: Allocation): AllocationProtoMsg;
registerTypeUrl(): void;
};
/**
* TransferAuthorization allows the grantee to spend up to spend_limit coins from
* the granter's account for ibc transfer on a specific channel
* @name TransferAuthorization
* @package ibc.applications.transfer.v1
* @see proto type: ibc.applications.transfer.v1.TransferAuthorization
*/
export declare const TransferAuthorization: {
typeUrl: string;
aminoType: string;
is(o: any): o is TransferAuthorization;
isAmino(o: any): o is TransferAuthorizationAmino;
encode(message: TransferAuthorization, writer?: BinaryWriter): BinaryWriter;
decode(input: BinaryReader | Uint8Array, length?: number): TransferAuthorization;
fromPartial(object: DeepPartial<TransferAuthorization>): TransferAuthorization;
fromAmino(object: TransferAuthorizationAmino): TransferAuthorization;
toAmino(message: TransferAuthorization): TransferAuthorizationAmino;
fromAminoMsg(object: TransferAuthorizationAminoMsg): TransferAuthorization;
toAminoMsg(message: TransferAuthorization): TransferAuthorizationAminoMsg;
fromProtoMsg(message: TransferAuthorizationProtoMsg): TransferAuthorization;
toProto(message: TransferAuthorization): Uint8Array;
toProtoMsg(message: TransferAuthorization): TransferAuthorizationProtoMsg;
registerTypeUrl(): void;
};