coreum-js 2.13.0 → 2.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/main/coreum/asset/ft/v1/tx.d.ts +49 -0
- package/dist/main/coreum/asset/ft/v1/tx.js +86 -1
- package/dist/main/coreum/asset/index.js +1 -0
- package/dist/main/coreum/index.d.ts +11 -1
- package/dist/main/coreum/index.js +12 -0
- package/dist/main/types/msgs.d.ts +5 -0
- package/dist/module/coreum/asset/ft/v1/tx.d.ts +49 -0
- package/dist/module/coreum/asset/ft/v1/tx.js +84 -0
- package/dist/module/coreum/asset/index.js +2 -1
- package/dist/module/coreum/index.d.ts +11 -1
- package/dist/module/coreum/index.js +13 -1
- package/dist/module/types/msgs.d.ts +5 -0
- package/package.json +1 -1
|
@@ -56,6 +56,11 @@ export interface MsgSetWhitelistedLimit {
|
|
|
56
56
|
account: string;
|
|
57
57
|
coin?: Coin;
|
|
58
58
|
}
|
|
59
|
+
export interface MsgClawback {
|
|
60
|
+
sender: string;
|
|
61
|
+
account: string;
|
|
62
|
+
coin?: Coin;
|
|
63
|
+
}
|
|
59
64
|
export interface EmptyResponse {
|
|
60
65
|
}
|
|
61
66
|
export declare const MsgIssue: {
|
|
@@ -356,6 +361,48 @@ export declare const MsgSetWhitelistedLimit: {
|
|
|
356
361
|
} & { [K_2 in Exclude<keyof I_1["coin"], keyof Coin>]: never; };
|
|
357
362
|
} & { [K_3 in Exclude<keyof I_1, keyof MsgSetWhitelistedLimit>]: never; }>(object: I_1): MsgSetWhitelistedLimit;
|
|
358
363
|
};
|
|
364
|
+
export declare const MsgClawback: {
|
|
365
|
+
encode(message: MsgClawback, writer?: _m0.Writer): _m0.Writer;
|
|
366
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): MsgClawback;
|
|
367
|
+
fromJSON(object: any): MsgClawback;
|
|
368
|
+
toJSON(message: MsgClawback): unknown;
|
|
369
|
+
create<I extends {
|
|
370
|
+
sender?: string;
|
|
371
|
+
account?: string;
|
|
372
|
+
coin?: {
|
|
373
|
+
denom?: string;
|
|
374
|
+
amount?: string;
|
|
375
|
+
};
|
|
376
|
+
} & {
|
|
377
|
+
sender?: string;
|
|
378
|
+
account?: string;
|
|
379
|
+
coin?: {
|
|
380
|
+
denom?: string;
|
|
381
|
+
amount?: string;
|
|
382
|
+
} & {
|
|
383
|
+
denom?: string;
|
|
384
|
+
amount?: string;
|
|
385
|
+
} & { [K in Exclude<keyof I["coin"], keyof Coin>]: never; };
|
|
386
|
+
} & { [K_1 in Exclude<keyof I, keyof MsgClawback>]: never; }>(base?: I): MsgClawback;
|
|
387
|
+
fromPartial<I_1 extends {
|
|
388
|
+
sender?: string;
|
|
389
|
+
account?: string;
|
|
390
|
+
coin?: {
|
|
391
|
+
denom?: string;
|
|
392
|
+
amount?: string;
|
|
393
|
+
};
|
|
394
|
+
} & {
|
|
395
|
+
sender?: string;
|
|
396
|
+
account?: string;
|
|
397
|
+
coin?: {
|
|
398
|
+
denom?: string;
|
|
399
|
+
amount?: string;
|
|
400
|
+
} & {
|
|
401
|
+
denom?: string;
|
|
402
|
+
amount?: string;
|
|
403
|
+
} & { [K_2 in Exclude<keyof I_1["coin"], keyof Coin>]: never; };
|
|
404
|
+
} & { [K_3 in Exclude<keyof I_1, keyof MsgClawback>]: never; }>(object: I_1): MsgClawback;
|
|
405
|
+
};
|
|
359
406
|
export declare const EmptyResponse: {
|
|
360
407
|
encode(_: EmptyResponse, writer?: _m0.Writer): _m0.Writer;
|
|
361
408
|
decode(input: _m0.Reader | Uint8Array, length?: number): EmptyResponse;
|
|
@@ -394,6 +441,7 @@ export interface Msg {
|
|
|
394
441
|
GloballyUnfreeze(request: MsgGloballyUnfreeze): Promise<EmptyResponse>;
|
|
395
442
|
/** SetWhitelistedLimit sets the limit of how many tokens a specific account may hold. */
|
|
396
443
|
SetWhitelistedLimit(request: MsgSetWhitelistedLimit): Promise<EmptyResponse>;
|
|
444
|
+
Clawback(request: MsgClawback): Promise<EmptyResponse>;
|
|
397
445
|
}
|
|
398
446
|
export declare class MsgClientImpl implements Msg {
|
|
399
447
|
private readonly rpc;
|
|
@@ -409,6 +457,7 @@ export declare class MsgClientImpl implements Msg {
|
|
|
409
457
|
GloballyFreeze(request: MsgGloballyFreeze): Promise<EmptyResponse>;
|
|
410
458
|
GloballyUnfreeze(request: MsgGloballyUnfreeze): Promise<EmptyResponse>;
|
|
411
459
|
SetWhitelistedLimit(request: MsgSetWhitelistedLimit): Promise<EmptyResponse>;
|
|
460
|
+
Clawback(request: MsgClawback): Promise<EmptyResponse>;
|
|
412
461
|
}
|
|
413
462
|
interface Rpc {
|
|
414
463
|
request(service: string, method: string, data: Uint8Array): Promise<Uint8Array>;
|
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.MsgClientImpl = exports.EmptyResponse = exports.MsgSetWhitelistedLimit = exports.MsgGloballyUnfreeze = exports.MsgGloballyFreeze = exports.MsgUnfreeze = exports.MsgFreeze = exports.MsgBurn = exports.MsgMint = exports.MsgIssue = exports.protobufPackage = void 0;
|
|
6
|
+
exports.MsgClientImpl = exports.EmptyResponse = exports.MsgClawback = exports.MsgSetWhitelistedLimit = exports.MsgGloballyUnfreeze = exports.MsgGloballyFreeze = exports.MsgUnfreeze = exports.MsgFreeze = exports.MsgBurn = exports.MsgMint = exports.MsgIssue = exports.protobufPackage = void 0;
|
|
7
7
|
/* eslint-disable */
|
|
8
8
|
const long_1 = __importDefault(require("long"));
|
|
9
9
|
const minimal_1 = __importDefault(require("protobufjs/minimal"));
|
|
@@ -714,6 +714,85 @@ exports.MsgSetWhitelistedLimit = {
|
|
|
714
714
|
return message;
|
|
715
715
|
},
|
|
716
716
|
};
|
|
717
|
+
function createBaseMsgClawback() {
|
|
718
|
+
return { sender: "", account: "", coin: undefined };
|
|
719
|
+
}
|
|
720
|
+
exports.MsgClawback = {
|
|
721
|
+
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
722
|
+
if (message.sender !== "") {
|
|
723
|
+
writer.uint32(10).string(message.sender);
|
|
724
|
+
}
|
|
725
|
+
if (message.account !== "") {
|
|
726
|
+
writer.uint32(18).string(message.account);
|
|
727
|
+
}
|
|
728
|
+
if (message.coin !== undefined) {
|
|
729
|
+
coin_1.Coin.encode(message.coin, writer.uint32(26).fork()).ldelim();
|
|
730
|
+
}
|
|
731
|
+
return writer;
|
|
732
|
+
},
|
|
733
|
+
decode(input, length) {
|
|
734
|
+
const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
|
|
735
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
736
|
+
const message = createBaseMsgClawback();
|
|
737
|
+
while (reader.pos < end) {
|
|
738
|
+
const tag = reader.uint32();
|
|
739
|
+
switch (tag >>> 3) {
|
|
740
|
+
case 1:
|
|
741
|
+
if (tag != 10) {
|
|
742
|
+
break;
|
|
743
|
+
}
|
|
744
|
+
message.sender = reader.string();
|
|
745
|
+
continue;
|
|
746
|
+
case 2:
|
|
747
|
+
if (tag != 18) {
|
|
748
|
+
break;
|
|
749
|
+
}
|
|
750
|
+
message.account = reader.string();
|
|
751
|
+
continue;
|
|
752
|
+
case 3:
|
|
753
|
+
if (tag != 26) {
|
|
754
|
+
break;
|
|
755
|
+
}
|
|
756
|
+
message.coin = coin_1.Coin.decode(reader, reader.uint32());
|
|
757
|
+
continue;
|
|
758
|
+
}
|
|
759
|
+
if ((tag & 7) == 4 || tag == 0) {
|
|
760
|
+
break;
|
|
761
|
+
}
|
|
762
|
+
reader.skipType(tag & 7);
|
|
763
|
+
}
|
|
764
|
+
return message;
|
|
765
|
+
},
|
|
766
|
+
fromJSON(object) {
|
|
767
|
+
return {
|
|
768
|
+
sender: isSet(object.sender) ? String(object.sender) : "",
|
|
769
|
+
account: isSet(object.account) ? String(object.account) : "",
|
|
770
|
+
coin: isSet(object.coin) ? coin_1.Coin.fromJSON(object.coin) : undefined,
|
|
771
|
+
};
|
|
772
|
+
},
|
|
773
|
+
toJSON(message) {
|
|
774
|
+
const obj = {};
|
|
775
|
+
message.sender !== undefined && (obj.sender = message.sender);
|
|
776
|
+
message.account !== undefined && (obj.account = message.account);
|
|
777
|
+
message.coin !== undefined &&
|
|
778
|
+
(obj.coin = message.coin ? coin_1.Coin.toJSON(message.coin) : undefined);
|
|
779
|
+
return obj;
|
|
780
|
+
},
|
|
781
|
+
create(base) {
|
|
782
|
+
return exports.MsgClawback.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
783
|
+
},
|
|
784
|
+
fromPartial(object) {
|
|
785
|
+
var _a, _b;
|
|
786
|
+
const message = createBaseMsgClawback();
|
|
787
|
+
message.sender = (_a = object.sender) !== null && _a !== void 0 ? _a : "";
|
|
788
|
+
message.account = (_b = object.account) !== null && _b !== void 0 ? _b : "";
|
|
789
|
+
message.coin =
|
|
790
|
+
object.coin !== undefined && object.coin !== null
|
|
791
|
+
? coin_1.Coin.fromPartial(object.coin)
|
|
792
|
+
: undefined;
|
|
793
|
+
return message;
|
|
794
|
+
},
|
|
795
|
+
};
|
|
717
796
|
function createBaseEmptyResponse() {
|
|
718
797
|
return {};
|
|
719
798
|
}
|
|
@@ -763,6 +842,7 @@ class MsgClientImpl {
|
|
|
763
842
|
this.GloballyFreeze = this.GloballyFreeze.bind(this);
|
|
764
843
|
this.GloballyUnfreeze = this.GloballyUnfreeze.bind(this);
|
|
765
844
|
this.SetWhitelistedLimit = this.SetWhitelistedLimit.bind(this);
|
|
845
|
+
this.Clawback = this.Clawback.bind(this);
|
|
766
846
|
}
|
|
767
847
|
Issue(request) {
|
|
768
848
|
const data = exports.MsgIssue.encode(request).finish();
|
|
@@ -804,6 +884,11 @@ class MsgClientImpl {
|
|
|
804
884
|
const promise = this.rpc.request(this.service, "SetWhitelistedLimit", data);
|
|
805
885
|
return promise.then((data) => exports.EmptyResponse.decode(minimal_1.default.Reader.create(data)));
|
|
806
886
|
}
|
|
887
|
+
Clawback(request) {
|
|
888
|
+
const data = exports.MsgClawback.encode(request).finish();
|
|
889
|
+
const promise = this.rpc.request(this.service, "Clawback", data);
|
|
890
|
+
return promise.then((data) => exports.EmptyResponse.decode(minimal_1.default.Reader.create(data)));
|
|
891
|
+
}
|
|
807
892
|
}
|
|
808
893
|
exports.MsgClientImpl = MsgClientImpl;
|
|
809
894
|
if (minimal_1.default.util.Long !== long_1.default) {
|
|
@@ -22,4 +22,5 @@ exports.assetFtRegistry = [
|
|
|
22
22
|
[types_1.CoreumTypeUrl.FT + "MsgGloballyFreeze", tx_2.MsgGloballyFreeze],
|
|
23
23
|
[types_1.CoreumTypeUrl.FT + "MsgGloballyUnfreeze", tx_2.MsgGloballyUnfreeze],
|
|
24
24
|
[types_1.CoreumTypeUrl.FT + "MsgSetWhitelistedLimit", tx_2.MsgSetWhitelistedLimit],
|
|
25
|
+
[types_1.CoreumTypeUrl.FT + "MsgClawback", tx_2.MsgClawback],
|
|
25
26
|
];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { GeneratedType } from "@cosmjs/proto-signing";
|
|
2
2
|
import { MsgSend as NFTMsgSend } from "./nft/v1beta1/tx";
|
|
3
3
|
import { MsgIssueClass as NFTMsgIssueClass, MsgMint as NFTMsgMint, MsgAddToWhitelist as NFTMsgAddToWhitelist, MsgBurn as NFTMsgBurn, MsgRemoveFromWhitelist as NFTMsgRemoveFromWhitelist, MsgFreeze as NFTMsgFreeze, MsgUnfreeze as NFTMsgUnfreeze } from "./asset/nft/v1/tx";
|
|
4
|
-
import { MsgIssue as FTMsgIssue, MsgMint as FTMsgMint, MsgBurn as FTMsgBurn, MsgFreeze as FTMsgFreeze, MsgUnfreeze as FTMsgUnfreeze, MsgGloballyFreeze as FTMsgGloballyFreeze, MsgGloballyUnfreeze as FTMsgGloballyUnfreeze, MsgSetWhitelistedLimit as FTMsgSetWhitelistedLimit } from "./asset/ft/v1/tx";
|
|
4
|
+
import { MsgIssue as FTMsgIssue, MsgMint as FTMsgMint, MsgBurn as FTMsgBurn, MsgFreeze as FTMsgFreeze, MsgUnfreeze as FTMsgUnfreeze, MsgGloballyFreeze as FTMsgGloballyFreeze, MsgGloballyUnfreeze as FTMsgGloballyUnfreeze, MsgSetWhitelistedLimit as FTMsgSetWhitelistedLimit, MsgClawback as FTMsgClawback } from "./asset/ft/v1/tx";
|
|
5
5
|
import { FTMsgs, NFTMsgs } from "../types/msgs";
|
|
6
6
|
export { Feature } from "./asset/ft/v1/token";
|
|
7
7
|
export { ClassFeature } from "./asset/nft/v1/nft";
|
|
@@ -98,6 +98,16 @@ export declare namespace FT {
|
|
|
98
98
|
typeUrl: string;
|
|
99
99
|
value: FTMsgSetWhitelistedLimit;
|
|
100
100
|
};
|
|
101
|
+
/** MsgClawback message creator
|
|
102
|
+
* Clawbacks the assets from the specific address.
|
|
103
|
+
*
|
|
104
|
+
* @param object Represents the properties available for this MsgClawback message.
|
|
105
|
+
* @returns A Msg object with the typeUrl and value object for the proper message
|
|
106
|
+
*/
|
|
107
|
+
const Clawback: (object: FTMsgs.MsgClawback) => {
|
|
108
|
+
typeUrl: string;
|
|
109
|
+
value: FTMsgClawback;
|
|
110
|
+
};
|
|
101
111
|
}
|
|
102
112
|
/**
|
|
103
113
|
* Transaction Module for the Non-Fungible Tokens modules (assetnft, nftbeta).
|
|
@@ -119,6 +119,18 @@ var FT;
|
|
|
119
119
|
value: tx_3.MsgSetWhitelistedLimit.fromPartial(object),
|
|
120
120
|
};
|
|
121
121
|
};
|
|
122
|
+
/** MsgClawback message creator
|
|
123
|
+
* Clawbacks the assets from the specific address.
|
|
124
|
+
*
|
|
125
|
+
* @param object Represents the properties available for this MsgClawback message.
|
|
126
|
+
* @returns A Msg object with the typeUrl and value object for the proper message
|
|
127
|
+
*/
|
|
128
|
+
FT.Clawback = function (object) {
|
|
129
|
+
return {
|
|
130
|
+
typeUrl: "/coreum.asset.ft.v1.MsgClawback",
|
|
131
|
+
value: tx_3.MsgClawback.fromPartial(object),
|
|
132
|
+
};
|
|
133
|
+
};
|
|
122
134
|
})(FT || (exports.FT = FT = {}));
|
|
123
135
|
/**
|
|
124
136
|
* Transaction Module for the Non-Fungible Tokens modules (assetnft, nftbeta).
|
|
@@ -62,6 +62,11 @@ export declare namespace FTMsgs {
|
|
|
62
62
|
account: string;
|
|
63
63
|
coin: Coin;
|
|
64
64
|
}
|
|
65
|
+
interface MsgClawback {
|
|
66
|
+
sender: string;
|
|
67
|
+
account: string;
|
|
68
|
+
coin: Coin;
|
|
69
|
+
}
|
|
65
70
|
}
|
|
66
71
|
export declare namespace NFTMsgs {
|
|
67
72
|
/** MsgSend represents a message to send a nft from one account to another account. */
|
|
@@ -56,6 +56,11 @@ export interface MsgSetWhitelistedLimit {
|
|
|
56
56
|
account: string;
|
|
57
57
|
coin?: Coin;
|
|
58
58
|
}
|
|
59
|
+
export interface MsgClawback {
|
|
60
|
+
sender: string;
|
|
61
|
+
account: string;
|
|
62
|
+
coin?: Coin;
|
|
63
|
+
}
|
|
59
64
|
export interface EmptyResponse {
|
|
60
65
|
}
|
|
61
66
|
export declare const MsgIssue: {
|
|
@@ -356,6 +361,48 @@ export declare const MsgSetWhitelistedLimit: {
|
|
|
356
361
|
} & { [K_2 in Exclude<keyof I_1["coin"], keyof Coin>]: never; };
|
|
357
362
|
} & { [K_3 in Exclude<keyof I_1, keyof MsgSetWhitelistedLimit>]: never; }>(object: I_1): MsgSetWhitelistedLimit;
|
|
358
363
|
};
|
|
364
|
+
export declare const MsgClawback: {
|
|
365
|
+
encode(message: MsgClawback, writer?: _m0.Writer): _m0.Writer;
|
|
366
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): MsgClawback;
|
|
367
|
+
fromJSON(object: any): MsgClawback;
|
|
368
|
+
toJSON(message: MsgClawback): unknown;
|
|
369
|
+
create<I extends {
|
|
370
|
+
sender?: string;
|
|
371
|
+
account?: string;
|
|
372
|
+
coin?: {
|
|
373
|
+
denom?: string;
|
|
374
|
+
amount?: string;
|
|
375
|
+
};
|
|
376
|
+
} & {
|
|
377
|
+
sender?: string;
|
|
378
|
+
account?: string;
|
|
379
|
+
coin?: {
|
|
380
|
+
denom?: string;
|
|
381
|
+
amount?: string;
|
|
382
|
+
} & {
|
|
383
|
+
denom?: string;
|
|
384
|
+
amount?: string;
|
|
385
|
+
} & { [K in Exclude<keyof I["coin"], keyof Coin>]: never; };
|
|
386
|
+
} & { [K_1 in Exclude<keyof I, keyof MsgClawback>]: never; }>(base?: I): MsgClawback;
|
|
387
|
+
fromPartial<I_1 extends {
|
|
388
|
+
sender?: string;
|
|
389
|
+
account?: string;
|
|
390
|
+
coin?: {
|
|
391
|
+
denom?: string;
|
|
392
|
+
amount?: string;
|
|
393
|
+
};
|
|
394
|
+
} & {
|
|
395
|
+
sender?: string;
|
|
396
|
+
account?: string;
|
|
397
|
+
coin?: {
|
|
398
|
+
denom?: string;
|
|
399
|
+
amount?: string;
|
|
400
|
+
} & {
|
|
401
|
+
denom?: string;
|
|
402
|
+
amount?: string;
|
|
403
|
+
} & { [K_2 in Exclude<keyof I_1["coin"], keyof Coin>]: never; };
|
|
404
|
+
} & { [K_3 in Exclude<keyof I_1, keyof MsgClawback>]: never; }>(object: I_1): MsgClawback;
|
|
405
|
+
};
|
|
359
406
|
export declare const EmptyResponse: {
|
|
360
407
|
encode(_: EmptyResponse, writer?: _m0.Writer): _m0.Writer;
|
|
361
408
|
decode(input: _m0.Reader | Uint8Array, length?: number): EmptyResponse;
|
|
@@ -394,6 +441,7 @@ export interface Msg {
|
|
|
394
441
|
GloballyUnfreeze(request: MsgGloballyUnfreeze): Promise<EmptyResponse>;
|
|
395
442
|
/** SetWhitelistedLimit sets the limit of how many tokens a specific account may hold. */
|
|
396
443
|
SetWhitelistedLimit(request: MsgSetWhitelistedLimit): Promise<EmptyResponse>;
|
|
444
|
+
Clawback(request: MsgClawback): Promise<EmptyResponse>;
|
|
397
445
|
}
|
|
398
446
|
export declare class MsgClientImpl implements Msg {
|
|
399
447
|
private readonly rpc;
|
|
@@ -409,6 +457,7 @@ export declare class MsgClientImpl implements Msg {
|
|
|
409
457
|
GloballyFreeze(request: MsgGloballyFreeze): Promise<EmptyResponse>;
|
|
410
458
|
GloballyUnfreeze(request: MsgGloballyUnfreeze): Promise<EmptyResponse>;
|
|
411
459
|
SetWhitelistedLimit(request: MsgSetWhitelistedLimit): Promise<EmptyResponse>;
|
|
460
|
+
Clawback(request: MsgClawback): Promise<EmptyResponse>;
|
|
412
461
|
}
|
|
413
462
|
interface Rpc {
|
|
414
463
|
request(service: string, method: string, data: Uint8Array): Promise<Uint8Array>;
|
|
@@ -700,6 +700,84 @@ export const MsgSetWhitelistedLimit = {
|
|
|
700
700
|
return message;
|
|
701
701
|
},
|
|
702
702
|
};
|
|
703
|
+
function createBaseMsgClawback() {
|
|
704
|
+
return { sender: "", account: "", coin: undefined };
|
|
705
|
+
}
|
|
706
|
+
export const MsgClawback = {
|
|
707
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
708
|
+
if (message.sender !== "") {
|
|
709
|
+
writer.uint32(10).string(message.sender);
|
|
710
|
+
}
|
|
711
|
+
if (message.account !== "") {
|
|
712
|
+
writer.uint32(18).string(message.account);
|
|
713
|
+
}
|
|
714
|
+
if (message.coin !== undefined) {
|
|
715
|
+
Coin.encode(message.coin, writer.uint32(26).fork()).ldelim();
|
|
716
|
+
}
|
|
717
|
+
return writer;
|
|
718
|
+
},
|
|
719
|
+
decode(input, length) {
|
|
720
|
+
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
721
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
722
|
+
const message = createBaseMsgClawback();
|
|
723
|
+
while (reader.pos < end) {
|
|
724
|
+
const tag = reader.uint32();
|
|
725
|
+
switch (tag >>> 3) {
|
|
726
|
+
case 1:
|
|
727
|
+
if (tag != 10) {
|
|
728
|
+
break;
|
|
729
|
+
}
|
|
730
|
+
message.sender = reader.string();
|
|
731
|
+
continue;
|
|
732
|
+
case 2:
|
|
733
|
+
if (tag != 18) {
|
|
734
|
+
break;
|
|
735
|
+
}
|
|
736
|
+
message.account = reader.string();
|
|
737
|
+
continue;
|
|
738
|
+
case 3:
|
|
739
|
+
if (tag != 26) {
|
|
740
|
+
break;
|
|
741
|
+
}
|
|
742
|
+
message.coin = Coin.decode(reader, reader.uint32());
|
|
743
|
+
continue;
|
|
744
|
+
}
|
|
745
|
+
if ((tag & 7) == 4 || tag == 0) {
|
|
746
|
+
break;
|
|
747
|
+
}
|
|
748
|
+
reader.skipType(tag & 7);
|
|
749
|
+
}
|
|
750
|
+
return message;
|
|
751
|
+
},
|
|
752
|
+
fromJSON(object) {
|
|
753
|
+
return {
|
|
754
|
+
sender: isSet(object.sender) ? String(object.sender) : "",
|
|
755
|
+
account: isSet(object.account) ? String(object.account) : "",
|
|
756
|
+
coin: isSet(object.coin) ? Coin.fromJSON(object.coin) : undefined,
|
|
757
|
+
};
|
|
758
|
+
},
|
|
759
|
+
toJSON(message) {
|
|
760
|
+
const obj = {};
|
|
761
|
+
message.sender !== undefined && (obj.sender = message.sender);
|
|
762
|
+
message.account !== undefined && (obj.account = message.account);
|
|
763
|
+
message.coin !== undefined &&
|
|
764
|
+
(obj.coin = message.coin ? Coin.toJSON(message.coin) : undefined);
|
|
765
|
+
return obj;
|
|
766
|
+
},
|
|
767
|
+
create(base) {
|
|
768
|
+
return MsgClawback.fromPartial(base ?? {});
|
|
769
|
+
},
|
|
770
|
+
fromPartial(object) {
|
|
771
|
+
const message = createBaseMsgClawback();
|
|
772
|
+
message.sender = object.sender ?? "";
|
|
773
|
+
message.account = object.account ?? "";
|
|
774
|
+
message.coin =
|
|
775
|
+
object.coin !== undefined && object.coin !== null
|
|
776
|
+
? Coin.fromPartial(object.coin)
|
|
777
|
+
: undefined;
|
|
778
|
+
return message;
|
|
779
|
+
},
|
|
780
|
+
};
|
|
703
781
|
function createBaseEmptyResponse() {
|
|
704
782
|
return {};
|
|
705
783
|
}
|
|
@@ -751,6 +829,7 @@ export class MsgClientImpl {
|
|
|
751
829
|
this.GloballyFreeze = this.GloballyFreeze.bind(this);
|
|
752
830
|
this.GloballyUnfreeze = this.GloballyUnfreeze.bind(this);
|
|
753
831
|
this.SetWhitelistedLimit = this.SetWhitelistedLimit.bind(this);
|
|
832
|
+
this.Clawback = this.Clawback.bind(this);
|
|
754
833
|
}
|
|
755
834
|
Issue(request) {
|
|
756
835
|
const data = MsgIssue.encode(request).finish();
|
|
@@ -792,6 +871,11 @@ export class MsgClientImpl {
|
|
|
792
871
|
const promise = this.rpc.request(this.service, "SetWhitelistedLimit", data);
|
|
793
872
|
return promise.then((data) => EmptyResponse.decode(_m0.Reader.create(data)));
|
|
794
873
|
}
|
|
874
|
+
Clawback(request) {
|
|
875
|
+
const data = MsgClawback.encode(request).finish();
|
|
876
|
+
const promise = this.rpc.request(this.service, "Clawback", data);
|
|
877
|
+
return promise.then((data) => EmptyResponse.decode(_m0.Reader.create(data)));
|
|
878
|
+
}
|
|
795
879
|
}
|
|
796
880
|
if (_m0.util.Long !== Long) {
|
|
797
881
|
_m0.util.Long = Long;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CoreumTypeUrl } from "../../types";
|
|
2
2
|
import { MsgAddToWhitelist, MsgBurn, MsgIssueClass, MsgRemoveFromWhitelist, MsgMint, MsgFreeze, MsgUnfreeze, } from "./nft/v1/tx";
|
|
3
|
-
import { MsgIssue, MsgFreeze as MsgFreezeFT, MsgGloballyFreeze, MsgGloballyUnfreeze, MsgMint as MsgMintFT, MsgBurn as MsgBurnFT, MsgSetWhitelistedLimit, MsgUnfreeze as MsgUnfreezeFT, } from "./ft/v1/tx";
|
|
3
|
+
import { MsgIssue, MsgFreeze as MsgFreezeFT, MsgGloballyFreeze, MsgGloballyUnfreeze, MsgMint as MsgMintFT, MsgBurn as MsgBurnFT, MsgSetWhitelistedLimit, MsgUnfreeze as MsgUnfreezeFT, MsgClawback, } from "./ft/v1/tx";
|
|
4
4
|
export const assetNftRegistry = [
|
|
5
5
|
[CoreumTypeUrl.NFT + "MsgIssueClass", MsgIssueClass],
|
|
6
6
|
[CoreumTypeUrl.NFT + "MsgAddToWhitelist", MsgAddToWhitelist],
|
|
@@ -19,4 +19,5 @@ export const assetFtRegistry = [
|
|
|
19
19
|
[CoreumTypeUrl.FT + "MsgGloballyFreeze", MsgGloballyFreeze],
|
|
20
20
|
[CoreumTypeUrl.FT + "MsgGloballyUnfreeze", MsgGloballyUnfreeze],
|
|
21
21
|
[CoreumTypeUrl.FT + "MsgSetWhitelistedLimit", MsgSetWhitelistedLimit],
|
|
22
|
+
[CoreumTypeUrl.FT + "MsgClawback", MsgClawback],
|
|
22
23
|
];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { GeneratedType } from "@cosmjs/proto-signing";
|
|
2
2
|
import { MsgSend as NFTMsgSend } from "./nft/v1beta1/tx";
|
|
3
3
|
import { MsgIssueClass as NFTMsgIssueClass, MsgMint as NFTMsgMint, MsgAddToWhitelist as NFTMsgAddToWhitelist, MsgBurn as NFTMsgBurn, MsgRemoveFromWhitelist as NFTMsgRemoveFromWhitelist, MsgFreeze as NFTMsgFreeze, MsgUnfreeze as NFTMsgUnfreeze } from "./asset/nft/v1/tx";
|
|
4
|
-
import { MsgIssue as FTMsgIssue, MsgMint as FTMsgMint, MsgBurn as FTMsgBurn, MsgFreeze as FTMsgFreeze, MsgUnfreeze as FTMsgUnfreeze, MsgGloballyFreeze as FTMsgGloballyFreeze, MsgGloballyUnfreeze as FTMsgGloballyUnfreeze, MsgSetWhitelistedLimit as FTMsgSetWhitelistedLimit } from "./asset/ft/v1/tx";
|
|
4
|
+
import { MsgIssue as FTMsgIssue, MsgMint as FTMsgMint, MsgBurn as FTMsgBurn, MsgFreeze as FTMsgFreeze, MsgUnfreeze as FTMsgUnfreeze, MsgGloballyFreeze as FTMsgGloballyFreeze, MsgGloballyUnfreeze as FTMsgGloballyUnfreeze, MsgSetWhitelistedLimit as FTMsgSetWhitelistedLimit, MsgClawback as FTMsgClawback } from "./asset/ft/v1/tx";
|
|
5
5
|
import { FTMsgs, NFTMsgs } from "../types/msgs";
|
|
6
6
|
export { Feature } from "./asset/ft/v1/token";
|
|
7
7
|
export { ClassFeature } from "./asset/nft/v1/nft";
|
|
@@ -98,6 +98,16 @@ export declare namespace FT {
|
|
|
98
98
|
typeUrl: string;
|
|
99
99
|
value: FTMsgSetWhitelistedLimit;
|
|
100
100
|
};
|
|
101
|
+
/** MsgClawback message creator
|
|
102
|
+
* Clawbacks the assets from the specific address.
|
|
103
|
+
*
|
|
104
|
+
* @param object Represents the properties available for this MsgClawback message.
|
|
105
|
+
* @returns A Msg object with the typeUrl and value object for the proper message
|
|
106
|
+
*/
|
|
107
|
+
const Clawback: (object: FTMsgs.MsgClawback) => {
|
|
108
|
+
typeUrl: string;
|
|
109
|
+
value: FTMsgClawback;
|
|
110
|
+
};
|
|
101
111
|
}
|
|
102
112
|
/**
|
|
103
113
|
* Transaction Module for the Non-Fungible Tokens modules (assetnft, nftbeta).
|
|
@@ -2,7 +2,7 @@ import { assetNftRegistry, assetFtRegistry } from "./asset";
|
|
|
2
2
|
import { nftBetaRegistry } from "./nft";
|
|
3
3
|
import { MsgSend as NFTMsgSend } from "./nft/v1beta1/tx";
|
|
4
4
|
import { MsgIssueClass as NFTMsgIssueClass, MsgMint as NFTMsgMint, MsgAddToWhitelist as NFTMsgAddToWhitelist, MsgBurn as NFTMsgBurn, MsgRemoveFromWhitelist as NFTMsgRemoveFromWhitelist, MsgFreeze as NFTMsgFreeze, MsgUnfreeze as NFTMsgUnfreeze, } from "./asset/nft/v1/tx";
|
|
5
|
-
import { MsgIssue as FTMsgIssue, MsgMint as FTMsgMint, MsgBurn as FTMsgBurn, MsgFreeze as FTMsgFreeze, MsgUnfreeze as FTMsgUnfreeze, MsgGloballyFreeze as FTMsgGloballyFreeze, MsgGloballyUnfreeze as FTMsgGloballyUnfreeze, MsgSetWhitelistedLimit as FTMsgSetWhitelistedLimit, } from "./asset/ft/v1/tx";
|
|
5
|
+
import { MsgIssue as FTMsgIssue, MsgMint as FTMsgMint, MsgBurn as FTMsgBurn, MsgFreeze as FTMsgFreeze, MsgUnfreeze as FTMsgUnfreeze, MsgGloballyFreeze as FTMsgGloballyFreeze, MsgGloballyUnfreeze as FTMsgGloballyUnfreeze, MsgSetWhitelistedLimit as FTMsgSetWhitelistedLimit, MsgClawback as FTMsgClawback, } from "./asset/ft/v1/tx";
|
|
6
6
|
export { Feature } from "./asset/ft/v1/token";
|
|
7
7
|
export { ClassFeature } from "./asset/nft/v1/nft";
|
|
8
8
|
/**
|
|
@@ -114,6 +114,18 @@ export var FT;
|
|
|
114
114
|
value: FTMsgSetWhitelistedLimit.fromPartial(object),
|
|
115
115
|
};
|
|
116
116
|
};
|
|
117
|
+
/** MsgClawback message creator
|
|
118
|
+
* Clawbacks the assets from the specific address.
|
|
119
|
+
*
|
|
120
|
+
* @param object Represents the properties available for this MsgClawback message.
|
|
121
|
+
* @returns A Msg object with the typeUrl and value object for the proper message
|
|
122
|
+
*/
|
|
123
|
+
FT.Clawback = function (object) {
|
|
124
|
+
return {
|
|
125
|
+
typeUrl: "/coreum.asset.ft.v1.MsgClawback",
|
|
126
|
+
value: FTMsgClawback.fromPartial(object),
|
|
127
|
+
};
|
|
128
|
+
};
|
|
117
129
|
})(FT || (FT = {}));
|
|
118
130
|
/**
|
|
119
131
|
* Transaction Module for the Non-Fungible Tokens modules (assetnft, nftbeta).
|
|
@@ -62,6 +62,11 @@ export declare namespace FTMsgs {
|
|
|
62
62
|
account: string;
|
|
63
63
|
coin: Coin;
|
|
64
64
|
}
|
|
65
|
+
interface MsgClawback {
|
|
66
|
+
sender: string;
|
|
67
|
+
account: string;
|
|
68
|
+
coin: Coin;
|
|
69
|
+
}
|
|
65
70
|
}
|
|
66
71
|
export declare namespace NFTMsgs {
|
|
67
72
|
/** MsgSend represents a message to send a nft from one account to another account. */
|