Skip to content

Commit 3622e01

Browse files
kiln-botEllzer
andcommitted
Update OpenAPI schema (#211)
* Update OpenAPI schema * bump version --------- Co-authored-by: Kiln Bot <[email protected]> Co-authored-by: Elliott Denis <[email protected]>
1 parent 6caf9ac commit 3622e01

File tree

2 files changed

+202
-27
lines changed

2 files changed

+202
-27
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@kilnfi/sdk",
3-
"version": "4.1.17",
3+
"version": "4.1.18",
44
"autor": "Kiln <[email protected]> (https://kiln.fi)",
55
"license": "BUSL-1.1",
66
"description": "JavaScript sdk for Kiln API",

src/openapi/schema.ts

Lines changed: 201 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -6924,6 +6924,26 @@ export interface paths {
69246924
patch?: never;
69256925
trace?: never;
69266926
};
6927+
"/ton/operations": {
6928+
parameters: {
6929+
query?: never;
6930+
header?: never;
6931+
path?: never;
6932+
cookie?: never;
6933+
};
6934+
/**
6935+
* Operations
6936+
* @description Get the operations of TON stakes
6937+
*/
6938+
get: operations["getTonOperations"];
6939+
put?: never;
6940+
post?: never;
6941+
delete?: never;
6942+
options?: never;
6943+
head?: never;
6944+
patch?: never;
6945+
trace?: never;
6946+
};
69276947
"/ton/network-stats": {
69286948
parameters: {
69296949
query?: never;
@@ -35834,6 +35854,100 @@ export interface components {
3583435854
*/
3583535855
address: string;
3583635856
};
35857+
TONOperation: {
35858+
/**
35859+
* @description Operation type
35860+
* @example stake
35861+
*/
35862+
type: string;
35863+
/**
35864+
* @description Operation data
35865+
* @example {
35866+
* "Text": "d"
35867+
* }
35868+
*/
35869+
data?: Record<string, never>;
35870+
/**
35871+
* @description Operation value
35872+
* @example 1000000000000000
35873+
*/
35874+
value: string;
35875+
/**
35876+
* @description Source address
35877+
* @example UQAfjn5-4M5H7q_2z4rCjAIGDslZoT0VsZNWaQ9BIaR4w0V9
35878+
*/
35879+
source: string;
35880+
/**
35881+
* @description Destination address
35882+
* @example Ef8xihYQ_8JBVBmystDCnNcAsy5yH_NzpFi2eYcXNaSzIdgw
35883+
*/
35884+
destination: string;
35885+
/**
35886+
* @description Pool address
35887+
* @example Ef8xihYQ_8JBVBmystDCnNcAsy5yH_NzpFi2eYcXNaSzIdgw
35888+
*/
35889+
pool: string;
35890+
/**
35891+
* @description Operation direction
35892+
* @example out
35893+
*/
35894+
direction: string;
35895+
/**
35896+
* @description Forward fees
35897+
* @example 1000000000000000
35898+
*/
35899+
fwd_fees: string;
35900+
/**
35901+
* @description IHR fees
35902+
* @example 1000000000000000
35903+
*/
35904+
ihr_fees: string;
35905+
/**
35906+
* @description Operation hash
35907+
* @example 1000000000000000
35908+
*/
35909+
hash: string;
35910+
/**
35911+
* @description Transaction hash
35912+
* @example 1000000000000000
35913+
*/
35914+
tx_hash: string;
35915+
/**
35916+
* @description Transaction status
35917+
* @example success
35918+
*/
35919+
tx_status: string;
35920+
/**
35921+
* @description Transaction timestamp
35922+
* @example 2023-01-15T01:13:59Z
35923+
*/
35924+
tx_timestamp: string;
35925+
/**
35926+
* @description Transaction block
35927+
* @example 1000000000000000
35928+
*/
35929+
tx_block: string;
35930+
/**
35931+
* @description Transaction total fees
35932+
* @example 1000000000000000
35933+
*/
35934+
tx_total_fees: string;
35935+
/**
35936+
* @description Transaction storage fees
35937+
* @example 100000000
35938+
*/
35939+
tx_storage_fees: string;
35940+
/**
35941+
* @description Transaction gas fees
35942+
* @example 1000000000000000
35943+
*/
35944+
tx_gas_fees: string;
35945+
/**
35946+
* @description Transaction forward fees
35947+
* @example 1000000000000000
35948+
*/
35949+
tx_fwd_fees: string;
35950+
};
3583735951
NOBLEGetBalancePayload: {
3583835952
/**
3583935953
* @description Wallet address
@@ -35980,7 +36094,7 @@ export interface components {
3598036094
* "TQzd66b9EFVHJfZK5AmiVhBjtJvXGeSPPZ": 1
3598136095
* }
3598236096
*/
35983-
votes?: {
36097+
votes: {
3598436098
[key: string]: number;
3598536099
};
3598636100
};
@@ -36051,24 +36165,24 @@ export interface components {
3605136165
wallet: string;
3605236166
/**
3605336167
* @description Available balance in sun
36054-
* @example 4000000
36168+
* @example 32647466
3605536169
*/
36056-
available_balance: number;
36170+
available_balance: string;
3605736171
/**
36058-
* @description Available balance in sun
36059-
* @example 3000000
36172+
* @description Available rewards in sun
36173+
* @example 13749
3606036174
*/
36061-
claimable_rewards: number;
36175+
claimable_rewards: string;
3606236176
/**
3606336177
* @description Frozen TRX for bandwidth in sun
3606436178
* @example 1000000
3606536179
*/
36066-
frozen_bandwidth: number;
36180+
frozen_bandwidth: string;
3606736181
/**
3606836182
* @description Frozen TRX for energy in sun
3606936183
* @example 1000000
3607036184
*/
36071-
frozen_energy: number;
36185+
frozen_energy: string;
3607236186
/**
3607336187
* Format: date-time
3607436188
* @description Last withdraw timestamp
@@ -36087,7 +36201,7 @@ export interface components {
3608736201
* @description Amount of TRX unstaking
3608836202
* @example 1000000
3608936203
*/
36090-
amount: number;
36204+
amount: string;
3609136205
/**
3609236206
* Format: date-time
3609336207
* @description end of the waiting period
@@ -36106,13 +36220,13 @@ export interface components {
3610636220
* @description Vote count
3610736221
* @example 4
3610836222
*/
36109-
count: number;
36223+
count: string;
3611036224
}[];
3611136225
/**
3611236226
* @description Withdrawable balance in sun
3611336227
* @example 2000000
3611436228
*/
36115-
withdrawable_balance: number;
36229+
withdrawable_balance: string;
3611636230
/**
3611736231
* Format: date-time
3611836232
* @description Last updated timestamp
@@ -36122,19 +36236,14 @@ export interface components {
3612236236
};
3612336237
TRXReward: {
3612436238
/**
36125-
* @description Wallet address
36126-
* @example TAERHY5gyzDRmAaeqqa6C4Fuyc9HLnnHx7
36127-
*/
36128-
wallet: string;
36129-
/**
36130-
* Format: date-time
36131-
* @description Date of the reward
36132-
* @example 2025-03-21 18:10:27.816999375 +0000 UTC
36239+
* Format: date
36240+
* @description Day for this reward entry
36241+
* @example 2025-03-21
3613336242
*/
3613436243
date: string;
3613536244
/**
36136-
* @description Rewards in TRX
36137-
* @example 0.0024145
36245+
* @description Accumulated rewards in sun during the day
36246+
* @example 1000000
3613836247
*/
3613936248
rewards: string;
3614036249
/**
@@ -36143,15 +36252,25 @@ export interface components {
3614336252
*/
3614436253
net_apy: number;
3614536254
/**
36146-
* @description Total wallet votes
36255+
* @description Stake balance in sun used to vote for Kiln at the end of day
3614736256
* @example 4
3614836257
*/
36149-
wallet_votes: number;
36258+
effective_balance: string;
3615036259
/**
36151-
* @description Total validator votes
36152-
* @example 100
36260+
* @description Number of votes for kiln validator at the end of day
36261+
* @example validator_votes
3615336262
*/
36154-
validator_votes: number;
36263+
validator_votes: string;
36264+
/**
36265+
* @description Estimated value of the effective balance of that day in USD. The exchange rate is the rate at the end of the day provided by CoinGeckko.
36266+
* @example 4407596.22
36267+
*/
36268+
effective_balance_usd?: number;
36269+
/**
36270+
* @description Estimated value of rewards generated in USD. The exchange rate is the rate at the end of the day provided by CoinGeckko.
36271+
* @example 0.22
36272+
*/
36273+
rewards_usd?: number;
3615536274
};
3615636275
};
3615736276
responses: never;
@@ -54432,6 +54551,60 @@ export interface operations {
5443254551
};
5443354552
};
5443454553
};
54554+
getTonOperations: {
54555+
parameters: {
54556+
query?: {
54557+
/** @description Comma-separated list of nominator addresses */
54558+
nominators?: components["parameters"]["TONNominatorsParam"];
54559+
/** @description Comma-separated list of pool addresses */
54560+
pools?: components["parameters"]["TONPoolsParam"];
54561+
/** @description Comma-separated list of Kiln accounts identifiers */
54562+
accounts?: components["parameters"]["AccountsParam"];
54563+
/** @description Get data from this date (YYYY-MM-DD) */
54564+
start_date?: components["parameters"]["StartDateParam"];
54565+
/** @description Get data to this date (YYYY-MM-DD) */
54566+
end_date?: components["parameters"]["EndDateParam"];
54567+
};
54568+
header?: never;
54569+
path?: never;
54570+
cookie?: never;
54571+
};
54572+
requestBody?: never;
54573+
responses: {
54574+
/** @description Successful operation */
54575+
200: {
54576+
headers: {
54577+
[name: string]: unknown;
54578+
};
54579+
content: {
54580+
"application/json; charset=utf-8": {
54581+
data: components["schemas"]["TONOperation"][];
54582+
};
54583+
};
54584+
};
54585+
/** @description Invalid parameters */
54586+
400: {
54587+
headers: {
54588+
[name: string]: unknown;
54589+
};
54590+
content?: never;
54591+
};
54592+
/** @description Unauthorized */
54593+
401: {
54594+
headers: {
54595+
[name: string]: unknown;
54596+
};
54597+
content?: never;
54598+
};
54599+
/** @description Internal server error */
54600+
500: {
54601+
headers: {
54602+
[name: string]: unknown;
54603+
};
54604+
content?: never;
54605+
};
54606+
};
54607+
};
5443554608
getTonNetworkStats: {
5443654609
parameters: {
5443754610
query?: never;
@@ -55723,6 +55896,8 @@ export interface operations {
5572355896
start_date?: components["parameters"]["StartDateParam"];
5572455897
/** @description Get data to this date (YYYY-MM-DD) */
5572555898
end_date?: components["parameters"]["EndDateParam"];
55899+
/** @description Include rewards and balance in USD in response. <br/> If a `format` parameter exists it will only work with `format=daily` */
55900+
include_usd?: components["parameters"]["IncludeUSDParam"];
5572655901
};
5572755902
header?: never;
5572855903
path?: never;

0 commit comments

Comments
 (0)