@narrative.io/data-collaboration-sdk-ts 4.3.0 → 4.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.
@@ -38,10 +38,11 @@ export interface SnowflakePlatform {
38
38
  account_name: string;
39
39
  organization_name: string;
40
40
  /**
41
- * Optional: the platform can fail to parse a region when provisioning the
42
- * Snowflake Native App. Informational only.
41
+ * The platform can fail to parse a region when provisioning the Snowflake
42
+ * Native App, so this is informational only. Responses always carry the key,
43
+ * with an explicit `null` when there is no region.
43
44
  */
44
- region?: DataPlaneRegion;
45
+ region?: DataPlaneRegion | null;
45
46
  }
46
47
  /** Platform details returned for a data plane the calling company owns. */
47
48
  export type DataPlanePlatform = AwsPlatform | SnowflakePlatform;
@@ -51,7 +52,8 @@ export interface AwsSharedPlatform {
51
52
  }
52
53
  export interface SnowflakeSharedPlatform {
53
54
  type: "platform_shared_snowflake";
54
- region?: DataPlaneRegion;
55
+ /** Nullable for the same reason as {@link SnowflakePlatform.region}. */
56
+ region?: DataPlaneRegion | null;
55
57
  }
56
58
  /**
57
59
  * Platform details returned for a data plane shared with you. Account
@@ -84,11 +86,21 @@ export interface DataPlaneOwnedResponse {
84
86
  status: DataPlaneStatus;
85
87
  updated_at: string;
86
88
  collaborators: DataPlaneCollaborators;
89
+ /**
90
+ * Always present, empty when the plane has no pools: the backend field is a
91
+ * plain `List`, never an `Option`.
92
+ */
87
93
  compute_pools: ComputePoolResponse[];
88
- description?: string;
89
- tags?: string[];
90
- last_heartbeat_at?: string;
91
- default_compute_pool_id?: string;
94
+ /**
95
+ * The response encoder does not drop nulls, so each of these four arrives as
96
+ * an explicit `null` when absent rather than being left out. `tags` is `null`
97
+ * for a plane with no tags too — `DataPlaneResponse.apply` maps an empty list
98
+ * to `None` — though a directly constructed response can still send `[]`.
99
+ */
100
+ description?: string | null;
101
+ tags?: string[] | null;
102
+ last_heartbeat_at?: string | null;
103
+ default_compute_pool_id?: string | null;
92
104
  }
93
105
  /**
94
106
  * A data plane shared with the calling company. Omits details like the external
@@ -104,11 +116,13 @@ export interface DataPlaneSharedResponse {
104
116
  platform: DataPlaneSharedPlatform;
105
117
  status: DataPlaneStatus;
106
118
  updated_at: string;
119
+ /** Required for the same reason as {@link DataPlaneOwnedResponse.compute_pools}. */
107
120
  compute_pools: ComputePoolResponse[];
108
- description?: string;
109
- tags?: string[];
110
- last_heartbeat_at?: string;
111
- default_compute_pool_id?: string;
121
+ /** Nullable for the same reason as on {@link DataPlaneOwnedResponse}. */
122
+ description?: string | null;
123
+ tags?: string[] | null;
124
+ last_heartbeat_at?: string | null;
125
+ default_compute_pool_id?: string | null;
112
126
  }
113
127
  /** Discriminated union of the owned/shared data plane response shapes. */
114
128
  export type DataPlane = DataPlaneOwnedResponse | DataPlaneSharedResponse;
@@ -2,7 +2,7 @@
2
2
  * GENERATED FILE — DO NOT EDIT.
3
3
  *
4
4
  * Source: https://docs-cdn.narrative.io/api-reference/main/openapi.json
5
- * Spec etag: W/"2579229b75ddefef951659560f71d465"
5
+ * Spec etag: W/"1b05b0fe6188a5d59c67bbde3678af08"
6
6
  *
7
7
  * Regenerate with: bun run generate:api-types
8
8
  */
@@ -24249,15 +24249,54 @@ export interface components {
24249
24249
  provider?: components["schemas"]["Provider"];
24250
24250
  collaborators?: components["schemas"]["ComputePoolCollaborators"];
24251
24251
  };
24252
+ AwsRegion: {
24253
+ /**
24254
+ * @description discriminator enum property added by openapi-typescript
24255
+ * @enum {string}
24256
+ */
24257
+ type: "region_aws";
24258
+ /** @description AWS region identifier, e.g. `us-east-1`. */
24259
+ id: string;
24260
+ };
24252
24261
  AwsPlatform: {
24253
- /** @enum {string} */
24262
+ /**
24263
+ * @description discriminator enum property added by openapi-typescript
24264
+ * @enum {string}
24265
+ */
24254
24266
  type: "platform_aws";
24255
- region: string;
24267
+ /** @description The 12-digit AWS account ID of the account hosting the data plane. */
24268
+ account_id: string;
24269
+ region: components["schemas"]["AwsRegion"];
24256
24270
  };
24271
+ AzureRegion: {
24272
+ /**
24273
+ * @description discriminator enum property added by openapi-typescript
24274
+ * @enum {string}
24275
+ */
24276
+ type: "region_azure";
24277
+ /** @description Azure region identifier, e.g. `uaenorth`. */
24278
+ id: string;
24279
+ };
24280
+ GcpRegion: {
24281
+ /**
24282
+ * @description discriminator enum property added by openapi-typescript
24283
+ * @enum {string}
24284
+ */
24285
+ type: "region_gcp";
24286
+ /** @description GCP region identifier, e.g. `us-east4`. */
24287
+ id: string;
24288
+ };
24289
+ Region: components["schemas"]["AwsRegion"] | components["schemas"]["AzureRegion"] | components["schemas"]["GcpRegion"];
24257
24290
  SnowflakePlatform: {
24258
- /** @enum {string} */
24291
+ /**
24292
+ * @description discriminator enum property added by openapi-typescript
24293
+ * @enum {string}
24294
+ */
24259
24295
  type: "platform_snowflake";
24260
- region?: string;
24296
+ account_locator: string;
24297
+ account_name: string;
24298
+ organization_name: string;
24299
+ region?: components["schemas"]["Region"] | null;
24261
24300
  };
24262
24301
  Platform: components["schemas"]["AwsPlatform"] | components["schemas"]["SnowflakePlatform"];
24263
24302
  "data-plane-collaborators_ParticipantsAll": {
@@ -24274,7 +24313,7 @@ export interface components {
24274
24313
  */
24275
24314
  type: "none";
24276
24315
  };
24277
- "data-plane-collaborators_CompanyId": string;
24316
+ "data-plane-collaborators_CompanyId": number;
24278
24317
  "data-plane-collaborators_ParticipantsInclusion": {
24279
24318
  /**
24280
24319
  * @description discriminator enum property added by openapi-typescript
@@ -24297,60 +24336,73 @@ export interface components {
24297
24336
  manage_compute_pools: components["schemas"]["DataPlaneParticipants"];
24298
24337
  };
24299
24338
  DataPlaneOwnedResponse: {
24300
- /** @enum {string} */
24339
+ /**
24340
+ * @description discriminator enum property added by openapi-typescript
24341
+ * @enum {string}
24342
+ */
24301
24343
  type: "owned";
24302
24344
  /** Format: uuid */
24303
24345
  id: string;
24304
24346
  company_id: number;
24305
24347
  /** Format: date-time */
24306
24348
  created_at: string;
24307
- description?: string;
24349
+ description?: string | null;
24308
24350
  display_name: string;
24309
24351
  external_id: string;
24310
24352
  platform: components["schemas"]["Platform"];
24311
24353
  /** @enum {string} */
24312
24354
  status: "active" | "archived";
24313
24355
  /** Format: date-time */
24314
- last_heartbeat_at?: string;
24315
- tags?: string[];
24356
+ last_heartbeat_at?: string | null;
24357
+ tags?: string[] | null;
24316
24358
  /** Format: date-time */
24317
24359
  updated_at: string;
24318
24360
  collaborators: components["schemas"]["DataPlaneCollaborators"];
24319
24361
  /** Format: uuid */
24320
- default_compute_pool_id?: string;
24321
- compute_pools?: components["schemas"]["ComputePoolResponse"][];
24362
+ default_compute_pool_id?: string | null;
24363
+ compute_pools: components["schemas"]["ComputePoolResponse"][];
24322
24364
  };
24323
24365
  AwsSharedResponse: {
24324
- /** @enum {string} */
24366
+ /**
24367
+ * @description discriminator enum property added by openapi-typescript
24368
+ * @enum {string}
24369
+ */
24325
24370
  type: "platform_shared_aws";
24326
- region: string;
24371
+ region: components["schemas"]["AwsRegion"];
24327
24372
  };
24328
24373
  SnowflakeSharedResponse: {
24329
- /** @enum {string} */
24374
+ /**
24375
+ * @description discriminator enum property added by openapi-typescript
24376
+ * @enum {string}
24377
+ */
24330
24378
  type: "platform_shared_snowflake";
24331
- region?: string;
24379
+ region?: components["schemas"]["Region"] | null;
24332
24380
  };
24333
24381
  PlatformSharedResponse: components["schemas"]["AwsSharedResponse"] | components["schemas"]["SnowflakeSharedResponse"];
24334
24382
  DataPlaneSharedResponse: {
24335
- /** @enum {string} */
24383
+ /**
24384
+ * @description discriminator enum property added by openapi-typescript
24385
+ * @enum {string}
24386
+ */
24336
24387
  type: "shared";
24388
+ /** Format: uuid */
24337
24389
  id: string;
24338
- company_id: string;
24390
+ company_id: number;
24339
24391
  /** Format: date-time */
24340
24392
  created_at: string;
24341
- description?: string;
24393
+ description?: string | null;
24342
24394
  display_name: string;
24343
24395
  platform: components["schemas"]["PlatformSharedResponse"];
24344
24396
  /** @enum {string} */
24345
24397
  status: "active" | "archived";
24346
24398
  /** Format: date-time */
24347
- last_heartbeat_at?: string;
24348
- tags?: string[];
24399
+ last_heartbeat_at?: string | null;
24400
+ tags?: string[] | null;
24349
24401
  /** Format: date-time */
24350
24402
  updated_at: string;
24351
24403
  /** Format: uuid */
24352
- default_compute_pool_id?: string;
24353
- compute_pools?: components["schemas"]["ComputePoolResponse"][];
24404
+ default_compute_pool_id?: string | null;
24405
+ compute_pools: components["schemas"]["ComputePoolResponse"][];
24354
24406
  };
24355
24407
  DataPlaneResponse: components["schemas"]["DataPlaneOwnedResponse"] | components["schemas"]["DataPlaneSharedResponse"];
24356
24408
  GetDataPlanesResponse: {
@@ -2,7 +2,7 @@
2
2
  * GENERATED FILE — DO NOT EDIT.
3
3
  *
4
4
  * Source: https://docs-cdn.narrative.io/api-reference/main/openapi.json
5
- * Spec etag: W/"2579229b75ddefef951659560f71d465"
5
+ * Spec etag: W/"1b05b0fe6188a5d59c67bbde3678af08"
6
6
  *
7
7
  * Regenerate with: bun run generate:api-types
8
8
  */
@@ -1,7 +1,9 @@
1
1
  import type { DataPlaneOwnedResponse, JobResponse } from "../types";
2
2
  /**
3
3
  * An owned, active data plane. Every field the spec requires is filled in, so a
4
- * caller only overrides what its assertion is about.
4
+ * caller only overrides what its assertion is about. The optional fields are
5
+ * present and `null`, which is what the API sends for an absent value — a mock
6
+ * that omitted them would let a consumer assert `undefined` and still pass.
5
7
  */
6
8
  export declare function createDataPlane(overrides?: Partial<DataPlaneOwnedResponse>): DataPlaneOwnedResponse;
7
9
  /** The job a health check enqueues, pending and not yet attempted. */
@@ -1,7 +1,9 @@
1
1
  const TIMESTAMP = "2026-01-01T00:00:00Z";
2
2
  /**
3
3
  * An owned, active data plane. Every field the spec requires is filled in, so a
4
- * caller only overrides what its assertion is about.
4
+ * caller only overrides what its assertion is about. The optional fields are
5
+ * present and `null`, which is what the API sends for an absent value — a mock
6
+ * that omitted them would let a consumer assert `undefined` and still pass.
5
7
  */
6
8
  export function createDataPlane(overrides = {}) {
7
9
  return {
@@ -11,13 +13,22 @@ export function createDataPlane(overrides = {}) {
11
13
  created_at: TIMESTAMP,
12
14
  display_name: "Test Data Plane",
13
15
  external_id: "test-data-plane",
14
- platform: { type: "platform_aws", region: "us-east-1" },
16
+ platform: {
17
+ type: "platform_aws",
18
+ account_id: "123456789000",
19
+ region: { type: "region_aws", id: "us-east-1" },
20
+ },
15
21
  status: "active",
16
22
  updated_at: TIMESTAMP,
17
23
  collaborators: {
18
24
  participants: { type: "none" },
19
25
  manage_compute_pools: { type: "none" },
20
26
  },
27
+ compute_pools: [],
28
+ description: null,
29
+ tags: null,
30
+ last_heartbeat_at: null,
31
+ default_compute_pool_id: null,
21
32
  ...overrides,
22
33
  };
23
34
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@narrative.io/data-collaboration-sdk-ts",
3
- "version": "4.3.0",
3
+ "version": "4.3.1",
4
4
  "main": "build/index.js",
5
5
  "repository": "github:narrative-io/data-collaboration-sdk-ts",
6
6
  "source": "src/index.ts",