@xemahq/space-registry-api-client 0.1.1 → 0.2.0

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/LICENSE CHANGED
@@ -9,7 +9,7 @@ Parameters
9
9
 
10
10
  Licensor: Neuralchowder Inc.
11
11
 
12
- Licensed Work: Xema. The Licensed Work is (c) 2026 Neuralchowder Inc..
12
+ Licensed Work: Xema. The Licensed Work is (c) 2026 Neuralchowder Inc.
13
13
 
14
14
  The Licensed Work includes, without limitation, Xema Core, Xema Runtime,
15
15
  Xema Kernel, Xema control plane, Xema application runtime, Xema biome
@@ -116,6 +116,7 @@ the interpretation of, the Additional Use Grant set out above.
116
116
  and effect. The Licensor reserves all rights not expressly granted
117
117
  by this License.
118
118
 
119
+
119
120
  Change Date: Four years from the date the specific version of the Licensed
120
121
  Work is first publicly released by Licensor.
121
122
 
@@ -5,37 +5,41 @@
5
5
  * Authoritative Space ownership + data-classification plane: Space CRUD, hierarchy, and most-specific-wins classification resolution.
6
6
  * OpenAPI spec version: 0.1.0
7
7
  */
8
- import type { CreateSpaceDto, SpaceAncestorsDto, SpaceClassificationDto, SpaceDto, SpacesControllerAncestorsParams, SpacesControllerClassificationParams, SpacesControllerListParams, SpacesControllerResolveParams, UpdateClassificationDto } from '../../models';
8
+ import type { CreateSpaceDto, SpaceAncestorsDtoDataEnvelope, SpaceClassificationDtoDataEnvelope, SpaceDtoDataArrayEnvelope, SpaceDtoDataEnvelope, SpacesControllerAncestorsParams, SpacesControllerClassificationParams, SpacesControllerListParams, SpacesControllerResolveParams, UpdateClassificationDto } from '../../models';
9
9
  export declare const getSpacesControllerCreateUrl: () => string;
10
10
  /**
11
11
  * @summary Create a Space (idempotent on its canonical refUri).
12
12
  */
13
- export declare const spacesControllerCreate: (createSpaceDto: CreateSpaceDto, options?: RequestInit) => Promise<SpaceDto>;
13
+ export declare const spacesControllerCreate: (createSpaceDto: CreateSpaceDto, options?: RequestInit) => Promise<SpaceDtoDataEnvelope>;
14
14
  export declare const getSpacesControllerListUrl: (params?: SpacesControllerListParams) => string;
15
15
  /**
16
16
  * @summary List the caller org's Spaces (newest first). Org-less System Spaces are not enumerated here.
17
17
  */
18
- export declare const spacesControllerList: (params?: SpacesControllerListParams, options?: RequestInit) => Promise<SpaceDto[]>;
18
+ export declare const spacesControllerList: (params?: SpacesControllerListParams, options?: RequestInit) => Promise<SpaceDtoDataArrayEnvelope>;
19
19
  export declare const getSpacesControllerResolveUrl: (params: SpacesControllerResolveParams) => string;
20
20
  /**
21
+ * The organization is selected through the X-Xema-Org-Id request context, NOT through the ref. A ref naming a different organization is refused with 403 SPACE_CROSS_ORG_ACCESS_FORBIDDEN — never silently preferred. Org-less refs (xema://system, xema://biomes/<id>, xema://users/<id>, xema://sessions/<id>) are platform-global and remain readable by every authenticated caller.
21
22
  * @summary Resolve a Space by its xema:// URI.
22
23
  */
23
- export declare const spacesControllerResolve: (params: SpacesControllerResolveParams, options?: RequestInit) => Promise<SpaceDto>;
24
+ export declare const spacesControllerResolve: (params: SpacesControllerResolveParams, options?: RequestInit) => Promise<SpaceDtoDataEnvelope>;
24
25
  export declare const getSpacesControllerAncestorsUrl: (params: SpacesControllerAncestorsParams) => string;
25
26
  /**
27
+ * Same tenant rule as /spaces/resolve: the ref is fenced against the request-context organization. The org-less System tail of the chain is returned for every caller — it is what carries the inherited classification floor.
26
28
  * @summary Persisted ancestor chain (closest-first, self at index 0) up to System.
27
29
  */
28
- export declare const spacesControllerAncestors: (params: SpacesControllerAncestorsParams, options?: RequestInit) => Promise<SpaceAncestorsDto>;
30
+ export declare const spacesControllerAncestors: (params: SpacesControllerAncestorsParams, options?: RequestInit) => Promise<SpaceAncestorsDtoDataEnvelope>;
29
31
  export declare const getSpacesControllerClassificationUrl: (params: SpacesControllerClassificationParams) => string;
30
32
  /**
33
+ * Same tenant rule as /spaces/resolve. A data-classification label is exactly the kind of metadata a cross-tenant read must not expose, so a ref naming another organization is refused with 403.
31
34
  * @summary Resolve effective (most-specific-wins) classification over the ancestry.
32
35
  */
33
- export declare const spacesControllerClassification: (params: SpacesControllerClassificationParams, options?: RequestInit) => Promise<SpaceClassificationDto>;
36
+ export declare const spacesControllerClassification: (params: SpacesControllerClassificationParams, options?: RequestInit) => Promise<SpaceClassificationDtoDataEnvelope>;
34
37
  export declare const getSpacesControllerGetByIdUrl: (id: string) => string;
35
38
  /**
39
+ * A Space owned by another organization returns the SAME 404 as an unknown id — an opaque id names no tenant, so a distinct 403 would make this route a cross-tenant existence oracle.
36
40
  * @summary Fetch a Space by opaque id.
37
41
  */
38
- export declare const spacesControllerGetById: (id: string, options?: RequestInit) => Promise<SpaceDto>;
42
+ export declare const spacesControllerGetById: (id: string, options?: RequestInit) => Promise<SpaceDtoDataEnvelope>;
39
43
  export declare const getSpacesControllerRemoveUrl: (id: string) => string;
40
44
  /**
41
45
  * @summary Delete a Space by id. Refuses system-managed Spaces and Spaces that still have children (fail-fast).
@@ -45,4 +49,4 @@ export declare const getSpacesControllerSetClassificationUrl: (id: string) => st
45
49
  /**
46
50
  * @summary Set/change a Space's own classification. Downgrades require allowDowngrade and are audited.
47
51
  */
48
- export declare const spacesControllerSetClassification: (id: string, updateClassificationDto: UpdateClassificationDto, options?: RequestInit) => Promise<SpaceDto>;
52
+ export declare const spacesControllerSetClassification: (id: string, updateClassificationDto: UpdateClassificationDto, options?: RequestInit) => Promise<SpaceDtoDataEnvelope>;
@@ -75,6 +75,7 @@ const getSpacesControllerResolveUrl = (params) => {
75
75
  };
76
76
  exports.getSpacesControllerResolveUrl = getSpacesControllerResolveUrl;
77
77
  /**
78
+ * The organization is selected through the X-Xema-Org-Id request context, NOT through the ref. A ref naming a different organization is refused with 403 SPACE_CROSS_ORG_ACCESS_FORBIDDEN — never silently preferred. Org-less refs (xema://system, xema://biomes/<id>, xema://users/<id>, xema://sessions/<id>) are platform-global and remain readable by every authenticated caller.
78
79
  * @summary Resolve a Space by its xema:// URI.
79
80
  */
80
81
  const spacesControllerResolve = async (params, options) => {
@@ -108,6 +109,7 @@ const getSpacesControllerAncestorsUrl = (params) => {
108
109
  };
109
110
  exports.getSpacesControllerAncestorsUrl = getSpacesControllerAncestorsUrl;
110
111
  /**
112
+ * Same tenant rule as /spaces/resolve: the ref is fenced against the request-context organization. The org-less System tail of the chain is returned for every caller — it is what carries the inherited classification floor.
111
113
  * @summary Persisted ancestor chain (closest-first, self at index 0) up to System.
112
114
  */
113
115
  const spacesControllerAncestors = async (params, options) => {
@@ -141,6 +143,7 @@ const getSpacesControllerClassificationUrl = (params) => {
141
143
  };
142
144
  exports.getSpacesControllerClassificationUrl = getSpacesControllerClassificationUrl;
143
145
  /**
146
+ * Same tenant rule as /spaces/resolve. A data-classification label is exactly the kind of metadata a cross-tenant read must not expose, so a ref naming another organization is refused with 403.
144
147
  * @summary Resolve effective (most-specific-wins) classification over the ancestry.
145
148
  */
146
149
  const spacesControllerClassification = async (params, options) => {
@@ -155,6 +158,7 @@ const getSpacesControllerGetByIdUrl = (id) => {
155
158
  };
156
159
  exports.getSpacesControllerGetByIdUrl = getSpacesControllerGetByIdUrl;
157
160
  /**
161
+ * A Space owned by another organization returns the SAME 404 as an unknown id — an opaque id names no tenant, so a distinct 403 would make this route a cross-tenant existence oracle.
158
162
  * @summary Fetch a Space by opaque id.
159
163
  */
160
164
  const spacesControllerGetById = async (id, options) => {
@@ -6,7 +6,7 @@
6
6
  * OpenAPI spec version: 0.1.0
7
7
  */
8
8
  /**
9
- * Own data classification. MUST be >= the parent floor unless allowClassificationBelowParent is set.
9
+ * Own classification, if explicitly set on this Space.
10
10
  */
11
11
  export type DataClassification = typeof DataClassification[keyof typeof DataClassification];
12
12
  export declare const DataClassification: {
@@ -2,11 +2,15 @@ export * from './createSpaceDto';
2
2
  export * from './createSpaceDtoLabels';
3
3
  export * from './dataClassification';
4
4
  export * from './spaceAncestorsDto';
5
+ export * from './spaceAncestorsDtoDataEnvelope';
5
6
  export * from './spaceClassificationDto';
7
+ export * from './spaceClassificationDtoDataEnvelope';
6
8
  export * from './spaceClassificationDtoResolvedFromRefUri';
7
9
  export * from './spaceDto';
8
10
  export * from './spaceDtoAppId';
9
11
  export * from './spaceDtoBiomeId';
12
+ export * from './spaceDtoDataArrayEnvelope';
13
+ export * from './spaceDtoDataEnvelope';
10
14
  export * from './spaceDtoLabels';
11
15
  export * from './spaceDtoOrgId';
12
16
  export * from './spaceDtoParentId';
@@ -19,11 +19,15 @@ __exportStar(require("./createSpaceDto"), exports);
19
19
  __exportStar(require("./createSpaceDtoLabels"), exports);
20
20
  __exportStar(require("./dataClassification"), exports);
21
21
  __exportStar(require("./spaceAncestorsDto"), exports);
22
+ __exportStar(require("./spaceAncestorsDtoDataEnvelope"), exports);
22
23
  __exportStar(require("./spaceClassificationDto"), exports);
24
+ __exportStar(require("./spaceClassificationDtoDataEnvelope"), exports);
23
25
  __exportStar(require("./spaceClassificationDtoResolvedFromRefUri"), exports);
24
26
  __exportStar(require("./spaceDto"), exports);
25
27
  __exportStar(require("./spaceDtoAppId"), exports);
26
28
  __exportStar(require("./spaceDtoBiomeId"), exports);
29
+ __exportStar(require("./spaceDtoDataArrayEnvelope"), exports);
30
+ __exportStar(require("./spaceDtoDataEnvelope"), exports);
27
31
  __exportStar(require("./spaceDtoLabels"), exports);
28
32
  __exportStar(require("./spaceDtoOrgId"), exports);
29
33
  __exportStar(require("./spaceDtoParentId"), exports);
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Generated by orval v8.16.0 🍺
3
+ * Do not edit manually.
4
+ * Space Registry API
5
+ * Authoritative Space ownership + data-classification plane: Space CRUD, hierarchy, and most-specific-wins classification resolution.
6
+ * OpenAPI spec version: 0.1.0
7
+ */
8
+ import type { SpaceAncestorsDto } from './spaceAncestorsDto.js';
9
+ export interface SpaceAncestorsDtoDataEnvelope {
10
+ data: SpaceAncestorsDto;
11
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Generated by orval v8.16.0 🍺
3
+ * Do not edit manually.
4
+ * Space Registry API
5
+ * Authoritative Space ownership + data-classification plane: Space CRUD, hierarchy, and most-specific-wins classification resolution.
6
+ * OpenAPI spec version: 0.1.0
7
+ */
8
+ import type { SpaceClassificationDto } from './spaceClassificationDto.js';
9
+ export interface SpaceClassificationDtoDataEnvelope {
10
+ data: SpaceClassificationDto;
11
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Generated by orval v8.16.0 🍺
3
+ * Do not edit manually.
4
+ * Space Registry API
5
+ * Authoritative Space ownership + data-classification plane: Space CRUD, hierarchy, and most-specific-wins classification resolution.
6
+ * OpenAPI spec version: 0.1.0
7
+ */
8
+ import type { SpaceDto } from './spaceDto.js';
9
+ export interface SpaceDtoDataArrayEnvelope {
10
+ data: SpaceDto[];
11
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Generated by orval v8.16.0 🍺
3
+ * Do not edit manually.
4
+ * Space Registry API
5
+ * Authoritative Space ownership + data-classification plane: Space CRUD, hierarchy, and most-specific-wins classification resolution.
6
+ * OpenAPI spec version: 0.1.0
7
+ */
8
+ import type { SpaceDto } from './spaceDto.js';
9
+ export interface SpaceDtoDataEnvelope {
10
+ data: SpaceDto;
11
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
package/package.json CHANGED
@@ -1,14 +1,14 @@
1
1
  {
2
2
  "name": "@xemahq/space-registry-api-client",
3
- "version": "0.1.1",
3
+ "version": "0.2.0",
4
4
  "main": "./dist/index.js",
5
5
  "types": "./dist/index.d.ts",
6
6
  "files": [
7
7
  "dist"
8
8
  ],
9
9
  "publishConfig": {
10
- "registry": "https://registry.npmjs.org/",
11
- "access": "public"
10
+ "access": "public",
11
+ "registry": "https://registry.npmjs.org/"
12
12
  },
13
13
  "devDependencies": {
14
14
  "typescript": "5.9.3"
@@ -19,7 +19,7 @@
19
19
  "service": "space-registry-api",
20
20
  "biome": "space-registry",
21
21
  "target": "server",
22
- "generator": "@xemahq/api-client-generator@0.1.2",
22
+ "generator": "@xemahq/api-client-generator@0.2.0",
23
23
  "source": "openapi.public.json"
24
24
  },
25
25
  "license": "LicenseRef-Xema-BSL-1.1",
@@ -28,7 +28,7 @@
28
28
  "bugs": "https://github.com/xema-dev/xema-community/issues",
29
29
  "repository": {
30
30
  "type": "git",
31
- "url": "git+https://github.com/xema-dev/xema-community.git",
31
+ "url": "git+https://github.com/xema-dev/xema-base.git",
32
32
  "directory": "packages/clients/space-registry-api"
33
33
  },
34
34
  "description": "Generated public API client for the Xema space-registry-api service.",