@gpuai/sdk 0.3.0 → 0.3.1

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 CHANGED
@@ -1,4 +1,4 @@
1
- # @gpuai/sdk@0.3.0
1
+ # @gpuai/sdk@0.3.1
2
2
 
3
3
  A TypeScript SDK client for the api.gpu.ai API.
4
4
 
@@ -196,7 +196,7 @@ and is automatically generated by the
196
196
  [OpenAPI Generator](https://openapi-generator.tech) project:
197
197
 
198
198
  - API version: `1.0.0`
199
- - Package version: `0.3.0`
199
+ - Package version: `0.3.1`
200
200
  - Generator version: `7.24.0`
201
201
  - Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
202
202
 
@@ -29,7 +29,7 @@ export interface Instance {
29
29
  */
30
30
  name?: string;
31
31
  /**
32
- * Customer-facing lifecycle status. "allocating" = the GPU is still being acquired from the provider (slow-boot capacity such as baremetal can take ~15 min); "starting" = the node exists and is booting; "running" = ready to use.
32
+ * Customer-facing lifecycle status. "allocating" = the GPU is still being acquired from the provider (slow-boot capacity such as baremetal can take ~15 min); "starting" = the node exists and is booting; "running" = ready to use. "unreachable" = the platform's tunnel probe has confirmed the SSH path is down while the machine may still be up: the instance is NOT usable right now, billing for the confirmed-dead window is auto-credited back, and the instance either recovers to "running" on its own or is failed after a grace window. It is a degraded reading of a running instance, not a separate lifecycle state — see unreachable_since.
33
33
  * @type {InstanceStatusEnum}
34
34
  * @memberof Instance
35
35
  */
@@ -106,6 +106,12 @@ export interface Instance {
106
106
  * @memberof Instance
107
107
  */
108
108
  lastReachableAt?: Date;
109
+ /**
110
+ * Start of the confirmed tunnel outage the instance is currently in. Present exactly when status is "unreachable", absent otherwise. It is the timestamp the auto-credit for the dead window is computed from, so a ledger credit can be reconciled against it.
111
+ * @type {Date}
112
+ * @memberof Instance
113
+ */
114
+ unreachableSince?: Date;
109
115
  }
110
116
  /**
111
117
  * @export
@@ -117,6 +123,7 @@ export declare const InstanceStatusEnum: {
117
123
  readonly Stopping: "stopping";
118
124
  readonly Stopped: "stopped";
119
125
  readonly Terminated: "terminated";
126
+ readonly Unreachable: "unreachable";
120
127
  readonly Error: "error";
121
128
  };
122
129
  export type InstanceStatusEnum = typeof InstanceStatusEnum[keyof typeof InstanceStatusEnum];
@@ -22,6 +22,7 @@ export const InstanceStatusEnum = {
22
22
  Stopping: 'stopping',
23
23
  Stopped: 'stopped',
24
24
  Terminated: 'terminated',
25
+ Unreachable: 'unreachable',
25
26
  Error: 'error'
26
27
  };
27
28
  /**
@@ -76,6 +77,7 @@ export function InstanceFromJSONTyped(json, ignoreDiscriminator) {
76
77
  'readyAt': json['ready_at'] == null ? undefined : (new Date(json['ready_at'])),
77
78
  'terminatedAt': json['terminated_at'] == null ? undefined : (new Date(json['terminated_at'])),
78
79
  'lastReachableAt': json['last_reachable_at'] == null ? undefined : (new Date(json['last_reachable_at'])),
80
+ 'unreachableSince': json['unreachable_since'] == null ? undefined : (new Date(json['unreachable_since'])),
79
81
  };
80
82
  }
81
83
  export function InstanceToJSON(json) {
@@ -101,5 +103,6 @@ export function InstanceToJSONTyped(value, ignoreDiscriminator = false) {
101
103
  'ready_at': value['readyAt'] == null ? value['readyAt'] : value['readyAt'].toISOString(),
102
104
  'terminated_at': value['terminatedAt'] == null ? value['terminatedAt'] : value['terminatedAt'].toISOString(),
103
105
  'last_reachable_at': value['lastReachableAt'] == null ? value['lastReachableAt'] : value['lastReachableAt'].toISOString(),
106
+ 'unreachable_since': value['unreachableSince'] == null ? value['unreachableSince'] : value['unreachableSince'].toISOString(),
104
107
  };
105
108
  }
@@ -29,7 +29,7 @@ export interface Instance {
29
29
  */
30
30
  name?: string;
31
31
  /**
32
- * Customer-facing lifecycle status. "allocating" = the GPU is still being acquired from the provider (slow-boot capacity such as baremetal can take ~15 min); "starting" = the node exists and is booting; "running" = ready to use.
32
+ * Customer-facing lifecycle status. "allocating" = the GPU is still being acquired from the provider (slow-boot capacity such as baremetal can take ~15 min); "starting" = the node exists and is booting; "running" = ready to use. "unreachable" = the platform's tunnel probe has confirmed the SSH path is down while the machine may still be up: the instance is NOT usable right now, billing for the confirmed-dead window is auto-credited back, and the instance either recovers to "running" on its own or is failed after a grace window. It is a degraded reading of a running instance, not a separate lifecycle state — see unreachable_since.
33
33
  * @type {InstanceStatusEnum}
34
34
  * @memberof Instance
35
35
  */
@@ -106,6 +106,12 @@ export interface Instance {
106
106
  * @memberof Instance
107
107
  */
108
108
  lastReachableAt?: Date;
109
+ /**
110
+ * Start of the confirmed tunnel outage the instance is currently in. Present exactly when status is "unreachable", absent otherwise. It is the timestamp the auto-credit for the dead window is computed from, so a ledger credit can be reconciled against it.
111
+ * @type {Date}
112
+ * @memberof Instance
113
+ */
114
+ unreachableSince?: Date;
109
115
  }
110
116
  /**
111
117
  * @export
@@ -117,6 +123,7 @@ export declare const InstanceStatusEnum: {
117
123
  readonly Stopping: "stopping";
118
124
  readonly Stopped: "stopped";
119
125
  readonly Terminated: "terminated";
126
+ readonly Unreachable: "unreachable";
120
127
  readonly Error: "error";
121
128
  };
122
129
  export type InstanceStatusEnum = typeof InstanceStatusEnum[keyof typeof InstanceStatusEnum];
@@ -30,6 +30,7 @@ exports.InstanceStatusEnum = {
30
30
  Stopping: 'stopping',
31
31
  Stopped: 'stopped',
32
32
  Terminated: 'terminated',
33
+ Unreachable: 'unreachable',
33
34
  Error: 'error'
34
35
  };
35
36
  /**
@@ -84,6 +85,7 @@ function InstanceFromJSONTyped(json, ignoreDiscriminator) {
84
85
  'readyAt': json['ready_at'] == null ? undefined : (new Date(json['ready_at'])),
85
86
  'terminatedAt': json['terminated_at'] == null ? undefined : (new Date(json['terminated_at'])),
86
87
  'lastReachableAt': json['last_reachable_at'] == null ? undefined : (new Date(json['last_reachable_at'])),
88
+ 'unreachableSince': json['unreachable_since'] == null ? undefined : (new Date(json['unreachable_since'])),
87
89
  };
88
90
  }
89
91
  function InstanceToJSON(json) {
@@ -109,5 +111,6 @@ function InstanceToJSONTyped(value, ignoreDiscriminator = false) {
109
111
  'ready_at': value['readyAt'] == null ? value['readyAt'] : value['readyAt'].toISOString(),
110
112
  'terminated_at': value['terminatedAt'] == null ? value['terminatedAt'] : value['terminatedAt'].toISOString(),
111
113
  'last_reachable_at': value['lastReachableAt'] == null ? value['lastReachableAt'] : value['lastReachableAt'].toISOString(),
114
+ 'unreachable_since': value['unreachableSince'] == null ? value['unreachableSince'] : value['unreachableSince'].toISOString(),
112
115
  };
113
116
  }
package/docs/Instance.md CHANGED
@@ -21,6 +21,7 @@ Name | Type
21
21
  `readyAt` | Date
22
22
  `terminatedAt` | Date
23
23
  `lastReachableAt` | Date
24
+ `unreachableSince` | Date
24
25
 
25
26
  ## Example
26
27
 
@@ -44,6 +45,7 @@ const example = {
44
45
  "readyAt": null,
45
46
  "terminatedAt": null,
46
47
  "lastReachableAt": null,
48
+ "unreachableSince": null,
47
49
  } satisfies Instance
48
50
 
49
51
  console.log(example)
@@ -268,7 +268,7 @@ async function example() {
268
268
  cursor: cursor_example,
269
269
  // number (optional)
270
270
  limit: 56,
271
- // 'allocating' | 'starting' | 'running' | 'stopping' | 'stopped' | 'terminated' | 'error' | 'all' | Filter by customer-facing status (default = all non-terminated) (optional)
271
+ // 'allocating' | 'starting' | 'running' | 'stopping' | 'stopped' | 'terminated' | 'error' | 'all' | Filter by customer-facing status (default = all non-terminated). There is no \"unreachable\" filter value: an unreachable instance is a running instance with a dead tunnel, so it is listed under status=running and reads \"unreachable\" in the response body. (optional)
272
272
  status: status_example,
273
273
  } satisfies ListInstancesRequest;
274
274
 
@@ -291,7 +291,7 @@ example().catch(console.error);
291
291
  |------------- | ------------- | ------------- | -------------|
292
292
  | **cursor** | `string` | | [Optional] [Defaults to `undefined`] |
293
293
  | **limit** | `number` | | [Optional] [Defaults to `50`] |
294
- | **status** | `allocating`, `starting`, `running`, `stopping`, `stopped`, `terminated`, `error`, `all` | Filter by customer-facing status (default = all non-terminated) | [Optional] [Defaults to `undefined`] [Enum: allocating, starting, running, stopping, stopped, terminated, error, all] |
294
+ | **status** | `allocating`, `starting`, `running`, `stopping`, `stopped`, `terminated`, `error`, `all` | Filter by customer-facing status (default = all non-terminated). There is no \"unreachable\" filter value: an unreachable instance is a running instance with a dead tunnel, so it is listed under status=running and reads \"unreachable\" in the response body. | [Optional] [Defaults to `undefined`] [Enum: allocating, starting, running, stopping, stopped, terminated, error, all] |
295
295
 
296
296
  ### Return type
297
297
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gpuai/sdk",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "TypeScript SDK for the GPU.ai Public Developer API",
5
5
  "author": "GPU.ai Support <support@gpu.ai>",
6
6
  "repository": {
@@ -40,7 +40,7 @@ export interface Instance {
40
40
  */
41
41
  name?: string;
42
42
  /**
43
- * Customer-facing lifecycle status. "allocating" = the GPU is still being acquired from the provider (slow-boot capacity such as baremetal can take ~15 min); "starting" = the node exists and is booting; "running" = ready to use.
43
+ * Customer-facing lifecycle status. "allocating" = the GPU is still being acquired from the provider (slow-boot capacity such as baremetal can take ~15 min); "starting" = the node exists and is booting; "running" = ready to use. "unreachable" = the platform's tunnel probe has confirmed the SSH path is down while the machine may still be up: the instance is NOT usable right now, billing for the confirmed-dead window is auto-credited back, and the instance either recovers to "running" on its own or is failed after a grace window. It is a degraded reading of a running instance, not a separate lifecycle state — see unreachable_since.
44
44
  * @type {InstanceStatusEnum}
45
45
  * @memberof Instance
46
46
  */
@@ -117,6 +117,12 @@ export interface Instance {
117
117
  * @memberof Instance
118
118
  */
119
119
  lastReachableAt?: Date;
120
+ /**
121
+ * Start of the confirmed tunnel outage the instance is currently in. Present exactly when status is "unreachable", absent otherwise. It is the timestamp the auto-credit for the dead window is computed from, so a ledger credit can be reconciled against it.
122
+ * @type {Date}
123
+ * @memberof Instance
124
+ */
125
+ unreachableSince?: Date;
120
126
  }
121
127
 
122
128
 
@@ -130,6 +136,7 @@ export const InstanceStatusEnum = {
130
136
  Stopping: 'stopping',
131
137
  Stopped: 'stopped',
132
138
  Terminated: 'terminated',
139
+ Unreachable: 'unreachable',
133
140
  Error: 'error'
134
141
  } as const;
135
142
  export type InstanceStatusEnum = typeof InstanceStatusEnum[keyof typeof InstanceStatusEnum];
@@ -184,6 +191,7 @@ export function InstanceFromJSONTyped(json: any, ignoreDiscriminator: boolean):
184
191
  'readyAt': json['ready_at'] == null ? undefined : (new Date(json['ready_at'])),
185
192
  'terminatedAt': json['terminated_at'] == null ? undefined : (new Date(json['terminated_at'])),
186
193
  'lastReachableAt': json['last_reachable_at'] == null ? undefined : (new Date(json['last_reachable_at'])),
194
+ 'unreachableSince': json['unreachable_since'] == null ? undefined : (new Date(json['unreachable_since'])),
187
195
  };
188
196
  }
189
197
 
@@ -213,6 +221,7 @@ export function InstanceToJSONTyped(value?: Instance | null, ignoreDiscriminator
213
221
  'ready_at': value['readyAt'] == null ? value['readyAt'] : value['readyAt'].toISOString(),
214
222
  'terminated_at': value['terminatedAt'] == null ? value['terminatedAt'] : value['terminatedAt'].toISOString(),
215
223
  'last_reachable_at': value['lastReachableAt'] == null ? value['lastReachableAt'] : value['lastReachableAt'].toISOString(),
224
+ 'unreachable_since': value['unreachableSince'] == null ? value['unreachableSince'] : value['unreachableSince'].toISOString(),
216
225
  };
217
226
  }
218
227