@gpuai/sdk 0.1.2 → 0.1.4
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/README.md +2 -2
- package/dist/esm/models/Instance.d.ts +6 -0
- package/dist/esm/models/Instance.js +2 -0
- package/dist/esm/models/ListDeposits200Response.d.ts +6 -0
- package/dist/esm/models/ListDeposits200Response.js +4 -0
- package/dist/models/Instance.d.ts +6 -0
- package/dist/models/Instance.js +2 -0
- package/dist/models/ListDeposits200Response.d.ts +6 -0
- package/dist/models/ListDeposits200Response.js +4 -0
- package/docs/Instance.md +2 -0
- package/docs/ListDeposits200Response.md +2 -0
- package/package.json +1 -1
- package/src/models/Instance.ts +8 -0
- package/src/models/ListDeposits200Response.ts +9 -0
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# @gpuai/sdk@0.1.
|
|
1
|
+
# @gpuai/sdk@0.1.4
|
|
2
2
|
|
|
3
3
|
A TypeScript SDK client for the api.gpu.ai API.
|
|
4
4
|
|
|
@@ -202,7 +202,7 @@ and is automatically generated by the
|
|
|
202
202
|
[OpenAPI Generator](https://openapi-generator.tech) project:
|
|
203
203
|
|
|
204
204
|
- API version: `1.0.0`
|
|
205
|
-
- Package version: `0.1.
|
|
205
|
+
- Package version: `0.1.4`
|
|
206
206
|
- Generator version: `7.24.0`
|
|
207
207
|
- Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
|
|
208
208
|
|
|
@@ -100,6 +100,12 @@ export interface Instance {
|
|
|
100
100
|
* @memberof Instance
|
|
101
101
|
*/
|
|
102
102
|
terminatedAt?: Date;
|
|
103
|
+
/**
|
|
104
|
+
* Last time the platform verified the SSH path to this instance end-to-end through the tunnel. Absent means the instance has not been probed yet (freshly launched, or no tunnel) — it does NOT mean unreachable. An instance whose status is still "running" while this timestamp stops advancing is one whose SSH has died even though the machine is up.
|
|
105
|
+
* @type {Date}
|
|
106
|
+
* @memberof Instance
|
|
107
|
+
*/
|
|
108
|
+
lastReachableAt?: Date;
|
|
103
109
|
}
|
|
104
110
|
/**
|
|
105
111
|
* @export
|
|
@@ -75,6 +75,7 @@ export function InstanceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
75
75
|
'createdAt': (new Date(json['created_at'])),
|
|
76
76
|
'readyAt': json['ready_at'] == null ? undefined : (new Date(json['ready_at'])),
|
|
77
77
|
'terminatedAt': json['terminated_at'] == null ? undefined : (new Date(json['terminated_at'])),
|
|
78
|
+
'lastReachableAt': json['last_reachable_at'] == null ? undefined : (new Date(json['last_reachable_at'])),
|
|
78
79
|
};
|
|
79
80
|
}
|
|
80
81
|
export function InstanceToJSON(json) {
|
|
@@ -99,5 +100,6 @@ export function InstanceToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
99
100
|
'created_at': value['createdAt'].toISOString(),
|
|
100
101
|
'ready_at': value['readyAt'] == null ? value['readyAt'] : value['readyAt'].toISOString(),
|
|
101
102
|
'terminated_at': value['terminatedAt'] == null ? value['terminatedAt'] : value['terminatedAt'].toISOString(),
|
|
103
|
+
'last_reachable_at': value['lastReachableAt'] == null ? value['lastReachableAt'] : value['lastReachableAt'].toISOString(),
|
|
102
104
|
};
|
|
103
105
|
}
|
|
@@ -22,6 +22,12 @@ export interface ListDeposits200Response {
|
|
|
22
22
|
* @memberof ListDeposits200Response
|
|
23
23
|
*/
|
|
24
24
|
deposits: Array<CryptoDeposit>;
|
|
25
|
+
/**
|
|
26
|
+
* The effective minimum deposit in USD cents (admin override, else the deployment's configured floor). Validate amounts against this live value rather than hardcoding the default.
|
|
27
|
+
* @type {number}
|
|
28
|
+
* @memberof ListDeposits200Response
|
|
29
|
+
*/
|
|
30
|
+
minDepositCents: number;
|
|
25
31
|
}
|
|
26
32
|
/**
|
|
27
33
|
* Check if a given object implements the ListDeposits200Response interface.
|
|
@@ -18,6 +18,8 @@ import { CryptoDepositFromJSON, CryptoDepositToJSON, } from './CryptoDeposit';
|
|
|
18
18
|
export function instanceOfListDeposits200Response(value) {
|
|
19
19
|
if (!('deposits' in value) || value['deposits'] === undefined)
|
|
20
20
|
return false;
|
|
21
|
+
if ((!('minDepositCents' in value) && !('min_deposit_cents' in value)) || (value['minDepositCents'] === undefined && value['min_deposit_cents'] === undefined))
|
|
22
|
+
return false;
|
|
21
23
|
return true;
|
|
22
24
|
}
|
|
23
25
|
export function ListDeposits200ResponseFromJSON(json) {
|
|
@@ -29,6 +31,7 @@ export function ListDeposits200ResponseFromJSONTyped(json, ignoreDiscriminator)
|
|
|
29
31
|
}
|
|
30
32
|
return {
|
|
31
33
|
'deposits': (json['deposits'].map(CryptoDepositFromJSON)),
|
|
34
|
+
'minDepositCents': json['min_deposit_cents'],
|
|
32
35
|
};
|
|
33
36
|
}
|
|
34
37
|
export function ListDeposits200ResponseToJSON(json) {
|
|
@@ -40,5 +43,6 @@ export function ListDeposits200ResponseToJSONTyped(value, ignoreDiscriminator =
|
|
|
40
43
|
}
|
|
41
44
|
return {
|
|
42
45
|
'deposits': (value['deposits'].map(CryptoDepositToJSON)),
|
|
46
|
+
'min_deposit_cents': value['minDepositCents'],
|
|
43
47
|
};
|
|
44
48
|
}
|
|
@@ -100,6 +100,12 @@ export interface Instance {
|
|
|
100
100
|
* @memberof Instance
|
|
101
101
|
*/
|
|
102
102
|
terminatedAt?: Date;
|
|
103
|
+
/**
|
|
104
|
+
* Last time the platform verified the SSH path to this instance end-to-end through the tunnel. Absent means the instance has not been probed yet (freshly launched, or no tunnel) — it does NOT mean unreachable. An instance whose status is still "running" while this timestamp stops advancing is one whose SSH has died even though the machine is up.
|
|
105
|
+
* @type {Date}
|
|
106
|
+
* @memberof Instance
|
|
107
|
+
*/
|
|
108
|
+
lastReachableAt?: Date;
|
|
103
109
|
}
|
|
104
110
|
/**
|
|
105
111
|
* @export
|
package/dist/models/Instance.js
CHANGED
|
@@ -83,6 +83,7 @@ function InstanceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
83
83
|
'createdAt': (new Date(json['created_at'])),
|
|
84
84
|
'readyAt': json['ready_at'] == null ? undefined : (new Date(json['ready_at'])),
|
|
85
85
|
'terminatedAt': json['terminated_at'] == null ? undefined : (new Date(json['terminated_at'])),
|
|
86
|
+
'lastReachableAt': json['last_reachable_at'] == null ? undefined : (new Date(json['last_reachable_at'])),
|
|
86
87
|
};
|
|
87
88
|
}
|
|
88
89
|
function InstanceToJSON(json) {
|
|
@@ -107,5 +108,6 @@ function InstanceToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
107
108
|
'created_at': value['createdAt'].toISOString(),
|
|
108
109
|
'ready_at': value['readyAt'] == null ? value['readyAt'] : value['readyAt'].toISOString(),
|
|
109
110
|
'terminated_at': value['terminatedAt'] == null ? value['terminatedAt'] : value['terminatedAt'].toISOString(),
|
|
111
|
+
'last_reachable_at': value['lastReachableAt'] == null ? value['lastReachableAt'] : value['lastReachableAt'].toISOString(),
|
|
110
112
|
};
|
|
111
113
|
}
|
|
@@ -22,6 +22,12 @@ export interface ListDeposits200Response {
|
|
|
22
22
|
* @memberof ListDeposits200Response
|
|
23
23
|
*/
|
|
24
24
|
deposits: Array<CryptoDeposit>;
|
|
25
|
+
/**
|
|
26
|
+
* The effective minimum deposit in USD cents (admin override, else the deployment's configured floor). Validate amounts against this live value rather than hardcoding the default.
|
|
27
|
+
* @type {number}
|
|
28
|
+
* @memberof ListDeposits200Response
|
|
29
|
+
*/
|
|
30
|
+
minDepositCents: number;
|
|
25
31
|
}
|
|
26
32
|
/**
|
|
27
33
|
* Check if a given object implements the ListDeposits200Response interface.
|
|
@@ -25,6 +25,8 @@ const CryptoDeposit_1 = require("./CryptoDeposit");
|
|
|
25
25
|
function instanceOfListDeposits200Response(value) {
|
|
26
26
|
if (!('deposits' in value) || value['deposits'] === undefined)
|
|
27
27
|
return false;
|
|
28
|
+
if ((!('minDepositCents' in value) && !('min_deposit_cents' in value)) || (value['minDepositCents'] === undefined && value['min_deposit_cents'] === undefined))
|
|
29
|
+
return false;
|
|
28
30
|
return true;
|
|
29
31
|
}
|
|
30
32
|
function ListDeposits200ResponseFromJSON(json) {
|
|
@@ -36,6 +38,7 @@ function ListDeposits200ResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
36
38
|
}
|
|
37
39
|
return {
|
|
38
40
|
'deposits': (json['deposits'].map(CryptoDeposit_1.CryptoDepositFromJSON)),
|
|
41
|
+
'minDepositCents': json['min_deposit_cents'],
|
|
39
42
|
};
|
|
40
43
|
}
|
|
41
44
|
function ListDeposits200ResponseToJSON(json) {
|
|
@@ -47,5 +50,6 @@ function ListDeposits200ResponseToJSONTyped(value, ignoreDiscriminator = false)
|
|
|
47
50
|
}
|
|
48
51
|
return {
|
|
49
52
|
'deposits': (value['deposits'].map(CryptoDeposit_1.CryptoDepositToJSON)),
|
|
53
|
+
'min_deposit_cents': value['minDepositCents'],
|
|
50
54
|
};
|
|
51
55
|
}
|
package/docs/Instance.md
CHANGED
|
@@ -20,6 +20,7 @@ Name | Type
|
|
|
20
20
|
`createdAt` | Date
|
|
21
21
|
`readyAt` | Date
|
|
22
22
|
`terminatedAt` | Date
|
|
23
|
+
`lastReachableAt` | Date
|
|
23
24
|
|
|
24
25
|
## Example
|
|
25
26
|
|
|
@@ -42,6 +43,7 @@ const example = {
|
|
|
42
43
|
"createdAt": null,
|
|
43
44
|
"readyAt": null,
|
|
44
45
|
"terminatedAt": null,
|
|
46
|
+
"lastReachableAt": null,
|
|
45
47
|
} satisfies Instance
|
|
46
48
|
|
|
47
49
|
console.log(example)
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
Name | Type
|
|
8
8
|
------------ | -------------
|
|
9
9
|
`deposits` | [Array<CryptoDeposit>](CryptoDeposit.md)
|
|
10
|
+
`minDepositCents` | number
|
|
10
11
|
|
|
11
12
|
## Example
|
|
12
13
|
|
|
@@ -16,6 +17,7 @@ import type { ListDeposits200Response } from '@gpuai/sdk'
|
|
|
16
17
|
// TODO: Update the object below with actual values
|
|
17
18
|
const example = {
|
|
18
19
|
"deposits": null,
|
|
20
|
+
"minDepositCents": 500,
|
|
19
21
|
} satisfies ListDeposits200Response
|
|
20
22
|
|
|
21
23
|
console.log(example)
|
package/package.json
CHANGED
package/src/models/Instance.ts
CHANGED
|
@@ -111,6 +111,12 @@ export interface Instance {
|
|
|
111
111
|
* @memberof Instance
|
|
112
112
|
*/
|
|
113
113
|
terminatedAt?: Date;
|
|
114
|
+
/**
|
|
115
|
+
* Last time the platform verified the SSH path to this instance end-to-end through the tunnel. Absent means the instance has not been probed yet (freshly launched, or no tunnel) — it does NOT mean unreachable. An instance whose status is still "running" while this timestamp stops advancing is one whose SSH has died even though the machine is up.
|
|
116
|
+
* @type {Date}
|
|
117
|
+
* @memberof Instance
|
|
118
|
+
*/
|
|
119
|
+
lastReachableAt?: Date;
|
|
114
120
|
}
|
|
115
121
|
|
|
116
122
|
|
|
@@ -177,6 +183,7 @@ export function InstanceFromJSONTyped(json: any, ignoreDiscriminator: boolean):
|
|
|
177
183
|
'createdAt': (new Date(json['created_at'])),
|
|
178
184
|
'readyAt': json['ready_at'] == null ? undefined : (new Date(json['ready_at'])),
|
|
179
185
|
'terminatedAt': json['terminated_at'] == null ? undefined : (new Date(json['terminated_at'])),
|
|
186
|
+
'lastReachableAt': json['last_reachable_at'] == null ? undefined : (new Date(json['last_reachable_at'])),
|
|
180
187
|
};
|
|
181
188
|
}
|
|
182
189
|
|
|
@@ -205,6 +212,7 @@ export function InstanceToJSONTyped(value?: Instance | null, ignoreDiscriminator
|
|
|
205
212
|
'created_at': value['createdAt'].toISOString(),
|
|
206
213
|
'ready_at': value['readyAt'] == null ? value['readyAt'] : value['readyAt'].toISOString(),
|
|
207
214
|
'terminated_at': value['terminatedAt'] == null ? value['terminatedAt'] : value['terminatedAt'].toISOString(),
|
|
215
|
+
'last_reachable_at': value['lastReachableAt'] == null ? value['lastReachableAt'] : value['lastReachableAt'].toISOString(),
|
|
208
216
|
};
|
|
209
217
|
}
|
|
210
218
|
|
|
@@ -33,6 +33,12 @@ export interface ListDeposits200Response {
|
|
|
33
33
|
* @memberof ListDeposits200Response
|
|
34
34
|
*/
|
|
35
35
|
deposits: Array<CryptoDeposit>;
|
|
36
|
+
/**
|
|
37
|
+
* The effective minimum deposit in USD cents (admin override, else the deployment's configured floor). Validate amounts against this live value rather than hardcoding the default.
|
|
38
|
+
* @type {number}
|
|
39
|
+
* @memberof ListDeposits200Response
|
|
40
|
+
*/
|
|
41
|
+
minDepositCents: number;
|
|
36
42
|
}
|
|
37
43
|
|
|
38
44
|
/**
|
|
@@ -40,6 +46,7 @@ export interface ListDeposits200Response {
|
|
|
40
46
|
*/
|
|
41
47
|
export function instanceOfListDeposits200Response(value: object): value is ListDeposits200Response {
|
|
42
48
|
if (!('deposits' in value) || value['deposits'] === undefined) return false;
|
|
49
|
+
if ((!('minDepositCents' in (value as Record<string, any>)) && !('min_deposit_cents' in (value as Record<string, any>))) || ((value as Record<string, any>)['minDepositCents'] === undefined && (value as Record<string, any>)['min_deposit_cents'] === undefined)) return false;
|
|
43
50
|
return true;
|
|
44
51
|
}
|
|
45
52
|
|
|
@@ -54,6 +61,7 @@ export function ListDeposits200ResponseFromJSONTyped(json: any, ignoreDiscrimina
|
|
|
54
61
|
return {
|
|
55
62
|
|
|
56
63
|
'deposits': ((json['deposits'] as Array<any>).map(CryptoDepositFromJSON)),
|
|
64
|
+
'minDepositCents': json['min_deposit_cents'],
|
|
57
65
|
};
|
|
58
66
|
}
|
|
59
67
|
|
|
@@ -69,6 +77,7 @@ export function ListDeposits200ResponseToJSONTyped(value?: ListDeposits200Respon
|
|
|
69
77
|
return {
|
|
70
78
|
|
|
71
79
|
'deposits': ((value['deposits'] as Array<any>).map(CryptoDepositToJSON)),
|
|
80
|
+
'min_deposit_cents': value['minDepositCents'],
|
|
72
81
|
};
|
|
73
82
|
}
|
|
74
83
|
|