@initia/initia.js 0.2.24 → 0.2.25

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.
@@ -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
- constructor(extra_eips: number[], allowed_publishers: string[], allow_custom_erc20: boolean, allowed_custom_erc20s: string[], fee_denom: string);
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
  }
@@ -1,2 +1,3 @@
1
1
  export * from './msgs';
2
2
  export * from './EvmParams';
3
+ export * from './AccessTuple';
@@ -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
- constructor(sender: AccAddress, contract_addr: AccAddress, input: string, value: string);
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
- constructor(sender: AccAddress, code: string, value: string);
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
- constructor(sender: AccAddress, code: string, salt: number, value: string);
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
  }