@initia/initia.js 0.2.24 → 0.2.26
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/client/rest/api/EvmAPI.d.ts +1 -0
- package/dist/client/rest/api/TxAPI.d.ts +3 -1
- package/dist/core/evm/AccessTuple.d.ts +25 -0
- package/dist/core/evm/EvmParams.d.ts +7 -1
- package/dist/core/evm/index.d.ts +1 -0
- package/dist/core/evm/msgs/MsgCall.d.ts +5 -1
- package/dist/core/evm/msgs/MsgCreate.d.ts +5 -1
- package/dist/core/evm/msgs/MsgCreate2.d.ts +5 -1
- package/dist/core/ibc/applications/nft-transfer/msgs/MsgNftTransfer.d.ts +1 -1
- package/dist/core/ibc/applications/transfer/msgs/MsgTransfer.d.ts +1 -1
- package/dist/core/wasm/msgs/MsgExecuteContract.d.ts +2 -2
- package/dist/core/wasm/msgs/MsgInstantiateContract.d.ts +2 -2
- package/dist/core/wasm/msgs/MsgInstantiateContractV2.d.ts +2 -2
- package/dist/core/wasm/msgs/MsgMigrateContract.d.ts +2 -2
- package/dist/core/wasm/msgs/MsgStoreAndInstantiateContract.d.ts +2 -2
- package/dist/core/wasm/msgs/MsgStoreAndMigrateContract.d.ts +2 -2
- package/dist/core/wasm/msgs/MsgSudoContract.d.ts +2 -2
- package/dist/index.cjs.js +2 -2
- package/dist/index.es.js +6132 -5963
- package/package.json +2 -2
|
@@ -15,6 +15,7 @@ export declare class EvmAPI extends BaseAPI {
|
|
|
15
15
|
code(contract_addr: AccAddress, params?: APIParams): Promise<string>;
|
|
16
16
|
state(contract_addr: AccAddress, key: string, params?: APIParams): Promise<string>;
|
|
17
17
|
erc20Factory(params?: APIParams): Promise<string>;
|
|
18
|
+
erc20Wrapper(params?: APIParams): Promise<string>;
|
|
18
19
|
contractAddrByDenom(denom: string, params?: APIParams): Promise<AccAddress>;
|
|
19
20
|
denom(contract_addr: AccAddress, params?: APIParams): Promise<string>;
|
|
20
21
|
call(sender: AccAddress, contract_addr: AccAddress, input: string, with_trace: boolean): Promise<CallResponse>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BaseAPI } from './BaseAPI';
|
|
2
|
-
import { Msg, Tx, Coins, TxInfo, Fee, PublicKey, TxLog, Event } from '../../../core';
|
|
2
|
+
import { Msg, Tx, Coins, TxInfo, Fee, PublicKey, TxLog, Event, Denom, Coin } from '../../../core';
|
|
3
3
|
import { RESTClient } from '../RESTClient';
|
|
4
4
|
import { APIParams, Pagination, PaginationOptions } from '../APIRequester';
|
|
5
5
|
interface Wait {
|
|
@@ -181,5 +181,7 @@ export declare class TxAPI extends BaseAPI {
|
|
|
181
181
|
broadcastAsync(tx: Tx | string): Promise<AsyncTxBroadcastResult>;
|
|
182
182
|
search(options: Partial<TxSearchOptions>): Promise<TxSearchResult>;
|
|
183
183
|
searchEvents(module_addr: string, module_name: string, start_height: number, end_height: number): Promise<Event[]>;
|
|
184
|
+
gasPrices(params?: APIParams): Promise<Coins>;
|
|
185
|
+
gasPrice(denom: Denom, params?: APIParams): Promise<Coin>;
|
|
184
186
|
}
|
|
185
187
|
export {};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { JSONSerializable } from '../../util/json';
|
|
2
|
+
import { AccAddress } from '../bech32';
|
|
3
|
+
import { AccessTuple as AccessTuple_pb } from '@initia/initia.proto/minievm/evm/v1/types';
|
|
4
|
+
export declare class AccessTuple extends JSONSerializable<AccessTuple.Amino, AccessTuple.Data, AccessTuple.Proto> {
|
|
5
|
+
address: AccAddress;
|
|
6
|
+
storage_keys: string[];
|
|
7
|
+
constructor(address: AccAddress, storage_keys: string[]);
|
|
8
|
+
static fromAmino(data: AccessTuple.Amino): AccessTuple;
|
|
9
|
+
toAmino(): AccessTuple.Amino;
|
|
10
|
+
static fromData(data: AccessTuple.Data): AccessTuple;
|
|
11
|
+
toData(): AccessTuple.Data;
|
|
12
|
+
static fromProto(data: AccessTuple.Proto): AccessTuple;
|
|
13
|
+
toProto(): AccessTuple.Proto;
|
|
14
|
+
}
|
|
15
|
+
export declare namespace AccessTuple {
|
|
16
|
+
interface Amino {
|
|
17
|
+
address: AccAddress;
|
|
18
|
+
storage_keys: string[];
|
|
19
|
+
}
|
|
20
|
+
interface Data {
|
|
21
|
+
address: AccAddress;
|
|
22
|
+
storage_keys: string[];
|
|
23
|
+
}
|
|
24
|
+
type Proto = AccessTuple_pb;
|
|
25
|
+
}
|
|
@@ -6,7 +6,9 @@ export declare class EvmParams extends JSONSerializable<EvmParams.Amino, EvmPara
|
|
|
6
6
|
allow_custom_erc20: boolean;
|
|
7
7
|
allowed_custom_erc20s: string[];
|
|
8
8
|
fee_denom: string;
|
|
9
|
-
|
|
9
|
+
gas_refund_ratio: string;
|
|
10
|
+
num_retain_block_hashes: number;
|
|
11
|
+
constructor(extra_eips: number[], allowed_publishers: string[], allow_custom_erc20: boolean, allowed_custom_erc20s: string[], fee_denom: string, gas_refund_ratio: string, num_retain_block_hashes: number);
|
|
10
12
|
static fromAmino(data: EvmParams.Amino): EvmParams;
|
|
11
13
|
toAmino(): EvmParams.Amino;
|
|
12
14
|
static fromData(data: EvmParams.Data): EvmParams;
|
|
@@ -21,6 +23,8 @@ export declare namespace EvmParams {
|
|
|
21
23
|
allow_custom_erc20: boolean;
|
|
22
24
|
allowed_custom_erc20s: string[];
|
|
23
25
|
fee_denom: string;
|
|
26
|
+
gas_refund_ratio: string;
|
|
27
|
+
num_retain_block_hashes: string;
|
|
24
28
|
}
|
|
25
29
|
interface Data {
|
|
26
30
|
extra_eips: string[];
|
|
@@ -28,6 +32,8 @@ export declare namespace EvmParams {
|
|
|
28
32
|
allow_custom_erc20: boolean;
|
|
29
33
|
allowed_custom_erc20s: string[];
|
|
30
34
|
fee_denom: string;
|
|
35
|
+
gas_refund_ratio: string;
|
|
36
|
+
num_retain_block_hashes: string;
|
|
31
37
|
}
|
|
32
38
|
type Proto = Params_pb;
|
|
33
39
|
}
|
package/dist/core/evm/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { JSONSerializable } from '../../../util/json';
|
|
2
2
|
import { AccAddress } from '../../bech32';
|
|
3
|
+
import { AccessTuple } from '../AccessTuple';
|
|
3
4
|
import { Any } from '@initia/initia.proto/google/protobuf/any';
|
|
4
5
|
import { MsgCall as MsgCall_pb } from '@initia/initia.proto/minievm/evm/v1/tx';
|
|
5
6
|
export declare class MsgCall extends JSONSerializable<MsgCall.Amino, MsgCall.Data, MsgCall.Proto> {
|
|
@@ -7,7 +8,8 @@ export declare class MsgCall extends JSONSerializable<MsgCall.Amino, MsgCall.Dat
|
|
|
7
8
|
contract_addr: AccAddress;
|
|
8
9
|
input: string;
|
|
9
10
|
value: string;
|
|
10
|
-
|
|
11
|
+
access_list: AccessTuple[];
|
|
12
|
+
constructor(sender: AccAddress, contract_addr: AccAddress, input: string, value: string, access_list: AccessTuple[]);
|
|
11
13
|
static fromAmino(data: MsgCall.Amino): MsgCall;
|
|
12
14
|
toAmino(): MsgCall.Amino;
|
|
13
15
|
static fromData(data: MsgCall.Data): MsgCall;
|
|
@@ -25,6 +27,7 @@ export declare namespace MsgCall {
|
|
|
25
27
|
contract_addr: AccAddress;
|
|
26
28
|
input: string;
|
|
27
29
|
value: string;
|
|
30
|
+
access_list: AccessTuple.Amino[];
|
|
28
31
|
};
|
|
29
32
|
}
|
|
30
33
|
interface Data {
|
|
@@ -33,6 +36,7 @@ export declare namespace MsgCall {
|
|
|
33
36
|
contract_addr: AccAddress;
|
|
34
37
|
input: string;
|
|
35
38
|
value: string;
|
|
39
|
+
access_list: AccessTuple.Data[];
|
|
36
40
|
}
|
|
37
41
|
type Proto = MsgCall_pb;
|
|
38
42
|
}
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import { JSONSerializable } from '../../../util/json';
|
|
2
2
|
import { AccAddress } from '../../bech32';
|
|
3
|
+
import { AccessTuple } from '../AccessTuple';
|
|
3
4
|
import { Any } from '@initia/initia.proto/google/protobuf/any';
|
|
4
5
|
import { MsgCreate as MsgCreate_pb } from '@initia/initia.proto/minievm/evm/v1/tx';
|
|
5
6
|
export declare class MsgCreate extends JSONSerializable<MsgCreate.Amino, MsgCreate.Data, MsgCreate.Proto> {
|
|
6
7
|
sender: AccAddress;
|
|
7
8
|
code: string;
|
|
8
9
|
value: string;
|
|
9
|
-
|
|
10
|
+
access_list: AccessTuple[];
|
|
11
|
+
constructor(sender: AccAddress, code: string, value: string, access_list: AccessTuple[]);
|
|
10
12
|
static fromAmino(data: MsgCreate.Amino): MsgCreate;
|
|
11
13
|
toAmino(): MsgCreate.Amino;
|
|
12
14
|
static fromData(data: MsgCreate.Data): MsgCreate;
|
|
@@ -23,6 +25,7 @@ export declare namespace MsgCreate {
|
|
|
23
25
|
sender: AccAddress;
|
|
24
26
|
code: string;
|
|
25
27
|
value: string;
|
|
28
|
+
access_list: AccessTuple.Amino[];
|
|
26
29
|
};
|
|
27
30
|
}
|
|
28
31
|
interface Data {
|
|
@@ -30,6 +33,7 @@ export declare namespace MsgCreate {
|
|
|
30
33
|
sender: AccAddress;
|
|
31
34
|
code: string;
|
|
32
35
|
value: string;
|
|
36
|
+
access_list: AccessTuple.Data[];
|
|
33
37
|
}
|
|
34
38
|
type Proto = MsgCreate_pb;
|
|
35
39
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { JSONSerializable } from '../../../util/json';
|
|
2
2
|
import { AccAddress } from '../../bech32';
|
|
3
|
+
import { AccessTuple } from '../AccessTuple';
|
|
3
4
|
import { Any } from '@initia/initia.proto/google/protobuf/any';
|
|
4
5
|
import { MsgCreate2 as MsgCreate2_pb } from '@initia/initia.proto/minievm/evm/v1/tx';
|
|
5
6
|
export declare class MsgCreate2 extends JSONSerializable<MsgCreate2.Amino, MsgCreate2.Data, MsgCreate2.Proto> {
|
|
@@ -7,7 +8,8 @@ export declare class MsgCreate2 extends JSONSerializable<MsgCreate2.Amino, MsgCr
|
|
|
7
8
|
code: string;
|
|
8
9
|
salt: number;
|
|
9
10
|
value: string;
|
|
10
|
-
|
|
11
|
+
access_list: AccessTuple[];
|
|
12
|
+
constructor(sender: AccAddress, code: string, salt: number, value: string, access_list: AccessTuple[]);
|
|
11
13
|
static fromAmino(data: MsgCreate2.Amino): MsgCreate2;
|
|
12
14
|
toAmino(): MsgCreate2.Amino;
|
|
13
15
|
static fromData(data: MsgCreate2.Data): MsgCreate2;
|
|
@@ -25,6 +27,7 @@ export declare namespace MsgCreate2 {
|
|
|
25
27
|
code: string;
|
|
26
28
|
salt: string;
|
|
27
29
|
value: string;
|
|
30
|
+
access_list: AccessTuple.Amino[];
|
|
28
31
|
};
|
|
29
32
|
}
|
|
30
33
|
interface Data {
|
|
@@ -33,6 +36,7 @@ export declare namespace MsgCreate2 {
|
|
|
33
36
|
code: string;
|
|
34
37
|
salt: string;
|
|
35
38
|
value: string;
|
|
39
|
+
access_list: AccessTuple.Data[];
|
|
36
40
|
}
|
|
37
41
|
type Proto = MsgCreate2_pb;
|
|
38
42
|
}
|
|
@@ -24,7 +24,7 @@ export declare namespace MsgExecuteContract {
|
|
|
24
24
|
value: {
|
|
25
25
|
sender: AccAddress;
|
|
26
26
|
contract: AccAddress;
|
|
27
|
-
msg:
|
|
27
|
+
msg: JSON;
|
|
28
28
|
funds: Coins.Amino;
|
|
29
29
|
};
|
|
30
30
|
}
|
|
@@ -32,7 +32,7 @@ export declare namespace MsgExecuteContract {
|
|
|
32
32
|
'@type': '/cosmwasm.wasm.v1.MsgExecuteContract';
|
|
33
33
|
sender: AccAddress;
|
|
34
34
|
contract: AccAddress;
|
|
35
|
-
msg:
|
|
35
|
+
msg: JSON;
|
|
36
36
|
funds: Coins.Data;
|
|
37
37
|
}
|
|
38
38
|
type Proto = MsgExecuteContract_pb;
|
|
@@ -28,7 +28,7 @@ export declare namespace MsgInstantiateContract {
|
|
|
28
28
|
admin?: AccAddress;
|
|
29
29
|
code_id: string;
|
|
30
30
|
label?: string;
|
|
31
|
-
msg:
|
|
31
|
+
msg: JSON;
|
|
32
32
|
funds: Coins.Amino;
|
|
33
33
|
};
|
|
34
34
|
}
|
|
@@ -38,7 +38,7 @@ export declare namespace MsgInstantiateContract {
|
|
|
38
38
|
admin?: AccAddress;
|
|
39
39
|
code_id: string;
|
|
40
40
|
label?: string;
|
|
41
|
-
msg:
|
|
41
|
+
msg: JSON;
|
|
42
42
|
funds: Coins.Data;
|
|
43
43
|
}
|
|
44
44
|
type Proto = MsgInstantiateContract_pb;
|
|
@@ -30,7 +30,7 @@ export declare namespace MsgInstantiateContractV2 {
|
|
|
30
30
|
admin?: AccAddress;
|
|
31
31
|
code_id: string;
|
|
32
32
|
label?: string;
|
|
33
|
-
msg:
|
|
33
|
+
msg: JSON;
|
|
34
34
|
funds: Coins.Amino;
|
|
35
35
|
salt: string;
|
|
36
36
|
fix_msg: boolean;
|
|
@@ -42,7 +42,7 @@ export declare namespace MsgInstantiateContractV2 {
|
|
|
42
42
|
admin?: AccAddress;
|
|
43
43
|
code_id: string;
|
|
44
44
|
label?: string;
|
|
45
|
-
msg:
|
|
45
|
+
msg: JSON;
|
|
46
46
|
funds: Coins.Data;
|
|
47
47
|
salt: string;
|
|
48
48
|
fix_msg: boolean;
|
|
@@ -24,7 +24,7 @@ export declare namespace MsgMigrateContract {
|
|
|
24
24
|
sender: AccAddress;
|
|
25
25
|
contract: AccAddress;
|
|
26
26
|
code_id: string;
|
|
27
|
-
msg:
|
|
27
|
+
msg: JSON;
|
|
28
28
|
};
|
|
29
29
|
}
|
|
30
30
|
interface Data {
|
|
@@ -32,7 +32,7 @@ export declare namespace MsgMigrateContract {
|
|
|
32
32
|
sender: AccAddress;
|
|
33
33
|
contract: AccAddress;
|
|
34
34
|
code_id: string;
|
|
35
|
-
msg:
|
|
35
|
+
msg: JSON;
|
|
36
36
|
}
|
|
37
37
|
type Proto = MsgMigrateContract_pb;
|
|
38
38
|
}
|
|
@@ -36,7 +36,7 @@ export declare namespace MsgStoreAndInstantiateContract {
|
|
|
36
36
|
unpin_code?: boolean;
|
|
37
37
|
admin?: AccAddress;
|
|
38
38
|
label?: string;
|
|
39
|
-
msg:
|
|
39
|
+
msg: JSON;
|
|
40
40
|
funds: Coins.Amino;
|
|
41
41
|
source: string;
|
|
42
42
|
builder: string;
|
|
@@ -51,7 +51,7 @@ export declare namespace MsgStoreAndInstantiateContract {
|
|
|
51
51
|
unpin_code?: boolean;
|
|
52
52
|
admin?: AccAddress;
|
|
53
53
|
label?: string;
|
|
54
|
-
msg:
|
|
54
|
+
msg: JSON;
|
|
55
55
|
funds: Coins.Amino;
|
|
56
56
|
source: string;
|
|
57
57
|
builder: string;
|
|
@@ -27,7 +27,7 @@ export declare namespace MsgStoreAndMigrateContract {
|
|
|
27
27
|
wasm_byte_code: string;
|
|
28
28
|
instantiate_permission?: AccessConfig.Amino;
|
|
29
29
|
contract: AccAddress;
|
|
30
|
-
msg:
|
|
30
|
+
msg: JSON;
|
|
31
31
|
};
|
|
32
32
|
}
|
|
33
33
|
interface Data {
|
|
@@ -36,7 +36,7 @@ export declare namespace MsgStoreAndMigrateContract {
|
|
|
36
36
|
wasm_byte_code: string;
|
|
37
37
|
instantiate_permission?: AccessConfig.Data;
|
|
38
38
|
contract: AccAddress;
|
|
39
|
-
msg:
|
|
39
|
+
msg: JSON;
|
|
40
40
|
}
|
|
41
41
|
type Proto = MsgStoreAndMigrateContract_pb;
|
|
42
42
|
}
|
|
@@ -22,14 +22,14 @@ export declare namespace MsgSudoContract {
|
|
|
22
22
|
value: {
|
|
23
23
|
authority: AccAddress;
|
|
24
24
|
contract: AccAddress;
|
|
25
|
-
msg:
|
|
25
|
+
msg: JSON;
|
|
26
26
|
};
|
|
27
27
|
}
|
|
28
28
|
interface Data {
|
|
29
29
|
'@type': '/cosmwasm.wasm.v1.MsgSudoContract';
|
|
30
30
|
authority: AccAddress;
|
|
31
31
|
contract: AccAddress;
|
|
32
|
-
msg:
|
|
32
|
+
msg: JSON;
|
|
33
33
|
}
|
|
34
34
|
type Proto = MsgSudoContract_pb;
|
|
35
35
|
}
|