carbon-js-sdk 0.4.12 → 0.4.14
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.
|
@@ -20,6 +20,7 @@ declare class InsightsQueryClient {
|
|
|
20
20
|
VolumeCompetitionLeaderboard(req: Insights.QueryGetVolumeCompetitionLeaderboardRequest): Promise<Insights.InsightsQueryResponse<Insights.QueryGetVolumeCompetitionLeaderboardResponse>>;
|
|
21
21
|
PNLCompetitionLeaderboard(req: Insights.QueryGetPNLCompetitionLeaderboardRequest): Promise<Insights.InsightsQueryResponse<Insights.QueryGetPNLCompetitionLeaderboardResponse>>;
|
|
22
22
|
LotteryCompetitionLeaderboard(req: Insights.QueryGetLotteryCompetitionLeaderboardRequest): Promise<Insights.InsightsQueryResponse<Insights.QueryGetLotteryCompetitionLeaderboardResponse>>;
|
|
23
|
+
LeagueCompetitionLeaderboard(req: Insights.QueryGetLeagueCompetitionLeaderboardRequest): Promise<Insights.InsightsQueryResponse<Insights.QueryGetLeagueCompetitionLeaderboardResponse>>;
|
|
23
24
|
PoolsLiquidity(req?: Insights.QueryGetPoolsLiquidityRequest): Promise<Insights.InsightsQueryResponse<Insights.QueryGetPoolsLiquidityResponse>>;
|
|
24
25
|
MarketsVolume(req?: Insights.QueryGetMarketVolumeRequest): Promise<Insights.InsightsQueryResponse<Insights.QueryGetMarketVolumeResponse>>;
|
|
25
26
|
Nodes(req?: Insights.QueryGetNodesRequest): Promise<Insights.InsightsQueryResponse<Insights.QueryGetNodesResponse>>;
|
|
@@ -166,6 +166,16 @@ class InsightsQueryClient {
|
|
|
166
166
|
return response.data;
|
|
167
167
|
});
|
|
168
168
|
}
|
|
169
|
+
LeagueCompetitionLeaderboard(req) {
|
|
170
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
171
|
+
const queryParams = {
|
|
172
|
+
competitionId: req.competitionId,
|
|
173
|
+
};
|
|
174
|
+
const request = this.apiManager.path("competition/leaderboardleague", {}, queryParams);
|
|
175
|
+
const response = yield request.get();
|
|
176
|
+
return response.data;
|
|
177
|
+
});
|
|
178
|
+
}
|
|
169
179
|
PoolsLiquidity(req = {}) {
|
|
170
180
|
return __awaiter(this, void 0, void 0, function* () {
|
|
171
181
|
const queryParams = {
|
package/lib/insights/common.d.ts
CHANGED
|
@@ -27,6 +27,7 @@ export declare const InsightsEndpoints: {
|
|
|
27
27
|
"competition/leaderboard": string;
|
|
28
28
|
"competition/leaderboardpnl": string;
|
|
29
29
|
"competition/leaderboardlottery": string;
|
|
30
|
+
"competition/leaderboardleague": string;
|
|
30
31
|
"info/denom_gecko_map": string;
|
|
31
32
|
"market/funding": string;
|
|
32
33
|
};
|
package/lib/insights/common.js
CHANGED
|
@@ -38,6 +38,7 @@ exports.InsightsEndpoints = {
|
|
|
38
38
|
"competition/leaderboard": "/competition/leaderboard",
|
|
39
39
|
"competition/leaderboardpnl": "/competition/leaderboardpnl",
|
|
40
40
|
"competition/leaderboardlottery": "/competition/leaderboardlottery",
|
|
41
|
+
"competition/leaderboardleague": "/competition/leaderboardleague",
|
|
41
42
|
//Coin Gecko Tokens api
|
|
42
43
|
"info/denom_gecko_map": "/info/denom_gecko_map",
|
|
43
44
|
//funding
|
|
@@ -65,6 +65,20 @@ export interface LotteryLeaderboardEntry {
|
|
|
65
65
|
positionTickets: string;
|
|
66
66
|
totalTickets: string;
|
|
67
67
|
}
|
|
68
|
+
export interface LeaderboardLeagueEntry {
|
|
69
|
+
rank: string;
|
|
70
|
+
totalPoints: string;
|
|
71
|
+
address: string;
|
|
72
|
+
volume: string;
|
|
73
|
+
spotsVolume: string;
|
|
74
|
+
derVolume: string;
|
|
75
|
+
freq: string;
|
|
76
|
+
username: string | null;
|
|
77
|
+
twitter: string | null;
|
|
78
|
+
spotsPoint: string;
|
|
79
|
+
derPoints: string;
|
|
80
|
+
freqFactor: string;
|
|
81
|
+
}
|
|
68
82
|
export interface QueryGetPNLCompetitionLeaderboardResponse {
|
|
69
83
|
entries: PNLLeaderboardEntry[];
|
|
70
84
|
meta: TimeMeta;
|
|
@@ -76,7 +90,13 @@ export interface QueryGetPNLCompetitionLeaderboardRequest {
|
|
|
76
90
|
export interface QueryGetLotteryCompetitionLeaderboardResponse {
|
|
77
91
|
entries: LotteryLeaderboardEntry[];
|
|
78
92
|
}
|
|
93
|
+
export interface QueryGetLeagueCompetitionLeaderboardResponse {
|
|
94
|
+
entries: LeaderboardLeagueEntry[];
|
|
95
|
+
}
|
|
79
96
|
export interface QueryGetLotteryCompetitionLeaderboardRequest {
|
|
80
97
|
competitionId: string;
|
|
81
98
|
market?: string;
|
|
82
99
|
}
|
|
100
|
+
export interface QueryGetLeagueCompetitionLeaderboardRequest {
|
|
101
|
+
competitionId: string;
|
|
102
|
+
}
|
|
@@ -7,8 +7,11 @@ interface RequestArguments {
|
|
|
7
7
|
params?: unknown[] | object;
|
|
8
8
|
}
|
|
9
9
|
interface MetaMaskAPI {
|
|
10
|
+
isMetaMask: boolean;
|
|
11
|
+
chainId: string | null;
|
|
10
12
|
isConnected: () => boolean;
|
|
11
13
|
request: (args: RequestArguments) => Promise<unknown>;
|
|
14
|
+
on: (eventName: string, listener: (...args: unknown[]) => void) => any;
|
|
12
15
|
}
|
|
13
16
|
export interface MetaMaskChangeNetworkParam {
|
|
14
17
|
chainId: string;
|