@gpuai/sdk 0.5.3 → 0.5.5

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.
Files changed (218) hide show
  1. package/.openapi-generator/FILES +56 -0
  2. package/README.md +50 -2
  3. package/dist/apis/BillingApi.d.ts +2 -2
  4. package/dist/apis/BillingApi.js +2 -2
  5. package/dist/apis/EndpointsApi.d.ts +150 -0
  6. package/dist/apis/EndpointsApi.js +379 -0
  7. package/dist/apis/InstancesApi.d.ts +15 -0
  8. package/dist/apis/InstancesApi.js +45 -0
  9. package/dist/apis/JobsApi.d.ts +172 -0
  10. package/dist/apis/JobsApi.js +444 -0
  11. package/dist/apis/OperationsApi.d.ts +17 -0
  12. package/dist/apis/OperationsApi.js +48 -0
  13. package/dist/apis/SecretsApi.d.ts +123 -0
  14. package/dist/apis/SecretsApi.js +328 -0
  15. package/dist/apis/index.d.ts +3 -0
  16. package/dist/apis/index.js +3 -0
  17. package/dist/esm/apis/BillingApi.d.ts +2 -2
  18. package/dist/esm/apis/BillingApi.js +2 -2
  19. package/dist/esm/apis/EndpointsApi.d.ts +150 -0
  20. package/dist/esm/apis/EndpointsApi.js +375 -0
  21. package/dist/esm/apis/InstancesApi.d.ts +15 -0
  22. package/dist/esm/apis/InstancesApi.js +45 -0
  23. package/dist/esm/apis/JobsApi.d.ts +172 -0
  24. package/dist/esm/apis/JobsApi.js +440 -0
  25. package/dist/esm/apis/OperationsApi.d.ts +17 -0
  26. package/dist/esm/apis/OperationsApi.js +48 -0
  27. package/dist/esm/apis/SecretsApi.d.ts +123 -0
  28. package/dist/esm/apis/SecretsApi.js +324 -0
  29. package/dist/esm/apis/index.d.ts +3 -0
  30. package/dist/esm/apis/index.js +3 -0
  31. package/dist/esm/models/Balance.d.ts +6 -0
  32. package/dist/esm/models/Balance.js +2 -0
  33. package/dist/esm/models/CreateWebhookEndpointRequest.d.ts +3 -0
  34. package/dist/esm/models/CreateWebhookEndpointRequest.js +4 -1
  35. package/dist/esm/models/DedicatedIPOffer.d.ts +98 -0
  36. package/dist/esm/models/DedicatedIPOffer.js +87 -0
  37. package/dist/esm/models/Endpoint.d.ts +147 -0
  38. package/dist/esm/models/Endpoint.js +121 -0
  39. package/dist/esm/models/EndpointCreate.d.ts +80 -0
  40. package/dist/esm/models/EndpointCreate.js +63 -0
  41. package/dist/esm/models/EndpointList.d.ts +33 -0
  42. package/dist/esm/models/EndpointList.js +44 -0
  43. package/dist/esm/models/EndpointMachine.d.ts +90 -0
  44. package/dist/esm/models/EndpointMachine.js +84 -0
  45. package/dist/esm/models/EndpointReplicaCounts.d.ts +38 -0
  46. package/dist/esm/models/EndpointReplicaCounts.js +47 -0
  47. package/dist/esm/models/Job.d.ts +352 -0
  48. package/dist/esm/models/Job.js +254 -0
  49. package/dist/esm/models/JobAttempt.d.ts +176 -0
  50. package/dist/esm/models/JobAttempt.js +147 -0
  51. package/dist/esm/models/JobCreate.d.ts +153 -0
  52. package/dist/esm/models/JobCreate.js +84 -0
  53. package/dist/esm/models/JobGpuTypes.d.ts +39 -0
  54. package/dist/esm/models/JobGpuTypes.js +48 -0
  55. package/dist/esm/models/JobGpuTypesDataInner.d.ts +58 -0
  56. package/dist/esm/models/JobGpuTypesDataInner.js +59 -0
  57. package/dist/esm/models/JobLogChunk.d.ts +50 -0
  58. package/dist/esm/models/JobLogChunk.js +55 -0
  59. package/dist/esm/models/JobLogs.d.ts +39 -0
  60. package/dist/esm/models/JobLogs.js +48 -0
  61. package/dist/esm/models/JobPage.d.ts +39 -0
  62. package/dist/esm/models/JobPage.js +48 -0
  63. package/dist/esm/models/JobSharingHint.d.ts +46 -0
  64. package/dist/esm/models/JobSharingHint.js +51 -0
  65. package/dist/esm/models/JobTelemetry.d.ts +51 -0
  66. package/dist/esm/models/JobTelemetry.js +56 -0
  67. package/dist/esm/models/JobTelemetryPoint.d.ts +56 -0
  68. package/dist/esm/models/JobTelemetryPoint.js +59 -0
  69. package/dist/esm/models/JobTrial.d.ts +79 -0
  70. package/dist/esm/models/JobTrial.js +73 -0
  71. package/dist/esm/models/Secret.d.ts +62 -0
  72. package/dist/esm/models/Secret.js +63 -0
  73. package/dist/esm/models/SecretCreate.d.ts +44 -0
  74. package/dist/esm/models/SecretCreate.js +49 -0
  75. package/dist/esm/models/SecretImportItem.d.ts +38 -0
  76. package/dist/esm/models/SecretImportItem.js +47 -0
  77. package/dist/esm/models/SecretImportRequest.d.ts +39 -0
  78. package/dist/esm/models/SecretImportRequest.js +46 -0
  79. package/dist/esm/models/SecretImportResult.d.ts +44 -0
  80. package/dist/esm/models/SecretImportResult.js +51 -0
  81. package/dist/esm/models/SecretList.d.ts +33 -0
  82. package/dist/esm/models/SecretList.js +44 -0
  83. package/dist/esm/models/SecretPut.d.ts +38 -0
  84. package/dist/esm/models/SecretPut.js +45 -0
  85. package/dist/esm/models/WebhookEndpoint.d.ts +3 -0
  86. package/dist/esm/models/WebhookEndpoint.js +4 -1
  87. package/dist/esm/models/index.d.ts +25 -0
  88. package/dist/esm/models/index.js +25 -0
  89. package/dist/esm/runtime.js +1 -1
  90. package/dist/models/Balance.d.ts +6 -0
  91. package/dist/models/Balance.js +2 -0
  92. package/dist/models/CreateWebhookEndpointRequest.d.ts +3 -0
  93. package/dist/models/CreateWebhookEndpointRequest.js +4 -1
  94. package/dist/models/DedicatedIPOffer.d.ts +98 -0
  95. package/dist/models/DedicatedIPOffer.js +94 -0
  96. package/dist/models/Endpoint.d.ts +147 -0
  97. package/dist/models/Endpoint.js +129 -0
  98. package/dist/models/EndpointCreate.d.ts +80 -0
  99. package/dist/models/EndpointCreate.js +70 -0
  100. package/dist/models/EndpointList.d.ts +33 -0
  101. package/dist/models/EndpointList.js +51 -0
  102. package/dist/models/EndpointMachine.d.ts +90 -0
  103. package/dist/models/EndpointMachine.js +92 -0
  104. package/dist/models/EndpointReplicaCounts.d.ts +38 -0
  105. package/dist/models/EndpointReplicaCounts.js +54 -0
  106. package/dist/models/Job.d.ts +352 -0
  107. package/dist/models/Job.js +262 -0
  108. package/dist/models/JobAttempt.d.ts +176 -0
  109. package/dist/models/JobAttempt.js +155 -0
  110. package/dist/models/JobCreate.d.ts +153 -0
  111. package/dist/models/JobCreate.js +92 -0
  112. package/dist/models/JobGpuTypes.d.ts +39 -0
  113. package/dist/models/JobGpuTypes.js +55 -0
  114. package/dist/models/JobGpuTypesDataInner.d.ts +58 -0
  115. package/dist/models/JobGpuTypesDataInner.js +66 -0
  116. package/dist/models/JobLogChunk.d.ts +50 -0
  117. package/dist/models/JobLogChunk.js +62 -0
  118. package/dist/models/JobLogs.d.ts +39 -0
  119. package/dist/models/JobLogs.js +55 -0
  120. package/dist/models/JobPage.d.ts +39 -0
  121. package/dist/models/JobPage.js +55 -0
  122. package/dist/models/JobSharingHint.d.ts +46 -0
  123. package/dist/models/JobSharingHint.js +58 -0
  124. package/dist/models/JobTelemetry.d.ts +51 -0
  125. package/dist/models/JobTelemetry.js +63 -0
  126. package/dist/models/JobTelemetryPoint.d.ts +56 -0
  127. package/dist/models/JobTelemetryPoint.js +66 -0
  128. package/dist/models/JobTrial.d.ts +79 -0
  129. package/dist/models/JobTrial.js +81 -0
  130. package/dist/models/Secret.d.ts +62 -0
  131. package/dist/models/Secret.js +70 -0
  132. package/dist/models/SecretCreate.d.ts +44 -0
  133. package/dist/models/SecretCreate.js +56 -0
  134. package/dist/models/SecretImportItem.d.ts +38 -0
  135. package/dist/models/SecretImportItem.js +54 -0
  136. package/dist/models/SecretImportRequest.d.ts +39 -0
  137. package/dist/models/SecretImportRequest.js +53 -0
  138. package/dist/models/SecretImportResult.d.ts +44 -0
  139. package/dist/models/SecretImportResult.js +58 -0
  140. package/dist/models/SecretList.d.ts +33 -0
  141. package/dist/models/SecretList.js +51 -0
  142. package/dist/models/SecretPut.d.ts +38 -0
  143. package/dist/models/SecretPut.js +52 -0
  144. package/dist/models/WebhookEndpoint.d.ts +3 -0
  145. package/dist/models/WebhookEndpoint.js +4 -1
  146. package/dist/models/index.d.ts +25 -0
  147. package/dist/models/index.js +25 -0
  148. package/dist/runtime.js +1 -1
  149. package/docs/Balance.md +2 -0
  150. package/docs/BillingApi.md +2 -2
  151. package/docs/DedicatedIPOffer.md +56 -0
  152. package/docs/Endpoint.md +68 -0
  153. package/docs/EndpointCreate.md +50 -0
  154. package/docs/EndpointList.md +34 -0
  155. package/docs/EndpointMachine.md +50 -0
  156. package/docs/EndpointReplicaCounts.md +36 -0
  157. package/docs/EndpointsApi.md +544 -0
  158. package/docs/InstancesApi.md +68 -1
  159. package/docs/Job.md +125 -0
  160. package/docs/JobAttempt.md +69 -0
  161. package/docs/JobCreate.md +66 -0
  162. package/docs/JobGpuTypes.md +36 -0
  163. package/docs/JobGpuTypesDataInner.md +42 -0
  164. package/docs/JobLogChunk.md +40 -0
  165. package/docs/JobLogs.md +36 -0
  166. package/docs/JobPage.md +36 -0
  167. package/docs/JobSharingHint.md +39 -0
  168. package/docs/JobTelemetry.md +40 -0
  169. package/docs/JobTelemetryPoint.md +42 -0
  170. package/docs/JobTrial.md +46 -0
  171. package/docs/JobsApi.md +609 -0
  172. package/docs/OperationsApi.md +76 -0
  173. package/docs/Secret.md +45 -0
  174. package/docs/SecretCreate.md +38 -0
  175. package/docs/SecretImportItem.md +36 -0
  176. package/docs/SecretImportRequest.md +36 -0
  177. package/docs/SecretImportResult.md +38 -0
  178. package/docs/SecretList.md +34 -0
  179. package/docs/SecretPut.md +36 -0
  180. package/docs/SecretsApi.md +450 -0
  181. package/package.json +1 -1
  182. package/src/apis/BillingApi.ts +2 -2
  183. package/src/apis/EndpointsApi.ts +481 -0
  184. package/src/apis/InstancesApi.ts +52 -0
  185. package/src/apis/JobsApi.ts +551 -0
  186. package/src/apis/OperationsApi.ts +59 -0
  187. package/src/apis/SecretsApi.ts +413 -0
  188. package/src/apis/index.ts +3 -0
  189. package/src/models/Balance.ts +8 -0
  190. package/src/models/CreateWebhookEndpointRequest.ts +4 -1
  191. package/src/models/DedicatedIPOffer.ts +165 -0
  192. package/src/models/Endpoint.ts +247 -0
  193. package/src/models/EndpointCreate.ts +132 -0
  194. package/src/models/EndpointList.ts +74 -0
  195. package/src/models/EndpointMachine.ts +151 -0
  196. package/src/models/EndpointReplicaCounts.ts +75 -0
  197. package/src/models/Job.ts +538 -0
  198. package/src/models/JobAttempt.ts +267 -0
  199. package/src/models/JobCreate.ts +221 -0
  200. package/src/models/JobGpuTypes.ts +83 -0
  201. package/src/models/JobGpuTypesDataInner.ts +104 -0
  202. package/src/models/JobLogChunk.ts +93 -0
  203. package/src/models/JobLogs.ts +83 -0
  204. package/src/models/JobPage.ts +83 -0
  205. package/src/models/JobSharingHint.ts +86 -0
  206. package/src/models/JobTelemetry.ts +101 -0
  207. package/src/models/JobTelemetryPoint.ts +102 -0
  208. package/src/models/JobTrial.ts +132 -0
  209. package/src/models/Secret.ts +111 -0
  210. package/src/models/SecretCreate.ts +83 -0
  211. package/src/models/SecretImportItem.ts +75 -0
  212. package/src/models/SecretImportRequest.ts +82 -0
  213. package/src/models/SecretImportResult.ts +84 -0
  214. package/src/models/SecretList.ts +74 -0
  215. package/src/models/SecretPut.ts +74 -0
  216. package/src/models/WebhookEndpoint.ts +4 -1
  217. package/src/models/index.ts +25 -0
  218. package/src/runtime.ts +1 -1
@@ -0,0 +1,375 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * GPU.ai Public Developer API
5
+ * Programmatic API for GPU.ai. Authenticate with API keys minted from the dashboard. See https://gpu.ai/docs for details.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ * Contact: support@gpu.ai
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
15
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
16
+ return new (P || (P = Promise))(function (resolve, reject) {
17
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
18
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
19
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
20
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
21
+ });
22
+ };
23
+ import * as runtime from '../runtime';
24
+ import { ChatCompletionRequestToJSON, } from '../models/ChatCompletionRequest';
25
+ import { ChatCompletionResponseFromJSON, } from '../models/ChatCompletionResponse';
26
+ import { EndpointFromJSON, } from '../models/Endpoint';
27
+ import { EndpointCreateToJSON, } from '../models/EndpointCreate';
28
+ import { EndpointListFromJSON, } from '../models/EndpointList';
29
+ /**
30
+ *
31
+ */
32
+ export class EndpointsApi extends runtime.BaseAPI {
33
+ /**
34
+ * Creates request options for createEndpoint without sending the request
35
+ */
36
+ createEndpointRequestOpts(requestParameters) {
37
+ return __awaiter(this, void 0, void 0, function* () {
38
+ if (requestParameters['endpointCreate'] == null) {
39
+ throw new runtime.RequiredError('endpointCreate', 'Required parameter "endpointCreate" was null or undefined when calling createEndpoint().');
40
+ }
41
+ const queryParameters = {};
42
+ const headerParameters = {};
43
+ headerParameters['Content-Type'] = 'application/json';
44
+ if (this.configuration && this.configuration.accessToken) {
45
+ const token = this.configuration.accessToken;
46
+ const tokenString = yield token("bearerAuth", []);
47
+ if (tokenString) {
48
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
49
+ }
50
+ }
51
+ let urlPath = `/endpoints`;
52
+ return {
53
+ path: urlPath,
54
+ method: 'POST',
55
+ headers: headerParameters,
56
+ query: queryParameters,
57
+ body: EndpointCreateToJSON(requestParameters['endpointCreate']),
58
+ };
59
+ });
60
+ }
61
+ /**
62
+ * Creates an OpenAI-compatible endpoint serving a Hugging Face model with vLLM on the chosen GPU type. Nothing starts until the first request arrives, unless `min_replicas` keeps machines warm. Each machine is billed for the time it exists, like an instance, through the same balance. For a gated model, store a Hugging Face token as a secret and name it in `hf_token_secret`; it reaches the machines as HF_TOKEN. Returns 422 `validation_failed` for a bad field, 409 `name_taken` for a duplicate name, and 409 `limit_reached` at the per-organization cap. Requires the `functions:write` scope.
63
+ * Create a model endpoint
64
+ */
65
+ createEndpointRaw(requestParameters, initOverrides) {
66
+ return __awaiter(this, void 0, void 0, function* () {
67
+ const requestOptions = yield this.createEndpointRequestOpts(requestParameters);
68
+ const response = yield this.request(requestOptions, initOverrides);
69
+ return new runtime.JSONApiResponse(response, (jsonValue) => EndpointFromJSON(jsonValue));
70
+ });
71
+ }
72
+ /**
73
+ * Creates an OpenAI-compatible endpoint serving a Hugging Face model with vLLM on the chosen GPU type. Nothing starts until the first request arrives, unless `min_replicas` keeps machines warm. Each machine is billed for the time it exists, like an instance, through the same balance. For a gated model, store a Hugging Face token as a secret and name it in `hf_token_secret`; it reaches the machines as HF_TOKEN. Returns 422 `validation_failed` for a bad field, 409 `name_taken` for a duplicate name, and 409 `limit_reached` at the per-organization cap. Requires the `functions:write` scope.
74
+ * Create a model endpoint
75
+ */
76
+ createEndpoint(requestParameters, initOverrides) {
77
+ return __awaiter(this, void 0, void 0, function* () {
78
+ const response = yield this.createEndpointRaw(requestParameters, initOverrides);
79
+ return yield response.value();
80
+ });
81
+ }
82
+ /**
83
+ * Creates request options for createEndpointChatCompletion without sending the request
84
+ */
85
+ createEndpointChatCompletionRequestOpts(requestParameters) {
86
+ return __awaiter(this, void 0, void 0, function* () {
87
+ if (requestParameters['id'] == null) {
88
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling createEndpointChatCompletion().');
89
+ }
90
+ if (requestParameters['chatCompletionRequest'] == null) {
91
+ throw new runtime.RequiredError('chatCompletionRequest', 'Required parameter "chatCompletionRequest" was null or undefined when calling createEndpointChatCompletion().');
92
+ }
93
+ const queryParameters = {};
94
+ const headerParameters = {};
95
+ headerParameters['Content-Type'] = 'application/json';
96
+ if (this.configuration && this.configuration.accessToken) {
97
+ const token = this.configuration.accessToken;
98
+ const tokenString = yield token("bearerAuth", []);
99
+ if (tokenString) {
100
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
101
+ }
102
+ }
103
+ let urlPath = `/endpoints/{id}/openai/v1/chat/completions`;
104
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
105
+ return {
106
+ path: urlPath,
107
+ method: 'POST',
108
+ headers: headerParameters,
109
+ query: queryParameters,
110
+ body: ChatCompletionRequestToJSON(requestParameters['chatCompletionRequest']),
111
+ };
112
+ });
113
+ }
114
+ /**
115
+ * The OpenAI chat completions route of one endpoint: point an OpenAI client\'s base_url at the endpoint\'s `url` and use a GPU.ai API key with the `functions:write` scope. The request\'s `model` is replaced with the endpoint\'s model, so any value works. Set `\"stream\": true` for Server-Sent Events, passed through as vLLM produces them. When no machine is ready the request waits while one starts (a cold start takes minutes: machine, image and model download); if none is ready in time the answer is 503 `endpoint_starting` with Retry-After. 402 `insufficient_quota` when the balance is empty. Errors use the OpenAI error envelope.
116
+ * Chat completion on a model endpoint (OpenAI-compatible)
117
+ */
118
+ createEndpointChatCompletionRaw(requestParameters, initOverrides) {
119
+ return __awaiter(this, void 0, void 0, function* () {
120
+ const requestOptions = yield this.createEndpointChatCompletionRequestOpts(requestParameters);
121
+ const response = yield this.request(requestOptions, initOverrides);
122
+ return new runtime.JSONApiResponse(response, (jsonValue) => ChatCompletionResponseFromJSON(jsonValue));
123
+ });
124
+ }
125
+ /**
126
+ * The OpenAI chat completions route of one endpoint: point an OpenAI client\'s base_url at the endpoint\'s `url` and use a GPU.ai API key with the `functions:write` scope. The request\'s `model` is replaced with the endpoint\'s model, so any value works. Set `\"stream\": true` for Server-Sent Events, passed through as vLLM produces them. When no machine is ready the request waits while one starts (a cold start takes minutes: machine, image and model download); if none is ready in time the answer is 503 `endpoint_starting` with Retry-After. 402 `insufficient_quota` when the balance is empty. Errors use the OpenAI error envelope.
127
+ * Chat completion on a model endpoint (OpenAI-compatible)
128
+ */
129
+ createEndpointChatCompletion(requestParameters, initOverrides) {
130
+ return __awaiter(this, void 0, void 0, function* () {
131
+ const response = yield this.createEndpointChatCompletionRaw(requestParameters, initOverrides);
132
+ return yield response.value();
133
+ });
134
+ }
135
+ /**
136
+ * Creates request options for createEndpointCompletion without sending the request
137
+ */
138
+ createEndpointCompletionRequestOpts(requestParameters) {
139
+ return __awaiter(this, void 0, void 0, function* () {
140
+ if (requestParameters['id'] == null) {
141
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling createEndpointCompletion().');
142
+ }
143
+ if (requestParameters['requestBody'] == null) {
144
+ throw new runtime.RequiredError('requestBody', 'Required parameter "requestBody" was null or undefined when calling createEndpointCompletion().');
145
+ }
146
+ const queryParameters = {};
147
+ const headerParameters = {};
148
+ headerParameters['Content-Type'] = 'application/json';
149
+ if (this.configuration && this.configuration.accessToken) {
150
+ const token = this.configuration.accessToken;
151
+ const tokenString = yield token("bearerAuth", []);
152
+ if (tokenString) {
153
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
154
+ }
155
+ }
156
+ let urlPath = `/endpoints/{id}/openai/v1/completions`;
157
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
158
+ return {
159
+ path: urlPath,
160
+ method: 'POST',
161
+ headers: headerParameters,
162
+ query: queryParameters,
163
+ body: requestParameters['requestBody'],
164
+ };
165
+ });
166
+ }
167
+ /**
168
+ * The OpenAI completions route of one endpoint, with the same auth, model rewrite, streaming, cold start and error behavior as chat completions.
169
+ * Text completion on a model endpoint (OpenAI-compatible)
170
+ */
171
+ createEndpointCompletionRaw(requestParameters, initOverrides) {
172
+ return __awaiter(this, void 0, void 0, function* () {
173
+ const requestOptions = yield this.createEndpointCompletionRequestOpts(requestParameters);
174
+ const response = yield this.request(requestOptions, initOverrides);
175
+ return new runtime.JSONApiResponse(response);
176
+ });
177
+ }
178
+ /**
179
+ * The OpenAI completions route of one endpoint, with the same auth, model rewrite, streaming, cold start and error behavior as chat completions.
180
+ * Text completion on a model endpoint (OpenAI-compatible)
181
+ */
182
+ createEndpointCompletion(requestParameters, initOverrides) {
183
+ return __awaiter(this, void 0, void 0, function* () {
184
+ const response = yield this.createEndpointCompletionRaw(requestParameters, initOverrides);
185
+ return yield response.value();
186
+ });
187
+ }
188
+ /**
189
+ * Creates request options for deleteEndpoint without sending the request
190
+ */
191
+ deleteEndpointRequestOpts(requestParameters) {
192
+ return __awaiter(this, void 0, void 0, function* () {
193
+ if (requestParameters['id'] == null) {
194
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling deleteEndpoint().');
195
+ }
196
+ const queryParameters = {};
197
+ const headerParameters = {};
198
+ if (this.configuration && this.configuration.accessToken) {
199
+ const token = this.configuration.accessToken;
200
+ const tokenString = yield token("bearerAuth", []);
201
+ if (tokenString) {
202
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
203
+ }
204
+ }
205
+ let urlPath = `/endpoints/{id}`;
206
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
207
+ return {
208
+ path: urlPath,
209
+ method: 'DELETE',
210
+ headers: headerParameters,
211
+ query: queryParameters,
212
+ };
213
+ });
214
+ }
215
+ /**
216
+ * Deletes the endpoint. Its machines are released within seconds and stop billing when terminated. Requires the `functions:write` scope.
217
+ * Delete a model endpoint
218
+ */
219
+ deleteEndpointRaw(requestParameters, initOverrides) {
220
+ return __awaiter(this, void 0, void 0, function* () {
221
+ const requestOptions = yield this.deleteEndpointRequestOpts(requestParameters);
222
+ const response = yield this.request(requestOptions, initOverrides);
223
+ return new runtime.VoidApiResponse(response);
224
+ });
225
+ }
226
+ /**
227
+ * Deletes the endpoint. Its machines are released within seconds and stop billing when terminated. Requires the `functions:write` scope.
228
+ * Delete a model endpoint
229
+ */
230
+ deleteEndpoint(requestParameters, initOverrides) {
231
+ return __awaiter(this, void 0, void 0, function* () {
232
+ yield this.deleteEndpointRaw(requestParameters, initOverrides);
233
+ });
234
+ }
235
+ /**
236
+ * Creates request options for getEndpoint without sending the request
237
+ */
238
+ getEndpointRequestOpts(requestParameters) {
239
+ return __awaiter(this, void 0, void 0, function* () {
240
+ if (requestParameters['id'] == null) {
241
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling getEndpoint().');
242
+ }
243
+ const queryParameters = {};
244
+ const headerParameters = {};
245
+ if (this.configuration && this.configuration.accessToken) {
246
+ const token = this.configuration.accessToken;
247
+ const tokenString = yield token("bearerAuth", []);
248
+ if (tokenString) {
249
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
250
+ }
251
+ }
252
+ let urlPath = `/endpoints/{id}`;
253
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
254
+ return {
255
+ path: urlPath,
256
+ method: 'GET',
257
+ headers: headerParameters,
258
+ query: queryParameters,
259
+ };
260
+ });
261
+ }
262
+ /**
263
+ * Returns one endpoint with its recent machines (newest first), each with its price, ready and terminated times, and why it was released. Requires the `functions:read` scope.
264
+ * Get a model endpoint
265
+ */
266
+ getEndpointRaw(requestParameters, initOverrides) {
267
+ return __awaiter(this, void 0, void 0, function* () {
268
+ const requestOptions = yield this.getEndpointRequestOpts(requestParameters);
269
+ const response = yield this.request(requestOptions, initOverrides);
270
+ return new runtime.JSONApiResponse(response, (jsonValue) => EndpointFromJSON(jsonValue));
271
+ });
272
+ }
273
+ /**
274
+ * Returns one endpoint with its recent machines (newest first), each with its price, ready and terminated times, and why it was released. Requires the `functions:read` scope.
275
+ * Get a model endpoint
276
+ */
277
+ getEndpoint(requestParameters, initOverrides) {
278
+ return __awaiter(this, void 0, void 0, function* () {
279
+ const response = yield this.getEndpointRaw(requestParameters, initOverrides);
280
+ return yield response.value();
281
+ });
282
+ }
283
+ /**
284
+ * Creates request options for listEndpointModels without sending the request
285
+ */
286
+ listEndpointModelsRequestOpts(requestParameters) {
287
+ return __awaiter(this, void 0, void 0, function* () {
288
+ if (requestParameters['id'] == null) {
289
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling listEndpointModels().');
290
+ }
291
+ const queryParameters = {};
292
+ const headerParameters = {};
293
+ if (this.configuration && this.configuration.accessToken) {
294
+ const token = this.configuration.accessToken;
295
+ const tokenString = yield token("bearerAuth", []);
296
+ if (tokenString) {
297
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
298
+ }
299
+ }
300
+ let urlPath = `/endpoints/{id}/openai/v1/models`;
301
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
302
+ return {
303
+ path: urlPath,
304
+ method: 'GET',
305
+ headers: headerParameters,
306
+ query: queryParameters,
307
+ };
308
+ });
309
+ }
310
+ /**
311
+ * The OpenAI models route of one endpoint: the one model it serves. Can trigger a cold start like any other request.
312
+ * List the model an endpoint serves (OpenAI-compatible)
313
+ */
314
+ listEndpointModelsRaw(requestParameters, initOverrides) {
315
+ return __awaiter(this, void 0, void 0, function* () {
316
+ const requestOptions = yield this.listEndpointModelsRequestOpts(requestParameters);
317
+ const response = yield this.request(requestOptions, initOverrides);
318
+ return new runtime.JSONApiResponse(response);
319
+ });
320
+ }
321
+ /**
322
+ * The OpenAI models route of one endpoint: the one model it serves. Can trigger a cold start like any other request.
323
+ * List the model an endpoint serves (OpenAI-compatible)
324
+ */
325
+ listEndpointModels(requestParameters, initOverrides) {
326
+ return __awaiter(this, void 0, void 0, function* () {
327
+ const response = yield this.listEndpointModelsRaw(requestParameters, initOverrides);
328
+ return yield response.value();
329
+ });
330
+ }
331
+ /**
332
+ * Creates request options for listEndpoints without sending the request
333
+ */
334
+ listEndpointsRequestOpts() {
335
+ return __awaiter(this, void 0, void 0, function* () {
336
+ const queryParameters = {};
337
+ const headerParameters = {};
338
+ if (this.configuration && this.configuration.accessToken) {
339
+ const token = this.configuration.accessToken;
340
+ const tokenString = yield token("bearerAuth", []);
341
+ if (tokenString) {
342
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
343
+ }
344
+ }
345
+ let urlPath = `/endpoints`;
346
+ return {
347
+ path: urlPath,
348
+ method: 'GET',
349
+ headers: headerParameters,
350
+ query: queryParameters,
351
+ };
352
+ });
353
+ }
354
+ /**
355
+ * Lists the organization\'s live model endpoints with their status, URL and machine counts. Requires the `functions:read` scope.
356
+ * List model endpoints
357
+ */
358
+ listEndpointsRaw(initOverrides) {
359
+ return __awaiter(this, void 0, void 0, function* () {
360
+ const requestOptions = yield this.listEndpointsRequestOpts();
361
+ const response = yield this.request(requestOptions, initOverrides);
362
+ return new runtime.JSONApiResponse(response, (jsonValue) => EndpointListFromJSON(jsonValue));
363
+ });
364
+ }
365
+ /**
366
+ * Lists the organization\'s live model endpoints with their status, URL and machine counts. Requires the `functions:read` scope.
367
+ * List model endpoints
368
+ */
369
+ listEndpoints(initOverrides) {
370
+ return __awaiter(this, void 0, void 0, function* () {
371
+ const response = yield this.listEndpointsRaw(initOverrides);
372
+ return yield response.value();
373
+ });
374
+ }
375
+ }
@@ -11,6 +11,7 @@
11
11
  */
12
12
  import * as runtime from '../runtime';
13
13
  import { type CreateInstanceRequest } from '../models/CreateInstanceRequest';
14
+ import { type DedicatedIPOffer } from '../models/DedicatedIPOffer';
14
15
  import { type GpuSuggestion } from '../models/GpuSuggestion';
15
16
  import { type Instance } from '../models/Instance';
16
17
  import { type InstancePage } from '../models/InstancePage';
@@ -73,6 +74,20 @@ export declare class InstancesApi extends runtime.BaseAPI {
73
74
  * Terminate an instance (idempotent)
74
75
  */
75
76
  deleteInstance(requestParameters: DeleteInstanceRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Operation>;
77
+ /**
78
+ * Creates request options for getDedicatedIpOffer without sending the request
79
+ */
80
+ getDedicatedIpOfferRequestOpts(): Promise<runtime.RequestOpts>;
81
+ /**
82
+ * Describes the dedicated public IPv4 add-on for instances and the caller\'s usage of it. A dedicated IP is a GPU.ai-owned public address (never the supplier\'s) that forwards the chosen inbound TCP ports, raw and without TLS termination, to the same ports on the instance\'s loopback. Request one at launch with the `dedicated_ip` field on POST /instances. The response carries the hourly fee charged while the address is attached, the transfer price per GB (counted in both directions), the transfer cap per attachment after which forwarding is suspended, the ports a launch may forward, the organization\'s limit and how many it holds, how many addresses are free right now, and the acceptable use policy. Requires the `instances:read` scope. Returns 404 when the add-on is not enabled for this deployment.
83
+ * Get the dedicated public IP add-on offer
84
+ */
85
+ getDedicatedIpOfferRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DedicatedIPOffer>>;
86
+ /**
87
+ * Describes the dedicated public IPv4 add-on for instances and the caller\'s usage of it. A dedicated IP is a GPU.ai-owned public address (never the supplier\'s) that forwards the chosen inbound TCP ports, raw and without TLS termination, to the same ports on the instance\'s loopback. Request one at launch with the `dedicated_ip` field on POST /instances. The response carries the hourly fee charged while the address is attached, the transfer price per GB (counted in both directions), the transfer cap per attachment after which forwarding is suspended, the ports a launch may forward, the organization\'s limit and how many it holds, how many addresses are free right now, and the acceptable use policy. Requires the `instances:read` scope. Returns 404 when the add-on is not enabled for this deployment.
88
+ * Get the dedicated public IP add-on offer
89
+ */
90
+ getDedicatedIpOffer(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DedicatedIPOffer>;
76
91
  /**
77
92
  * Creates request options for getInstance without sending the request
78
93
  */
@@ -22,6 +22,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
22
22
  };
23
23
  import * as runtime from '../runtime';
24
24
  import { CreateInstanceRequestToJSON, } from '../models/CreateInstanceRequest';
25
+ import { DedicatedIPOfferFromJSON, } from '../models/DedicatedIPOffer';
25
26
  import { GpuSuggestionFromJSON, } from '../models/GpuSuggestion';
26
27
  import { InstanceFromJSON, } from '../models/Instance';
27
28
  import { InstancePageFromJSON, } from '../models/InstancePage';
@@ -134,6 +135,50 @@ export class InstancesApi extends runtime.BaseAPI {
134
135
  return yield response.value();
135
136
  });
136
137
  }
138
+ /**
139
+ * Creates request options for getDedicatedIpOffer without sending the request
140
+ */
141
+ getDedicatedIpOfferRequestOpts() {
142
+ return __awaiter(this, void 0, void 0, function* () {
143
+ const queryParameters = {};
144
+ const headerParameters = {};
145
+ if (this.configuration && this.configuration.accessToken) {
146
+ const token = this.configuration.accessToken;
147
+ const tokenString = yield token("bearerAuth", []);
148
+ if (tokenString) {
149
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
150
+ }
151
+ }
152
+ let urlPath = `/dedicated-ip`;
153
+ return {
154
+ path: urlPath,
155
+ method: 'GET',
156
+ headers: headerParameters,
157
+ query: queryParameters,
158
+ };
159
+ });
160
+ }
161
+ /**
162
+ * Describes the dedicated public IPv4 add-on for instances and the caller\'s usage of it. A dedicated IP is a GPU.ai-owned public address (never the supplier\'s) that forwards the chosen inbound TCP ports, raw and without TLS termination, to the same ports on the instance\'s loopback. Request one at launch with the `dedicated_ip` field on POST /instances. The response carries the hourly fee charged while the address is attached, the transfer price per GB (counted in both directions), the transfer cap per attachment after which forwarding is suspended, the ports a launch may forward, the organization\'s limit and how many it holds, how many addresses are free right now, and the acceptable use policy. Requires the `instances:read` scope. Returns 404 when the add-on is not enabled for this deployment.
163
+ * Get the dedicated public IP add-on offer
164
+ */
165
+ getDedicatedIpOfferRaw(initOverrides) {
166
+ return __awaiter(this, void 0, void 0, function* () {
167
+ const requestOptions = yield this.getDedicatedIpOfferRequestOpts();
168
+ const response = yield this.request(requestOptions, initOverrides);
169
+ return new runtime.JSONApiResponse(response, (jsonValue) => DedicatedIPOfferFromJSON(jsonValue));
170
+ });
171
+ }
172
+ /**
173
+ * Describes the dedicated public IPv4 add-on for instances and the caller\'s usage of it. A dedicated IP is a GPU.ai-owned public address (never the supplier\'s) that forwards the chosen inbound TCP ports, raw and without TLS termination, to the same ports on the instance\'s loopback. Request one at launch with the `dedicated_ip` field on POST /instances. The response carries the hourly fee charged while the address is attached, the transfer price per GB (counted in both directions), the transfer cap per attachment after which forwarding is suspended, the ports a launch may forward, the organization\'s limit and how many it holds, how many addresses are free right now, and the acceptable use policy. Requires the `instances:read` scope. Returns 404 when the add-on is not enabled for this deployment.
174
+ * Get the dedicated public IP add-on offer
175
+ */
176
+ getDedicatedIpOffer(initOverrides) {
177
+ return __awaiter(this, void 0, void 0, function* () {
178
+ const response = yield this.getDedicatedIpOfferRaw(initOverrides);
179
+ return yield response.value();
180
+ });
181
+ }
137
182
  /**
138
183
  * Creates request options for getInstance without sending the request
139
184
  */
@@ -0,0 +1,172 @@
1
+ /**
2
+ * GPU.ai Public Developer API
3
+ * Programmatic API for GPU.ai. Authenticate with API keys minted from the dashboard. See https://gpu.ai/docs for details.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: support@gpu.ai
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import * as runtime from '../runtime';
13
+ import { type Job } from '../models/Job';
14
+ import { type JobCreate } from '../models/JobCreate';
15
+ import { type JobGpuTypes } from '../models/JobGpuTypes';
16
+ import { type JobLogs } from '../models/JobLogs';
17
+ import { type JobPage } from '../models/JobPage';
18
+ import { type JobTelemetry } from '../models/JobTelemetry';
19
+ import { type JobTrial } from '../models/JobTrial';
20
+ export interface CancelJobRequest {
21
+ id: string;
22
+ idempotencyKey?: string;
23
+ }
24
+ export interface CreateJobRequest {
25
+ jobCreate: JobCreate;
26
+ idempotencyKey?: string;
27
+ }
28
+ export interface GetJobRequest {
29
+ id: string;
30
+ }
31
+ export interface GetJobLogsRequest {
32
+ id: string;
33
+ after?: number;
34
+ limit?: number;
35
+ }
36
+ export interface GetJobTelemetryRequest {
37
+ id: string;
38
+ }
39
+ export interface ListJobsRequest {
40
+ status?: ListJobsStatusEnum;
41
+ cursor?: string;
42
+ limit?: number;
43
+ }
44
+ /**
45
+ *
46
+ */
47
+ export declare class JobsApi extends runtime.BaseAPI {
48
+ /**
49
+ * Creates request options for cancelJob without sending the request
50
+ */
51
+ cancelJobRequestOpts(requestParameters: CancelJobRequest): Promise<runtime.RequestOpts>;
52
+ /**
53
+ * Cancels a job. A queued job is cancelled at once. A running job is stopped the next time its machine reports, within a few seconds, and shows `cancel_requested` until then. Cancelling a job that has already finished returns it unchanged. Requires the `instances:write` scope.
54
+ * Cancel a job
55
+ */
56
+ cancelJobRaw(requestParameters: CancelJobRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Job>>;
57
+ /**
58
+ * Cancels a job. A queued job is cancelled at once. A running job is stopped the next time its machine reports, within a few seconds, and shows `cancel_requested` until then. Cancelling a job that has already finished returns it unchanged. Requires the `instances:write` scope.
59
+ * Cancel a job
60
+ */
61
+ cancelJob(requestParameters: CancelJobRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Job>;
62
+ /**
63
+ * Creates request options for createJob without sending the request
64
+ */
65
+ createJobRequestOpts(requestParameters: CreateJobRequest): Promise<runtime.RequestOpts>;
66
+ /**
67
+ * Queues a batch job: a container image, a command, and the GPU it needs. The platform places it on a machine in your organization\'s job pool, starting a machine when none has room, and terminates machines that have been empty for a few minutes. Requires the `instances:write` scope, because a job can start a machine. Three opt-ins decide how the job is placed. `max_wait_seconds` lets the job wait for space on a machine you are already paying for before a new one is started. `allow_sharing` lets the job run on the same GPU as other jobs from your own organization. A GPU is never shared with another customer. `allow_restart` lets the platform stop and rerun the job, which sharing needs. A job shares a GPU only when `allow_sharing` and `allow_restart` are both true and its memory is known, from `memory_hint_mb` or from the peaks of earlier finished jobs with the same name or image. Any other job gets a whole GPU. Sharing is also limited by compute. Jobs share a GPU only while the sum of their expected compute duties (the share of time each keeps the GPU busy) stays at or under 100%, so two jobs that saturate the GPU never share one. A job\'s duty comes from `compute_hint_pct` or from the measured utilization of earlier finished jobs with the same name or image. A job with neither counts as 100% and gets a GPU to itself until it has been measured. The memory reservation is not a hard cap. A job that exits out of GPU memory, or that is stopped for outgrowing its reservation on a full GPU, is run again with a larger reservation, then with a whole GPU, up to `max_retries`. Every job gets a checkpoint directory that survives those reruns on the same machine. Billing: the machines a job runs on are instances of your organization and are billed like any instance. `attributed_cost_usd` on the job is its share of that, for display. Free trial: when this deployment runs one, an organization\'s first jobs are free up to a cap (GET /jobs/trial). Their attributed cost is credited back to the balance as they run.
68
+ * Submit a job
69
+ */
70
+ createJobRaw(requestParameters: CreateJobRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Job>>;
71
+ /**
72
+ * Queues a batch job: a container image, a command, and the GPU it needs. The platform places it on a machine in your organization\'s job pool, starting a machine when none has room, and terminates machines that have been empty for a few minutes. Requires the `instances:write` scope, because a job can start a machine. Three opt-ins decide how the job is placed. `max_wait_seconds` lets the job wait for space on a machine you are already paying for before a new one is started. `allow_sharing` lets the job run on the same GPU as other jobs from your own organization. A GPU is never shared with another customer. `allow_restart` lets the platform stop and rerun the job, which sharing needs. A job shares a GPU only when `allow_sharing` and `allow_restart` are both true and its memory is known, from `memory_hint_mb` or from the peaks of earlier finished jobs with the same name or image. Any other job gets a whole GPU. Sharing is also limited by compute. Jobs share a GPU only while the sum of their expected compute duties (the share of time each keeps the GPU busy) stays at or under 100%, so two jobs that saturate the GPU never share one. A job\'s duty comes from `compute_hint_pct` or from the measured utilization of earlier finished jobs with the same name or image. A job with neither counts as 100% and gets a GPU to itself until it has been measured. The memory reservation is not a hard cap. A job that exits out of GPU memory, or that is stopped for outgrowing its reservation on a full GPU, is run again with a larger reservation, then with a whole GPU, up to `max_retries`. Every job gets a checkpoint directory that survives those reruns on the same machine. Billing: the machines a job runs on are instances of your organization and are billed like any instance. `attributed_cost_usd` on the job is its share of that, for display. Free trial: when this deployment runs one, an organization\'s first jobs are free up to a cap (GET /jobs/trial). Their attributed cost is credited back to the balance as they run.
73
+ * Submit a job
74
+ */
75
+ createJob(requestParameters: CreateJobRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Job>;
76
+ /**
77
+ * Creates request options for getJob without sending the request
78
+ */
79
+ getJobRequestOpts(requestParameters: GetJobRequest): Promise<runtime.RequestOpts>;
80
+ /**
81
+ * Returns one job with its attempts. Requires the `instances:read` scope.
82
+ * Get a job
83
+ */
84
+ getJobRaw(requestParameters: GetJobRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Job>>;
85
+ /**
86
+ * Returns one job with its attempts. Requires the `instances:read` scope.
87
+ * Get a job
88
+ */
89
+ getJob(requestParameters: GetJobRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Job>;
90
+ /**
91
+ * Creates request options for getJobLogs without sending the request
92
+ */
93
+ getJobLogsRequestOpts(requestParameters: GetJobLogsRequest): Promise<runtime.RequestOpts>;
94
+ /**
95
+ * Returns the job\'s combined standard output and standard error, in chunks, across all attempts. Pass the `next_after` of one response as `after` on the next to read on from there. Output is uploaded every few seconds while the job runs, and stored output is capped at about 8 MB per attempt. Requires the `instances:read` scope.
96
+ * Read a job\'s output
97
+ */
98
+ getJobLogsRaw(requestParameters: GetJobLogsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<JobLogs>>;
99
+ /**
100
+ * Returns the job\'s combined standard output and standard error, in chunks, across all attempts. Pass the `next_after` of one response as `after` on the next to read on from there. Output is uploaded every few seconds while the job runs, and stored output is capped at about 8 MB per attempt. Requires the `instances:read` scope.
101
+ * Read a job\'s output
102
+ */
103
+ getJobLogs(requestParameters: GetJobLogsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<JobLogs>;
104
+ /**
105
+ * Creates request options for getJobTelemetry without sending the request
106
+ */
107
+ getJobTelemetryRequestOpts(requestParameters: GetJobTelemetryRequest): Promise<runtime.RequestOpts>;
108
+ /**
109
+ * Returns the job\'s peak GPU memory, its reservation, and up to the 720 most recent memory points. The machine samples every 2 seconds and stores one point per report, the highest sample in that window. Points are kept for 30 days. Requires the `instances:read` scope.
110
+ * Read a job\'s GPU memory telemetry
111
+ */
112
+ getJobTelemetryRaw(requestParameters: GetJobTelemetryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<JobTelemetry>>;
113
+ /**
114
+ * Returns the job\'s peak GPU memory, its reservation, and up to the 720 most recent memory points. The machine samples every 2 seconds and stores one point per report, the highest sample in that window. Points are kept for 30 days. Requires the `instances:read` scope.
115
+ * Read a job\'s GPU memory telemetry
116
+ */
117
+ getJobTelemetry(requestParameters: GetJobTelemetryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<JobTelemetry>;
118
+ /**
119
+ * Creates request options for getJobTrial without sending the request
120
+ */
121
+ getJobTrialRequestOpts(): Promise<runtime.RequestOpts>;
122
+ /**
123
+ * Reports the Jobs free trial for this organization. When the deployment runs one, an organization\'s first jobs are free up to `cap_cents`: the cost attributed to its jobs is credited back to its balance as they run, until the credits reach the cap. One trial per organization, for organizations that had not used Jobs before the trial started. `enabled` is false when there is no trial. Requires the `instances:read` scope.
124
+ * Whether this organization\'s first jobs are free
125
+ */
126
+ getJobTrialRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<JobTrial>>;
127
+ /**
128
+ * Reports the Jobs free trial for this organization. When the deployment runs one, an organization\'s first jobs are free up to `cap_cents`: the cost attributed to its jobs is credited back to its balance as they run, until the credits reach the cap. One trial per organization, for organizations that had not used Jobs before the trial started. `enabled` is false when there is no trial. Requires the `instances:read` scope.
129
+ * Whether this organization\'s first jobs are free
130
+ */
131
+ getJobTrial(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<JobTrial>;
132
+ /**
133
+ * Creates request options for listJobGpuTypes without sending the request
134
+ */
135
+ listJobGpuTypesRequestOpts(): Promise<runtime.RequestOpts>;
136
+ /**
137
+ * Returns the GPU types the suppliers that run jobs rent as a one-GPU machine, smallest memory first. A type is listed when one of them offered it in the last 7 days, in stock or not. `available_now` says whether one has such a machine to rent now, and `price_per_gpu_hour` is the cheapest retail price of it at that read (a guide, not a quote: the launch prices it again). When `complete` is true, `POST /jobs` refuses any other `gpu_type` with a 422 (and a `min_vram_gb` larger than every listed type), instead of queueing a job that could never start. When `complete` is false the list may be partial or empty, and a job for any known GPU model is accepted and waits for a machine. Requires the `instances:read` scope.
138
+ * List the GPU types a job can run on
139
+ */
140
+ listJobGpuTypesRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<JobGpuTypes>>;
141
+ /**
142
+ * Returns the GPU types the suppliers that run jobs rent as a one-GPU machine, smallest memory first. A type is listed when one of them offered it in the last 7 days, in stock or not. `available_now` says whether one has such a machine to rent now, and `price_per_gpu_hour` is the cheapest retail price of it at that read (a guide, not a quote: the launch prices it again). When `complete` is true, `POST /jobs` refuses any other `gpu_type` with a 422 (and a `min_vram_gb` larger than every listed type), instead of queueing a job that could never start. When `complete` is false the list may be partial or empty, and a job for any known GPU model is accepted and waits for a machine. Requires the `instances:read` scope.
143
+ * List the GPU types a job can run on
144
+ */
145
+ listJobGpuTypes(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<JobGpuTypes>;
146
+ /**
147
+ * Creates request options for listJobs without sending the request
148
+ */
149
+ listJobsRequestOpts(requestParameters: ListJobsRequest): Promise<runtime.RequestOpts>;
150
+ /**
151
+ * Lists this organization\'s jobs, newest first. Requires the `instances:read` scope. Jobs belonging to other organizations are never returned.
152
+ * List jobs
153
+ */
154
+ listJobsRaw(requestParameters: ListJobsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<JobPage>>;
155
+ /**
156
+ * Lists this organization\'s jobs, newest first. Requires the `instances:read` scope. Jobs belonging to other organizations are never returned.
157
+ * List jobs
158
+ */
159
+ listJobs(requestParameters?: ListJobsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<JobPage>;
160
+ }
161
+ /**
162
+ * @export
163
+ */
164
+ export declare const ListJobsStatusEnum: {
165
+ readonly Queued: "queued";
166
+ readonly Assigned: "assigned";
167
+ readonly Running: "running";
168
+ readonly Succeeded: "succeeded";
169
+ readonly Failed: "failed";
170
+ readonly Cancelled: "cancelled";
171
+ };
172
+ export type ListJobsStatusEnum = typeof ListJobsStatusEnum[keyof typeof ListJobsStatusEnum];