@iotexproject/kit 0.1.38 → 0.1.40

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.
Files changed (2) hide show
  1. package/dist/index.d.ts +119 -13
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -8862,6 +8862,7 @@ export type LaunchPadParam = {
8862
8862
  initialBuyAmount: string;
8863
8863
  };
8864
8864
  export type CreateProjectParams = {
8865
+ id?: number;
8865
8866
  recipient: `0x${string}`;
8866
8867
  projectName: string;
8867
8868
  tokenAddress: string;
@@ -8898,14 +8899,11 @@ declare class BondingCurve {
8898
8899
  chainId?: undefined;
8899
8900
  value?: undefined;
8900
8901
  }>;
8901
- upsertProject(args: CreateProjectParams, ctx?: ConfigContext): Promise<{
8902
- ok: boolean;
8903
- error?: undefined;
8904
- } | {
8905
- error: unknown;
8906
- ok?: undefined;
8907
- }>;
8908
- projectList(args: {}, ctx?: ConfigContext): Promise<postgres.RowList<postgres.Row[]>>;
8902
+ upsertProject(args: CreateProjectParams, ctx?: ConfigContext): Promise<postgres.Row | postgres.RowList<postgres.Row[]>>;
8903
+ projectList(args: {}, ctx?: ConfigContext): Promise<postgres.RowList<postgres.Row[]> | undefined>;
8904
+ projectDetail(args: {
8905
+ projectName: string;
8906
+ }, ctx?: ConfigContext): Promise<postgres.Row | undefined>;
8909
8907
  tokenList(args: {
8910
8908
  account: `0x${string}`;
8911
8909
  }, ctx?: ConfigContext): Promise<{
@@ -8932,7 +8930,7 @@ declare class BondingCurve {
8932
8930
  allowance: (owner: string, spender: string) => Promise<any>;
8933
8931
  approve: (spender: `0x${string}`, amount: string, owner: `0x${string}`) => Promise<`0x${string}` | null>;
8934
8932
  priceUSD: () => Promise<any>;
8935
- tokenUrl: () => Promise<any>;
8933
+ tokenUrl: any;
8936
8934
  }[]>;
8937
8935
  swap(args: SwapParams, ctx?: ConfigContext): Promise<{
8938
8936
  data: {
@@ -8940,6 +8938,7 @@ declare class BondingCurve {
8940
8938
  data: any;
8941
8939
  chainId: string;
8942
8940
  value: string;
8941
+ type: string;
8943
8942
  }[];
8944
8943
  quote: string;
8945
8944
  error?: undefined;
@@ -8948,6 +8947,7 @@ declare class BondingCurve {
8948
8947
  address: `0x${string}`;
8949
8948
  data: any;
8950
8949
  chainId: string;
8950
+ type: string;
8951
8951
  }[];
8952
8952
  quote: string;
8953
8953
  error?: undefined;
@@ -8983,7 +8983,8 @@ declare class BaseDBModule {
8983
8983
  iopay: ReturnType<typeof postgres>;
8984
8984
  nftmarket: ReturnType<typeof postgres>;
8985
8985
  ch: ClickHouseSDK;
8986
- analysis: ClickHouseSDK;
8986
+ analysisDev: ClickHouseSDK;
8987
+ analysisProd: ClickHouseSDK;
8987
8988
  constructor();
8988
8989
  checkAuth(key: string): Promise<{
8989
8990
  ok: boolean;
@@ -9013,7 +9014,107 @@ declare class Account extends BaseDBModule {
9013
9014
  tokens: import("postgres").RowList<import("postgres").Row[]>;
9014
9015
  }>;
9015
9016
  }
9016
- declare class Analysis extends BaseDBModule {
9017
+ declare class AnalysisDev extends BaseDBModule {
9018
+ checkAuth(key: string): Promise<{
9019
+ ok: boolean;
9020
+ message: string;
9021
+ authData: null;
9022
+ } | {
9023
+ ok: boolean;
9024
+ message: string;
9025
+ authData: {
9026
+ app_id: any;
9027
+ api_key: string;
9028
+ };
9029
+ }>;
9030
+ upload_event({ user_id, event_type, event_id, event }: {
9031
+ event_type: string;
9032
+ user_id: string;
9033
+ event_id: string;
9034
+ event: Record<string, any>;
9035
+ }, ctx?: {
9036
+ authData?: {
9037
+ app_id: string;
9038
+ api_key: string;
9039
+ };
9040
+ }): Promise<{
9041
+ ok: boolean;
9042
+ msg: any;
9043
+ }>;
9044
+ referral_code({ refer_id, }: {
9045
+ refer_id: string;
9046
+ }, ctx?: {
9047
+ authData?: {
9048
+ app_id: string;
9049
+ api_key: string;
9050
+ };
9051
+ }): Promise<{
9052
+ ok: boolean;
9053
+ referral_code: any;
9054
+ msg: string;
9055
+ } | {
9056
+ ok: boolean;
9057
+ msg: any;
9058
+ referral_code?: undefined;
9059
+ }>;
9060
+ create_refer({ refer_id, refer_id_type, user_id, device_id, data, }: {
9061
+ refer_id: string;
9062
+ refer_id_type: "referral_code" | "user_id";
9063
+ user_id: string;
9064
+ device_id: string;
9065
+ data: Record<string, any>;
9066
+ }, ctx?: {
9067
+ authData?: {
9068
+ app_id: string;
9069
+ api_key: string;
9070
+ };
9071
+ }): Promise<{
9072
+ ok: boolean;
9073
+ msg: any;
9074
+ }>;
9075
+ fetch_event({ event_id }: {
9076
+ event_id: string;
9077
+ }): Promise<Record<string, any>>;
9078
+ batch_fetch_event({ event_ids }: {
9079
+ event_ids: string[];
9080
+ }): Promise<any[] | {
9081
+ ok: boolean;
9082
+ msg: string;
9083
+ }>;
9084
+ fetch_user_point({ user_id, }: {
9085
+ user_id: string;
9086
+ }, ctx?: {
9087
+ authData?: {
9088
+ app_id: string;
9089
+ api_key: string;
9090
+ };
9091
+ }): Promise<{
9092
+ ok: boolean;
9093
+ point: any;
9094
+ msg?: undefined;
9095
+ } | {
9096
+ ok: boolean;
9097
+ msg: any;
9098
+ point?: undefined;
9099
+ }>;
9100
+ fetch_invitees_num({ user_id, }: {
9101
+ user_id: string;
9102
+ }, ctx?: {
9103
+ authData?: {
9104
+ app_id: string;
9105
+ api_key: string;
9106
+ };
9107
+ }): Promise<{
9108
+ ok: boolean;
9109
+ invitees_num: any;
9110
+ msg?: undefined;
9111
+ } | {
9112
+ ok: boolean;
9113
+ msg: any;
9114
+ invitees_num?: undefined;
9115
+ }>;
9116
+ }
9117
+ declare class AnalysisProd extends BaseDBModule {
9017
9118
  checkAuth(key: string): Promise<{
9018
9119
  ok: boolean;
9019
9120
  message: string;
@@ -9317,7 +9418,8 @@ declare const modules$1: {
9317
9418
  transaction: Transaction;
9318
9419
  nft: NFT;
9319
9420
  health: Health;
9320
- analysis: Analysis;
9421
+ "analysis-dev": AnalysisDev;
9422
+ "analysis-prod": AnalysisProd;
9321
9423
  contract: Contract;
9322
9424
  resource: Resource;
9323
9425
  iopay: IoPay;
@@ -10397,7 +10499,10 @@ declare class Point {
10397
10499
  }): Promise<any>;
10398
10500
  fetch_tasks({ user_id }: {
10399
10501
  user_id: string;
10400
- }): Promise<any>;
10502
+ }): Promise<any[] | {
10503
+ ok: boolean;
10504
+ msg: string;
10505
+ }>;
10401
10506
  fetch_point({ user_id }: {
10402
10507
  user_id: string;
10403
10508
  }): Promise<any>;
@@ -10407,6 +10512,7 @@ declare class Point {
10407
10512
  }
10408
10513
  declare const modules$4: {
10409
10514
  point: Point;
10515
+ health: Health;
10410
10516
  };
10411
10517
  export type IoPayModuleType = typeof modules$4;
10412
10518
  export type IotexscanAdapterType<T extends Record<string, Record<string, any>>> = {
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@iotexproject/kit",
3
3
  "module": "index.ts",
4
4
  "type": "module",
5
- "version": "v0.1.38",
5
+ "version": "v0.1.40",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",
8
8
  "scripts": {