@coingecko/coingecko-typescript 1.14.0 → 1.15.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/CHANGELOG.md +14 -0
- package/client.d.mts +6 -3
- package/client.d.mts.map +1 -1
- package/client.d.ts +6 -3
- package/client.d.ts.map +1 -1
- package/client.js +6 -3
- package/client.js.map +1 -1
- package/client.mjs +6 -3
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/coins/circulating-supply-chart.d.mts +7 -5
- package/resources/coins/circulating-supply-chart.d.mts.map +1 -1
- package/resources/coins/circulating-supply-chart.d.ts +7 -5
- package/resources/coins/circulating-supply-chart.d.ts.map +1 -1
- package/resources/coins/circulating-supply-chart.js +1 -1
- package/resources/coins/circulating-supply-chart.mjs +1 -1
- package/resources/coins/contract/market-chart.d.mts +13 -5
- package/resources/coins/contract/market-chart.d.mts.map +1 -1
- package/resources/coins/contract/market-chart.d.ts +13 -5
- package/resources/coins/contract/market-chart.d.ts.map +1 -1
- package/resources/coins/contract/market-chart.js +6 -1
- package/resources/coins/contract/market-chart.js.map +1 -1
- package/resources/coins/contract/market-chart.mjs +6 -1
- package/resources/coins/contract/market-chart.mjs.map +1 -1
- package/resources/coins/history.d.mts +2 -2
- package/resources/coins/history.d.ts +2 -2
- package/resources/coins/history.js +1 -1
- package/resources/coins/history.mjs +1 -1
- package/resources/coins/market-chart.d.mts +7 -5
- package/resources/coins/market-chart.d.mts.map +1 -1
- package/resources/coins/market-chart.d.ts +7 -5
- package/resources/coins/market-chart.d.ts.map +1 -1
- package/resources/coins/market-chart.js +1 -1
- package/resources/coins/market-chart.mjs +1 -1
- package/resources/coins/markets.d.mts +1 -1
- package/resources/coins/markets.d.ts +1 -1
- package/resources/coins/ohlc.d.mts +12 -5
- package/resources/coins/ohlc.d.mts.map +1 -1
- package/resources/coins/ohlc.d.ts +12 -5
- package/resources/coins/ohlc.d.ts.map +1 -1
- package/resources/coins/ohlc.js +6 -1
- package/resources/coins/ohlc.js.map +1 -1
- package/resources/coins/ohlc.mjs +6 -1
- package/resources/coins/ohlc.mjs.map +1 -1
- package/resources/coins/top-gainers-losers.d.mts +95 -5
- package/resources/coins/top-gainers-losers.d.mts.map +1 -1
- package/resources/coins/top-gainers-losers.d.ts +95 -5
- package/resources/coins/top-gainers-losers.d.ts.map +1 -1
- package/resources/coins/top-gainers-losers.js +1 -1
- package/resources/coins/top-gainers-losers.mjs +1 -1
- package/resources/coins/total-supply-chart.d.mts +8 -6
- package/resources/coins/total-supply-chart.d.mts.map +1 -1
- package/resources/coins/total-supply-chart.d.ts +8 -6
- package/resources/coins/total-supply-chart.d.ts.map +1 -1
- package/resources/coins/total-supply-chart.js +2 -2
- package/resources/coins/total-supply-chart.mjs +2 -2
- package/resources/derivatives/exchanges.d.mts +2 -2
- package/resources/derivatives/exchanges.d.ts +2 -2
- package/resources/derivatives/exchanges.js +2 -2
- package/resources/derivatives/exchanges.mjs +2 -2
- package/resources/entities.d.mts +54 -0
- package/resources/entities.d.mts.map +1 -0
- package/resources/entities.d.ts +54 -0
- package/resources/entities.d.ts.map +1 -0
- package/resources/entities.js +21 -0
- package/resources/entities.js.map +1 -0
- package/resources/entities.mjs +17 -0
- package/resources/entities.mjs.map +1 -0
- package/resources/exchanges/exchanges.d.mts +3 -3
- package/resources/exchanges/exchanges.d.ts +3 -3
- package/resources/exchanges/exchanges.js +3 -3
- package/resources/exchanges/exchanges.mjs +3 -3
- package/resources/exchanges/tickers.d.mts +2 -2
- package/resources/exchanges/tickers.d.mts.map +1 -1
- package/resources/exchanges/tickers.d.ts +2 -2
- package/resources/exchanges/tickers.d.ts.map +1 -1
- package/resources/exchanges/tickers.js +1 -1
- package/resources/exchanges/tickers.mjs +1 -1
- package/resources/exchanges/volume-chart.d.mts +2 -2
- package/resources/exchanges/volume-chart.d.ts +2 -2
- package/resources/exchanges/volume-chart.js +2 -2
- package/resources/exchanges/volume-chart.mjs +2 -2
- package/resources/index.d.mts +2 -1
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +2 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +5 -3
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +2 -1
- package/resources/index.mjs.map +1 -1
- package/resources/onchain/networks/pools/info.d.mts +72 -48
- package/resources/onchain/networks/pools/info.d.mts.map +1 -1
- package/resources/onchain/networks/pools/info.d.ts +72 -48
- package/resources/onchain/networks/pools/info.d.ts.map +1 -1
- package/resources/onchain/networks/pools/info.js +5 -2
- package/resources/onchain/networks/pools/info.js.map +1 -1
- package/resources/onchain/networks/pools/info.mjs +5 -2
- package/resources/onchain/networks/pools/info.mjs.map +1 -1
- package/resources/onchain/networks/pools/multi.d.mts +35 -0
- package/resources/onchain/networks/pools/multi.d.mts.map +1 -1
- package/resources/onchain/networks/pools/multi.d.ts +35 -0
- package/resources/onchain/networks/pools/multi.d.ts.map +1 -1
- package/resources/onchain/networks/pools/ohlcv.d.mts +2 -2
- package/resources/onchain/networks/pools/ohlcv.d.mts.map +1 -1
- package/resources/onchain/networks/pools/ohlcv.d.ts +2 -2
- package/resources/onchain/networks/pools/ohlcv.d.ts.map +1 -1
- package/resources/onchain/networks/pools/ohlcv.js.map +1 -1
- package/resources/onchain/networks/pools/ohlcv.mjs.map +1 -1
- package/resources/onchain/networks/pools/pools.d.mts +35 -0
- package/resources/onchain/networks/pools/pools.d.mts.map +1 -1
- package/resources/onchain/networks/pools/pools.d.ts +35 -0
- package/resources/onchain/networks/pools/pools.d.ts.map +1 -1
- package/resources/onchain/networks/pools/pools.js.map +1 -1
- package/resources/onchain/networks/pools/pools.mjs.map +1 -1
- package/resources/onchain/networks/tokens/info.d.mts +1 -1
- package/resources/onchain/networks/tokens/info.d.mts.map +1 -1
- package/resources/onchain/networks/tokens/info.d.ts +1 -1
- package/resources/onchain/networks/tokens/info.d.ts.map +1 -1
- package/resources/onchain/networks/tokens/multi.d.mts +132 -0
- package/resources/onchain/networks/tokens/multi.d.mts.map +1 -1
- package/resources/onchain/networks/tokens/multi.d.ts +132 -0
- package/resources/onchain/networks/tokens/multi.d.ts.map +1 -1
- package/resources/onchain/networks/tokens/ohlcv.d.mts +2 -2
- package/resources/onchain/networks/tokens/ohlcv.d.mts.map +1 -1
- package/resources/onchain/networks/tokens/ohlcv.d.ts +2 -2
- package/resources/onchain/networks/tokens/ohlcv.d.ts.map +1 -1
- package/resources/onchain/networks/tokens/ohlcv.js.map +1 -1
- package/resources/onchain/networks/tokens/ohlcv.mjs.map +1 -1
- package/resources/onchain/networks/tokens/tokens.d.mts +15 -0
- package/resources/onchain/networks/tokens/tokens.d.mts.map +1 -1
- package/resources/onchain/networks/tokens/tokens.d.ts +15 -0
- package/resources/onchain/networks/tokens/tokens.d.ts.map +1 -1
- package/resources/onchain/networks/tokens/tokens.js.map +1 -1
- package/resources/onchain/networks/tokens/tokens.mjs.map +1 -1
- package/resources/onchain/pools/megafilter.d.mts +1 -1
- package/resources/onchain/pools/megafilter.d.mts.map +1 -1
- package/resources/onchain/pools/megafilter.d.ts +1 -1
- package/resources/onchain/pools/megafilter.d.ts.map +1 -1
- package/resources/public-treasury.d.mts +137 -0
- package/resources/public-treasury.d.mts.map +1 -0
- package/resources/public-treasury.d.ts +137 -0
- package/resources/public-treasury.d.ts.map +1 -0
- package/resources/public-treasury.js +40 -0
- package/resources/public-treasury.js.map +1 -0
- package/resources/public-treasury.mjs +36 -0
- package/resources/public-treasury.mjs.map +1 -0
- package/resources/simple/price.d.mts +2 -2
- package/resources/simple/price.d.ts +2 -2
- package/src/client.ts +24 -5
- package/src/resources/coins/circulating-supply-chart.ts +7 -5
- package/src/resources/coins/contract/market-chart.ts +13 -5
- package/src/resources/coins/history.ts +2 -2
- package/src/resources/coins/market-chart.ts +7 -5
- package/src/resources/coins/markets.ts +1 -1
- package/src/resources/coins/ohlc.ts +12 -5
- package/src/resources/coins/top-gainers-losers.ts +117 -5
- package/src/resources/coins/total-supply-chart.ts +8 -6
- package/src/resources/derivatives/exchanges.ts +2 -2
- package/src/resources/entities.ts +73 -0
- package/src/resources/exchanges/exchanges.ts +3 -3
- package/src/resources/exchanges/tickers.ts +9 -2
- package/src/resources/exchanges/volume-chart.ts +2 -2
- package/src/resources/index.ts +7 -1
- package/src/resources/onchain/networks/pools/info.ts +92 -54
- package/src/resources/onchain/networks/pools/multi.ts +61 -0
- package/src/resources/onchain/networks/pools/ohlcv.ts +2 -2
- package/src/resources/onchain/networks/pools/pools.ts +61 -0
- package/src/resources/onchain/networks/tokens/info.ts +1 -1
- package/src/resources/onchain/networks/tokens/multi.ts +211 -0
- package/src/resources/onchain/networks/tokens/ohlcv.ts +2 -2
- package/src/resources/onchain/networks/tokens/tokens.ts +25 -0
- package/src/resources/onchain/pools/megafilter.ts +7 -0
- package/src/resources/public-treasury.ts +178 -0
- package/src/resources/simple/price.ts +2 -2
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
- package/resources/companies/companies.d.mts +0 -10
- package/resources/companies/companies.d.mts.map +0 -1
- package/resources/companies/companies.d.ts +0 -10
- package/resources/companies/companies.d.ts.map +0 -1
- package/resources/companies/companies.js +0 -17
- package/resources/companies/companies.js.map +0 -1
- package/resources/companies/companies.mjs +0 -12
- package/resources/companies/companies.mjs.map +0 -1
- package/resources/companies/index.d.mts +0 -3
- package/resources/companies/index.d.mts.map +0 -1
- package/resources/companies/index.d.ts +0 -3
- package/resources/companies/index.d.ts.map +0 -1
- package/resources/companies/index.js +0 -9
- package/resources/companies/index.js.map +0 -1
- package/resources/companies/index.mjs +0 -4
- package/resources/companies/index.mjs.map +0 -1
- package/resources/companies/public-treasury.d.mts +0 -69
- package/resources/companies/public-treasury.d.mts.map +0 -1
- package/resources/companies/public-treasury.d.ts +0 -69
- package/resources/companies/public-treasury.d.ts.map +0 -1
- package/resources/companies/public-treasury.js +0 -25
- package/resources/companies/public-treasury.js.map +0 -1
- package/resources/companies/public-treasury.mjs +0 -21
- package/resources/companies/public-treasury.mjs.map +0 -1
- package/resources/companies.d.mts +0 -2
- package/resources/companies.d.mts.map +0 -1
- package/resources/companies.d.ts +0 -2
- package/resources/companies.d.ts.map +0 -1
- package/resources/companies.js +0 -6
- package/resources/companies.js.map +0 -1
- package/resources/companies.mjs +0 -3
- package/resources/companies.mjs.map +0 -1
- package/src/resources/companies/companies.ts +0 -18
- package/src/resources/companies/index.ts +0 -4
- package/src/resources/companies/public-treasury.ts +0 -89
- package/src/resources/companies.ts +0 -3
|
@@ -30,7 +30,12 @@ export class Ohlc extends APIResource {
|
|
|
30
30
|
* ```ts
|
|
31
31
|
* const response = await client.coins.ohlc.getRange(
|
|
32
32
|
* 'bitcoin',
|
|
33
|
-
* {
|
|
33
|
+
* {
|
|
34
|
+
* from: 'from',
|
|
35
|
+
* interval: 'daily',
|
|
36
|
+
* to: 'to',
|
|
37
|
+
* vs_currency: 'usd',
|
|
38
|
+
* },
|
|
34
39
|
* );
|
|
35
40
|
* ```
|
|
36
41
|
*/
|
|
@@ -92,9 +97,10 @@ export interface OhlcGetParams {
|
|
|
92
97
|
|
|
93
98
|
export interface OhlcGetRangeParams {
|
|
94
99
|
/**
|
|
95
|
-
* starting date in UNIX
|
|
100
|
+
* starting date in ISO date string (`YYYY-MM-DD` or `YYYY-MM-DDTHH:MM`) or UNIX
|
|
101
|
+
* timestamp. **use ISO date string for best compatibility**
|
|
96
102
|
*/
|
|
97
|
-
from:
|
|
103
|
+
from: string;
|
|
98
104
|
|
|
99
105
|
/**
|
|
100
106
|
* data interval
|
|
@@ -102,9 +108,10 @@ export interface OhlcGetRangeParams {
|
|
|
102
108
|
interval: 'daily' | 'hourly';
|
|
103
109
|
|
|
104
110
|
/**
|
|
105
|
-
* ending date in UNIX
|
|
111
|
+
* ending date in ISO date string (`YYYY-MM-DD` or `YYYY-MM-DDTHH:MM`) or UNIX
|
|
112
|
+
* timestamp. **use ISO date string for best compatibility**
|
|
106
113
|
*/
|
|
107
|
-
to:
|
|
114
|
+
to: string;
|
|
108
115
|
|
|
109
116
|
/**
|
|
110
117
|
* target currency of price data \*refers to
|
|
@@ -11,7 +11,7 @@ export class TopGainersLosers extends APIResource {
|
|
|
11
11
|
*
|
|
12
12
|
* @example
|
|
13
13
|
* ```ts
|
|
14
|
-
* const
|
|
14
|
+
* const topGainersLoser =
|
|
15
15
|
* await client.coins.topGainersLosers.get({
|
|
16
16
|
* vs_currency: 'usd',
|
|
17
17
|
* });
|
|
@@ -22,10 +22,86 @@ export class TopGainersLosers extends APIResource {
|
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
export
|
|
25
|
+
export interface TopGainersLoserGetResponse {
|
|
26
|
+
top_gainers?: Array<TopGainersLoserGetResponse.TopGainer>;
|
|
27
|
+
|
|
28
|
+
top_losers?: Array<TopGainersLoserGetResponse.TopLoser>;
|
|
29
|
+
}
|
|
26
30
|
|
|
27
31
|
export namespace TopGainersLoserGetResponse {
|
|
28
|
-
export interface
|
|
32
|
+
export interface TopGainer {
|
|
33
|
+
/**
|
|
34
|
+
* coin ID
|
|
35
|
+
*/
|
|
36
|
+
id?: string;
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* coin image url
|
|
40
|
+
*/
|
|
41
|
+
image?: string;
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* coin rank by market cap
|
|
45
|
+
*/
|
|
46
|
+
market_cap_rank?: number;
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* coin name
|
|
50
|
+
*/
|
|
51
|
+
name?: string;
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* coin symbol
|
|
55
|
+
*/
|
|
56
|
+
symbol?: string;
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* coin price in USD
|
|
60
|
+
*/
|
|
61
|
+
usd?: number;
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* coin 14 day change percentage in USD
|
|
65
|
+
*/
|
|
66
|
+
usd_14d_change?: number | null;
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* coin 1hr change percentage in USD
|
|
70
|
+
*/
|
|
71
|
+
usd_1h_change?: number | null;
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* coin 1 year change percentage in USD
|
|
75
|
+
*/
|
|
76
|
+
usd_1y_change?: number | null;
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* coin 200 day change percentage in USD
|
|
80
|
+
*/
|
|
81
|
+
usd_200d_change?: number | null;
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* coin 24hr change percentage in USD
|
|
85
|
+
*/
|
|
86
|
+
usd_24h_change?: number | null;
|
|
87
|
+
|
|
88
|
+
/**
|
|
89
|
+
* coin 24hr volume in USD
|
|
90
|
+
*/
|
|
91
|
+
usd_24h_vol?: number;
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* coin 30 day change percentage in USD
|
|
95
|
+
*/
|
|
96
|
+
usd_30d_change?: number | null;
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* coin 7 day change percentage in USD
|
|
100
|
+
*/
|
|
101
|
+
usd_7d_change?: number | null;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
export interface TopLoser {
|
|
29
105
|
/**
|
|
30
106
|
* coin ID
|
|
31
107
|
*/
|
|
@@ -57,14 +133,44 @@ export namespace TopGainersLoserGetResponse {
|
|
|
57
133
|
usd?: number;
|
|
58
134
|
|
|
59
135
|
/**
|
|
60
|
-
* coin
|
|
136
|
+
* coin 14 day change percentage in USD
|
|
137
|
+
*/
|
|
138
|
+
usd_14d_change?: number | null;
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* coin 1hr change percentage in USD
|
|
142
|
+
*/
|
|
143
|
+
usd_1h_change?: number | null;
|
|
144
|
+
|
|
145
|
+
/**
|
|
146
|
+
* coin 1 year change percentage in USD
|
|
147
|
+
*/
|
|
148
|
+
usd_1y_change?: number | null;
|
|
149
|
+
|
|
150
|
+
/**
|
|
151
|
+
* coin 200 day change percentage in USD
|
|
152
|
+
*/
|
|
153
|
+
usd_200d_change?: number | null;
|
|
154
|
+
|
|
155
|
+
/**
|
|
156
|
+
* coin 24hr change percentage in USD
|
|
61
157
|
*/
|
|
62
|
-
|
|
158
|
+
usd_24h_change?: number | null;
|
|
63
159
|
|
|
64
160
|
/**
|
|
65
161
|
* coin 24hr volume in USD
|
|
66
162
|
*/
|
|
67
163
|
usd_24h_vol?: number;
|
|
164
|
+
|
|
165
|
+
/**
|
|
166
|
+
* coin 30 day change percentage in USD
|
|
167
|
+
*/
|
|
168
|
+
usd_30d_change?: number | null;
|
|
169
|
+
|
|
170
|
+
/**
|
|
171
|
+
* coin 7 day change percentage in USD
|
|
172
|
+
*/
|
|
173
|
+
usd_7d_change?: number | null;
|
|
68
174
|
}
|
|
69
175
|
}
|
|
70
176
|
|
|
@@ -80,6 +186,12 @@ export interface TopGainersLoserGetParams {
|
|
|
80
186
|
*/
|
|
81
187
|
duration?: '1h' | '24h' | '7d' | '14d' | '30d' | '60d' | '1y';
|
|
82
188
|
|
|
189
|
+
/**
|
|
190
|
+
* include price change percentage timeframe, comma-separated if query more than 1
|
|
191
|
+
* price change percentage timeframe Valid values: 1h, 24h, 7d, 14d, 30d, 200d, 1y
|
|
192
|
+
*/
|
|
193
|
+
price_change_percentage?: string;
|
|
194
|
+
|
|
83
195
|
/**
|
|
84
196
|
* filter result by market cap ranking (top 300 to 1000) or all coins (including
|
|
85
197
|
* coins that do not have market cap) Default value: `1000`
|
|
@@ -34,8 +34,8 @@ export class TotalSupplyChart extends APIResource {
|
|
|
34
34
|
* ```ts
|
|
35
35
|
* const response =
|
|
36
36
|
* await client.coins.totalSupplyChart.getRange('bitcoin', {
|
|
37
|
-
* from:
|
|
38
|
-
* to:
|
|
37
|
+
* from: 'from',
|
|
38
|
+
* to: 'to',
|
|
39
39
|
* });
|
|
40
40
|
* ```
|
|
41
41
|
*/
|
|
@@ -70,14 +70,16 @@ export interface TotalSupplyChartGetParams {
|
|
|
70
70
|
|
|
71
71
|
export interface TotalSupplyChartGetRangeParams {
|
|
72
72
|
/**
|
|
73
|
-
* starting date in UNIX
|
|
73
|
+
* starting date in ISO date string (`YYYY-MM-DD` or `YYYY-MM-DDTHH:MM`) or UNIX
|
|
74
|
+
* timestamp. **use ISO date string for best compatibility**
|
|
74
75
|
*/
|
|
75
|
-
from:
|
|
76
|
+
from: string;
|
|
76
77
|
|
|
77
78
|
/**
|
|
78
|
-
* ending date in UNIX
|
|
79
|
+
* ending date in ISO date string (`YYYY-MM-DD` or `YYYY-MM-DDTHH:MM`) or UNIX
|
|
80
|
+
* timestamp. **use ISO date string for best compatibility**
|
|
79
81
|
*/
|
|
80
|
-
to:
|
|
82
|
+
to: string;
|
|
81
83
|
}
|
|
82
84
|
|
|
83
85
|
export declare namespace TotalSupplyChart {
|
|
@@ -23,8 +23,8 @@ export class Exchanges extends APIResource {
|
|
|
23
23
|
}
|
|
24
24
|
|
|
25
25
|
/**
|
|
26
|
-
* This endpoint allows you to **query the derivatives exchange
|
|
27
|
-
* name, open interest, ...) based on the exchanges
|
|
26
|
+
* This endpoint allows you to **query the derivatives exchange's related data (ID,
|
|
27
|
+
* name, open interest, ...) based on the exchanges' ID**
|
|
28
28
|
*
|
|
29
29
|
* @example
|
|
30
30
|
* ```ts
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../core/resource';
|
|
4
|
+
import { APIPromise } from '../core/api-promise';
|
|
5
|
+
import { RequestOptions } from '../internal/request-options';
|
|
6
|
+
|
|
7
|
+
export class Entities extends APIResource {
|
|
8
|
+
/**
|
|
9
|
+
* This endpoint allows you to **query all the supported entities on CoinGecko with
|
|
10
|
+
* entities ID, name, symbol, and country**
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```ts
|
|
14
|
+
* const response = await client.entities.getList();
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
getList(
|
|
18
|
+
query: EntityGetListParams | null | undefined = {},
|
|
19
|
+
options?: RequestOptions,
|
|
20
|
+
): APIPromise<EntityGetListResponse> {
|
|
21
|
+
return this._client.get('/entities/list', { query, ...options });
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export type EntityGetListResponse = Array<EntityGetListResponse.EntityGetListResponseItem>;
|
|
26
|
+
|
|
27
|
+
export namespace EntityGetListResponse {
|
|
28
|
+
export interface EntityGetListResponseItem {
|
|
29
|
+
/**
|
|
30
|
+
* entity ID
|
|
31
|
+
*/
|
|
32
|
+
id?: string;
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* country code
|
|
36
|
+
*/
|
|
37
|
+
country?: string;
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* entity name
|
|
41
|
+
*/
|
|
42
|
+
name?: string;
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* ticker symbol of public company
|
|
46
|
+
*/
|
|
47
|
+
symbol?: string;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export interface EntityGetListParams {
|
|
52
|
+
/**
|
|
53
|
+
* filter by entity type, default: false
|
|
54
|
+
*/
|
|
55
|
+
entity_type?: 'company' | 'government';
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* page through results, default: 1
|
|
59
|
+
*/
|
|
60
|
+
page?: number;
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* total results per page, default: 100 Valid values: 1...250
|
|
64
|
+
*/
|
|
65
|
+
per_page?: number;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export declare namespace Entities {
|
|
69
|
+
export {
|
|
70
|
+
type EntityGetListResponse as EntityGetListResponse,
|
|
71
|
+
type EntityGetListParams as EntityGetListParams,
|
|
72
|
+
};
|
|
73
|
+
}
|
|
@@ -20,7 +20,7 @@ export class Exchanges extends APIResource {
|
|
|
20
20
|
volumeChart: VolumeChartAPI.VolumeChart = new VolumeChartAPI.VolumeChart(this._client);
|
|
21
21
|
|
|
22
22
|
/**
|
|
23
|
-
* This endpoint allows you to **query all the supported exchanges with exchanges
|
|
23
|
+
* This endpoint allows you to **query all the supported exchanges with exchanges'
|
|
24
24
|
* data (ID, name, country, ...) that have active trading volumes on CoinGecko**
|
|
25
25
|
*
|
|
26
26
|
* @example
|
|
@@ -36,8 +36,8 @@ export class Exchanges extends APIResource {
|
|
|
36
36
|
}
|
|
37
37
|
|
|
38
38
|
/**
|
|
39
|
-
* This endpoint allows you to **query exchange
|
|
40
|
-
* country, ...), exchange volume in BTC and top 100 tickers based on exchange
|
|
39
|
+
* This endpoint allows you to **query exchange's data (name, year established,
|
|
40
|
+
* country, ...), exchange volume in BTC and top 100 tickers based on exchange's
|
|
41
41
|
* ID**
|
|
42
42
|
*
|
|
43
43
|
* @example
|
|
@@ -7,7 +7,7 @@ import { path } from '../../internal/utils/path';
|
|
|
7
7
|
|
|
8
8
|
export class Tickers extends APIResource {
|
|
9
9
|
/**
|
|
10
|
-
* This endpoint allows you to **query exchange's tickers based on exchange
|
|
10
|
+
* This endpoint allows you to **query exchange's tickers based on exchange's ID**
|
|
11
11
|
*
|
|
12
12
|
* @example
|
|
13
13
|
* ```ts
|
|
@@ -217,7 +217,14 @@ export interface TickerGetParams {
|
|
|
217
217
|
/**
|
|
218
218
|
* use this to sort the order of responses, default: trust_score_desc
|
|
219
219
|
*/
|
|
220
|
-
order?:
|
|
220
|
+
order?:
|
|
221
|
+
| 'market_cap_asc'
|
|
222
|
+
| 'market_cap_desc'
|
|
223
|
+
| 'trust_score_desc'
|
|
224
|
+
| 'trust_score_asc'
|
|
225
|
+
| 'volume_desc'
|
|
226
|
+
| 'volume_asc'
|
|
227
|
+
| 'base_target';
|
|
221
228
|
|
|
222
229
|
/**
|
|
223
230
|
* page through results
|
|
@@ -8,7 +8,7 @@ import { path } from '../../internal/utils/path';
|
|
|
8
8
|
export class VolumeChart extends APIResource {
|
|
9
9
|
/**
|
|
10
10
|
* This endpoint allows you to **query the historical volume chart data with time
|
|
11
|
-
* in UNIX and trading volume data in BTC based on exchange
|
|
11
|
+
* in UNIX and trading volume data in BTC based on exchange's ID**
|
|
12
12
|
*
|
|
13
13
|
* @example
|
|
14
14
|
* ```ts
|
|
@@ -24,7 +24,7 @@ export class VolumeChart extends APIResource {
|
|
|
24
24
|
|
|
25
25
|
/**
|
|
26
26
|
* This endpoint allows you to **query the historical volume chart data in BTC by
|
|
27
|
-
* specifying date range in UNIX based on exchange
|
|
27
|
+
* specifying date range in UNIX based on exchange's ID**
|
|
28
28
|
*
|
|
29
29
|
* @example
|
|
30
30
|
* ```ts
|
package/src/resources/index.ts
CHANGED
|
@@ -6,8 +6,8 @@ export {
|
|
|
6
6
|
type AssetPlatformGetParams,
|
|
7
7
|
} from './asset-platforms';
|
|
8
8
|
export { Coins, type CoinGetIDResponse, type CoinGetIDParams } from './coins/coins';
|
|
9
|
-
export { Companies } from './companies/companies';
|
|
10
9
|
export { Derivatives, type DerivativeGetResponse } from './derivatives/derivatives';
|
|
10
|
+
export { Entities, type EntityGetListResponse, type EntityGetListParams } from './entities';
|
|
11
11
|
export { ExchangeRates, type ExchangeRateGetResponse } from './exchange-rates';
|
|
12
12
|
export {
|
|
13
13
|
Exchanges,
|
|
@@ -30,6 +30,12 @@ export {
|
|
|
30
30
|
} from './nfts/nfts';
|
|
31
31
|
export { Onchain } from './onchain/onchain';
|
|
32
32
|
export { Ping, type PingGetResponse } from './ping';
|
|
33
|
+
export {
|
|
34
|
+
PublicTreasury,
|
|
35
|
+
type PublicTreasuryGetCoinIDResponse,
|
|
36
|
+
type PublicTreasuryGetEntityIDResponse,
|
|
37
|
+
type PublicTreasuryGetCoinIDParams,
|
|
38
|
+
} from './public-treasury';
|
|
33
39
|
export { Search, type SearchGetResponse, type SearchGetParams } from './search/search';
|
|
34
40
|
export { Simple } from './simple/simple';
|
|
35
41
|
export { TokenLists, type TokenListGetAllJsonResponse } from './token-lists';
|
|
@@ -20,114 +20,152 @@ export class Info extends APIResource {
|
|
|
20
20
|
* ```
|
|
21
21
|
*/
|
|
22
22
|
get(poolAddress: string, params: InfoGetParams, options?: RequestOptions): APIPromise<InfoGetResponse> {
|
|
23
|
-
const { network } = params;
|
|
24
|
-
return this._client.get(path`/onchain/networks/${network}/pools/${poolAddress}/info`,
|
|
23
|
+
const { network, ...query } = params;
|
|
24
|
+
return this._client.get(path`/onchain/networks/${network}/pools/${poolAddress}/info`, {
|
|
25
|
+
query,
|
|
26
|
+
...options,
|
|
27
|
+
});
|
|
25
28
|
}
|
|
26
29
|
}
|
|
27
30
|
|
|
28
31
|
export interface InfoGetResponse {
|
|
29
|
-
data?: InfoGetResponse.Data
|
|
32
|
+
data?: Array<InfoGetResponse.Data>;
|
|
33
|
+
|
|
34
|
+
included?: Array<InfoGetResponse.Included>;
|
|
30
35
|
}
|
|
31
36
|
|
|
32
37
|
export namespace InfoGetResponse {
|
|
33
38
|
export interface Data {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
attributes?: Data.Attributes;
|
|
37
|
-
|
|
38
|
-
type?: string;
|
|
39
|
+
data?: Data.Data;
|
|
39
40
|
}
|
|
40
41
|
|
|
41
42
|
export namespace Data {
|
|
42
|
-
export interface
|
|
43
|
-
|
|
43
|
+
export interface Data {
|
|
44
|
+
id?: string;
|
|
45
|
+
|
|
46
|
+
attributes?: Data.Attributes;
|
|
44
47
|
|
|
45
|
-
|
|
48
|
+
type?: string;
|
|
49
|
+
}
|
|
46
50
|
|
|
47
|
-
|
|
51
|
+
export namespace Data {
|
|
52
|
+
export interface Attributes {
|
|
53
|
+
address?: string;
|
|
48
54
|
|
|
49
|
-
|
|
55
|
+
categories?: Array<string>;
|
|
50
56
|
|
|
51
|
-
|
|
57
|
+
coingecko_coin_id?: string;
|
|
52
58
|
|
|
53
|
-
|
|
59
|
+
description?: string;
|
|
54
60
|
|
|
55
|
-
|
|
61
|
+
discord_url?: string;
|
|
56
62
|
|
|
57
|
-
|
|
63
|
+
freeze_authority?: string;
|
|
58
64
|
|
|
59
|
-
|
|
65
|
+
gt_categories_id?: Array<string>;
|
|
60
66
|
|
|
61
|
-
|
|
67
|
+
gt_score?: number;
|
|
62
68
|
|
|
63
|
-
|
|
69
|
+
gt_score_details?: Attributes.GtScoreDetails;
|
|
64
70
|
|
|
65
|
-
|
|
71
|
+
holders?: Attributes.Holders;
|
|
66
72
|
|
|
67
|
-
|
|
73
|
+
image?: Attributes.Image;
|
|
68
74
|
|
|
69
|
-
|
|
75
|
+
image_url?: string;
|
|
70
76
|
|
|
71
|
-
|
|
77
|
+
is_honeypot?: boolean | string;
|
|
72
78
|
|
|
73
|
-
|
|
79
|
+
mint_authority?: string;
|
|
74
80
|
|
|
75
|
-
|
|
81
|
+
name?: string;
|
|
76
82
|
|
|
77
|
-
|
|
83
|
+
symbol?: string;
|
|
78
84
|
|
|
79
|
-
|
|
80
|
-
}
|
|
85
|
+
telegram_handle?: string;
|
|
81
86
|
|
|
82
|
-
|
|
83
|
-
export interface GtScoreDetails {
|
|
84
|
-
creation?: number;
|
|
87
|
+
twitter_handle?: string;
|
|
85
88
|
|
|
86
|
-
|
|
89
|
+
websites?: Array<string>;
|
|
90
|
+
}
|
|
87
91
|
|
|
88
|
-
|
|
92
|
+
export namespace Attributes {
|
|
93
|
+
export interface GtScoreDetails {
|
|
94
|
+
creation?: number;
|
|
89
95
|
|
|
90
|
-
|
|
96
|
+
holders?: number;
|
|
91
97
|
|
|
92
|
-
|
|
93
|
-
}
|
|
98
|
+
info?: number;
|
|
94
99
|
|
|
95
|
-
|
|
96
|
-
count?: number;
|
|
100
|
+
pool?: number;
|
|
97
101
|
|
|
98
|
-
|
|
102
|
+
transaction?: number;
|
|
103
|
+
}
|
|
99
104
|
|
|
100
|
-
|
|
101
|
-
|
|
105
|
+
export interface Holders {
|
|
106
|
+
count?: number;
|
|
102
107
|
|
|
103
|
-
|
|
104
|
-
export interface DistributionPercentage {
|
|
105
|
-
'11_30'?: number;
|
|
108
|
+
distribution_percentage?: Holders.DistributionPercentage;
|
|
106
109
|
|
|
107
|
-
|
|
110
|
+
last_updated?: string;
|
|
111
|
+
}
|
|
108
112
|
|
|
109
|
-
|
|
113
|
+
export namespace Holders {
|
|
114
|
+
export interface DistributionPercentage {
|
|
115
|
+
'11_30'?: number;
|
|
110
116
|
|
|
111
|
-
|
|
117
|
+
'31_50'?: number;
|
|
118
|
+
|
|
119
|
+
rest?: number;
|
|
120
|
+
|
|
121
|
+
top_10?: number;
|
|
122
|
+
}
|
|
112
123
|
}
|
|
113
|
-
}
|
|
114
124
|
|
|
115
|
-
|
|
116
|
-
|
|
125
|
+
export interface Image {
|
|
126
|
+
large?: string;
|
|
117
127
|
|
|
118
|
-
|
|
128
|
+
small?: string;
|
|
119
129
|
|
|
120
|
-
|
|
130
|
+
thumb?: string;
|
|
131
|
+
}
|
|
121
132
|
}
|
|
122
133
|
}
|
|
123
134
|
}
|
|
135
|
+
|
|
136
|
+
export interface Included {
|
|
137
|
+
id?: string;
|
|
138
|
+
|
|
139
|
+
attributes?: Included.Attributes;
|
|
140
|
+
|
|
141
|
+
type?: string;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
export namespace Included {
|
|
145
|
+
export interface Attributes {
|
|
146
|
+
base_token_address?: string;
|
|
147
|
+
|
|
148
|
+
community_sus_report?: number;
|
|
149
|
+
|
|
150
|
+
quote_token_address?: string;
|
|
151
|
+
|
|
152
|
+
sentiment_vote_negative_percentage?: number;
|
|
153
|
+
|
|
154
|
+
sentiment_vote_positive_percentage?: number;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
124
157
|
}
|
|
125
158
|
|
|
126
159
|
export interface InfoGetParams {
|
|
127
160
|
/**
|
|
128
|
-
* network ID \*refers to [/networks](/reference/networks-list)
|
|
161
|
+
* Path param: network ID \*refers to [/networks](/reference/networks-list)
|
|
129
162
|
*/
|
|
130
163
|
network: string;
|
|
164
|
+
|
|
165
|
+
/**
|
|
166
|
+
* Query param: attributes to include
|
|
167
|
+
*/
|
|
168
|
+
include?: 'pool';
|
|
131
169
|
}
|
|
132
170
|
|
|
133
171
|
export declare namespace Info {
|