Skip to content

Commit 1e295a9

Browse files
release: 0.1.0-alpha.27 (#38)
Co-authored-by: stainless-app[bot] <142633134+stainless-app[bot]@users.noreply.github.com>
1 parent f5027ab commit 1e295a9

File tree

7 files changed

+40
-16
lines changed

7 files changed

+40
-16
lines changed

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "0.1.0-alpha.26"
2+
".": "0.1.0-alpha.27"
33
}

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 15
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/the-san-francisco-compute-company%2Fsfc-nodes-c9d6d56eabd56a40a29dc2639a77d22dd5394ecd3ec9aeaebb3a3977811571da.yml
3-
openapi_spec_hash: beda3f45c48679e14d6fe8bbe7003d51
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/the-san-francisco-compute-company%2Fsfc-nodes-7284b205c8d1bc77799405fdd08ca68120426b87031cbc22718da68e22ed5a4c.yml
3+
openapi_spec_hash: b0248957ae5bcf9896f6d74d5c05351b
44
config_hash: a187153315a646ecf95709ee4a223df5

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# Changelog
22

3+
## 0.1.0-alpha.27 (2025-12-06)
4+
5+
Full Changelog: [v0.1.0-alpha.26...v0.1.0-alpha.27](https://github.com/sfcompute/nodes-typescript/compare/v0.1.0-alpha.26...v0.1.0-alpha.27)
6+
7+
### Features
8+
9+
* **api:** api update ([67e17ed](https://github.com/sfcompute/nodes-typescript/commit/67e17edd227cea207de6dea21fc207639ed66f49))
10+
311
## 0.1.0-alpha.26 (2025-12-03)
412

513
Full Changelog: [v0.1.0-alpha.25...v0.1.0-alpha.26](https://github.com/sfcompute/nodes-typescript/compare/v0.1.0-alpha.25...v0.1.0-alpha.26)

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@sfcompute/nodes-sdk-alpha",
3-
"version": "0.1.0-alpha.26",
3+
"version": "0.1.0-alpha.27",
44
"description": "The official TypeScript library for the SFC Nodes API",
55
"author": "SFC Nodes <hello@sfcompute.com>",
66
"types": "dist/index.d.ts",

src/resources/nodes.ts

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ export class Nodes extends APIResource {
1616
* const listResponseNode = await client.nodes.create({
1717
* desired_count: 1,
1818
* max_price_per_node_hour: 1000,
19-
* zone: 'hayesvalley',
2019
* });
2120
* ```
2221
*/
@@ -119,9 +118,9 @@ export interface CreateNodesRequest {
119118
max_price_per_node_hour: number;
120119

121120
/**
122-
* Zone to create the nodes in
121+
* Allow auto reserved nodes to be created in any zone that meets the requirements
123122
*/
124-
zone: string;
123+
any_zone?: boolean;
125124

126125
/**
127126
* User script to be executed during the VM's boot process Data should be base64
@@ -154,6 +153,12 @@ export interface CreateNodesRequest {
154153
* provided, defaults to now
155154
*/
156155
start_at?: number;
156+
157+
/**
158+
* Zone to create the nodes in. Required for auto reserved nodes if any_zone is
159+
* false.
160+
*/
161+
zone?: string;
157162
}
158163

159164
export interface ErrorContent {
@@ -293,6 +298,8 @@ export namespace ListResponseNode {
293298

294299
updated_at: number;
295300

301+
zone: string;
302+
296303
image_id?: string | null;
297304
}
298305

@@ -318,6 +325,8 @@ export namespace ListResponseNode {
318325

319326
updated_at: number;
320327

328+
zone: string;
329+
321330
image_id?: string | null;
322331
}
323332
}
@@ -397,6 +406,8 @@ export namespace Node {
397406

398407
updated_at: number;
399408

409+
zone: string;
410+
400411
image_id?: string | null;
401412
}
402413

@@ -422,6 +433,8 @@ export namespace Node {
422433

423434
updated_at: number;
424435

436+
zone: string;
437+
425438
image_id?: string | null;
426439
}
427440
}
@@ -451,9 +464,9 @@ export interface NodeCreateParams {
451464
max_price_per_node_hour: number;
452465

453466
/**
454-
* Zone to create the nodes in
467+
* Allow auto reserved nodes to be created in any zone that meets the requirements
455468
*/
456-
zone: string;
469+
any_zone?: boolean;
457470

458471
/**
459472
* User script to be executed during the VM's boot process Data should be base64
@@ -486,6 +499,12 @@ export interface NodeCreateParams {
486499
* provided, defaults to now
487500
*/
488501
start_at?: number;
502+
503+
/**
504+
* Zone to create the nodes in. Required for auto reserved nodes if any_zone is
505+
* false.
506+
*/
507+
zone?: string;
489508
}
490509

491510
export interface NodeListParams {

src/version.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export const VERSION = '0.1.0-alpha.26'; // x-release-please-version
1+
export const VERSION = '0.1.0-alpha.27'; // x-release-please-version

tests/api-resources/nodes.test.ts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,7 @@ const client = new SFCNodes({
1010
describe('resource nodes', () => {
1111
// Prism tests are disabled
1212
test.skip('create: only required params', async () => {
13-
const responsePromise = client.nodes.create({
14-
desired_count: 1,
15-
max_price_per_node_hour: 1000,
16-
zone: 'hayesvalley',
17-
});
13+
const responsePromise = client.nodes.create({ desired_count: 1, max_price_per_node_hour: 1000 });
1814
const rawResponse = await responsePromise.asResponse();
1915
expect(rawResponse).toBeInstanceOf(Response);
2016
const response = await responsePromise;
@@ -29,13 +25,14 @@ describe('resource nodes', () => {
2925
const response = await client.nodes.create({
3026
desired_count: 1,
3127
max_price_per_node_hour: 1000,
32-
zone: 'hayesvalley',
28+
any_zone: false,
3329
cloud_init_user_data: 'aGVsbG8gd29ybGQ=',
3430
end_at: 0,
3531
image_id: 'vmi_1234567890abcdef',
3632
names: ['cuda-crunch'],
3733
node_type: 'autoreserved',
3834
start_at: 1640995200,
35+
zone: 'hayesvalley',
3936
});
4037
});
4138

0 commit comments

Comments
 (0)