@consciousclouds/admin-sdk 0.1.4 → 0.1.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.
- package/dist/generated/contract-types.d.ts +1 -1
- package/dist/index.d.ts +13 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +13 -8
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* The body of GET /personality-envelope/{productId}/{personalityId} — a Personality's EFFECTIVE AUTHORITY, re-derived live and uncached at read time: the cutover state and the owning product's enrollment grants are read fresh on every call, while the personality DECLARATION baseline is the one loaded at boot and is not re-read until the service restarts. It is a snapshot of a computation, never stored state. It carries only the Personality/consent HALF of the authority envelope: the re-proven initiating actor and the immutable Operation bounds are deliberately elsewhere. A lawful refusal (post-cutover, or no file authority) is DATA, not an error — it arrives as a 200 carrying the reason, with every dimension empty.
|
|
2
|
+
* The body of GET /personality-envelope/{productId}/{personalityId} — a Personality's EFFECTIVE AUTHORITY, re-derived live and uncached at read time: the cutover state and the owning product's enrollment grants are read fresh on every call, while the personality DECLARATION baseline is the one loaded at boot and is not re-read until the service restarts. It is a snapshot of a computation, never stored state. It carries only the Personality/consent HALF of the authority envelope: the re-proven initiating actor and the immutable Operation bounds are deliberately elsewhere. A lawful refusal (post-cutover, or no file authority) is DATA, not an error — it arrives as a 200 carrying the reason, with every dimension empty. THE TWO STATES ARE EXCLUSIVE AND EXHAUSTIVE (oneOf): a body is either Computed (mode names an authority, refusal empty) or Refused (refusal names a reason, mode empty, every dimension empty). An earlier version expressed this as two independent if/then rules, which left a THIRD, undefined state validating — mode and refusal both empty, with populated dimensions — a body that says neither what served it nor why nothing did, while showing authority anyway.
|
|
3
3
|
*/
|
|
4
4
|
export interface AuthorityEnvelope {
|
|
5
5
|
/** The product that OWNS this Personality — echoed back from the request path, and the product whose enrollment grants were intersected in. A personality id alone is ambiguous across products, so authority is only ever answered for the owning product named here. */
|
package/dist/index.d.ts
CHANGED
|
@@ -63,15 +63,20 @@ import type { AuthorityEnvelope, EnrollmentDetail, EnrollmentList, OperativeType
|
|
|
63
63
|
/**
|
|
64
64
|
* A CONTRACT-COVERED METHOD TAKES NO TYPE PARAMETER.
|
|
65
65
|
*
|
|
66
|
-
*
|
|
67
|
-
*
|
|
68
|
-
*
|
|
69
|
-
*
|
|
70
|
-
*
|
|
71
|
-
* quietly stop meaning anything.
|
|
66
|
+
* The reads described by platform/contracts/operator-admin/v1 return the GENERATED type for their contract and
|
|
67
|
+
* deliberately expose no `<T>` escape, because a caller-supplied replacement type is exactly the defect this
|
|
68
|
+
* package was rebuilt to remove: the consumer re-declares the shape by hand, the hand-written shape drifts from
|
|
69
|
+
* the wire, and nothing objects — which is how nine divergences shipped. An override would let a consumer opt
|
|
70
|
+
* back out of the contract one call site at a time, and the contract would quietly stop meaning anything.
|
|
72
71
|
*
|
|
73
|
-
*
|
|
74
|
-
*
|
|
72
|
+
* NO COUNT IS STATED HERE ON PURPOSE. This comment used to say "six ... eight", and by the time anyone read it
|
|
73
|
+
* the answer was eight and six — a hand-maintained tally in published API documentation is wrong from the first
|
|
74
|
+
* change onward, and it is the kind of wrong a reader has no reason to doubt. The authoritative count is the
|
|
75
|
+
* contract directory itself, and the package's own test derives from it: every contract type must be the plain,
|
|
76
|
+
* non-overrideable return of some method.
|
|
77
|
+
*
|
|
78
|
+
* The remaining methods are still `<T = unknown>`. That is honest rather than lax: they declare NOTHING, so
|
|
79
|
+
* they cannot contradict the wire. They gain contracts, and lose their type parameter, when their response
|
|
75
80
|
* bodies are added to the contract home.
|
|
76
81
|
*/
|
|
77
82
|
export declare class AdminClient {
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AAKH,MAAM,WAA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*
|
|
67
|
-
* quietly stop meaning anything.
|
|
62
|
+
* The reads described by platform/contracts/operator-admin/v1 return the GENERATED type for their contract and
|
|
63
|
+
* deliberately expose no `<T>` escape, because a caller-supplied replacement type is exactly the defect this
|
|
64
|
+
* package was rebuilt to remove: the consumer re-declares the shape by hand, the hand-written shape drifts from
|
|
65
|
+
* the wire, and nothing objects — which is how nine divergences shipped. An override would let a consumer opt
|
|
66
|
+
* back out of the contract one call site at a time, and the contract would quietly stop meaning anything.
|
|
68
67
|
*
|
|
69
|
-
*
|
|
70
|
-
*
|
|
68
|
+
* NO COUNT IS STATED HERE ON PURPOSE. This comment used to say "six ... eight", and by the time anyone read it
|
|
69
|
+
* the answer was eight and six — a hand-maintained tally in published API documentation is wrong from the first
|
|
70
|
+
* change onward, and it is the kind of wrong a reader has no reason to doubt. The authoritative count is the
|
|
71
|
+
* contract directory itself, and the package's own test derives from it: every contract type must be the plain,
|
|
72
|
+
* non-overrideable return of some method.
|
|
73
|
+
*
|
|
74
|
+
* The remaining methods are still `<T = unknown>`. That is honest rather than lax: they declare NOTHING, so
|
|
75
|
+
* they cannot contradict the wire. They gain contracts, and lose their type parameter, when their response
|
|
71
76
|
* bodies are added to the contract home.
|
|
72
77
|
*/
|
|
73
78
|
export class AdminClient {
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AAEH,0GAA0G;AAC1G,MAAM,IAAI,GAAG,wBAAwB,CAAC;AAWtC;;;;;;;GAOG;AACH,MAAM,OAAO,UAAW,SAAQ,KAAK;IAInC,YAAY,MAAc,EAAE,IAAY,EAAE,MAAc;QACtD,KAAK,CAAC,cAAc,MAAM,IAAI,IAAI,MAAM,MAAM,EAAE,CAAC,CAAC;QAClD,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC;QACzB,IAAI,CAAC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;IAED,gEAAgE;IAChE,WAAW,CAAc,UAAkB;QACzC,OAAO,IAAI,CAAC,OAAO,CAAI,KAAK,EAAE,GAAG,IAAI,cAAc,kBAAkB,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;IACvF,CAAC;IAED;;;;;;OAMG;IACH,kBAAkB,CAAC,SAAiB;QAClC,OAAO,IAAI,CAAC,OAAO,CACjB,KAAK,EACL,GAAG,IAAI,+BAA+B,kBAAkB,CAAC,SAAS,CAAC,EAAE,CACtE,CAAC;IACJ,CAAC;IAED,wDAAwD;IACxD,gBAAgB,CAAC,SAAiB,EAAE,WAAmB;QACrD,OAAO,IAAI,CAAC,OAAO,CACjB,KAAK,EACL,GAAG,IAAI,mBAAmB,kBAAkB,CAAC,SAAS,CAAC,IAAI,kBAAkB,CAAC,WAAW,CAAC,EAAE,CAC7F,CAAC;IACJ,CAAC;CACF;AAED,4EAA4E;AAC5E,MAAM,UAAU,iBAAiB,CAAC,OAA2B;IAC3D,OAAO,IAAI,WAAW,CAAC,OAAO,CAAC,CAAC;AAClC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@consciousclouds/admin-sdk",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.5",
|
|
4
4
|
"description": "ConsciousClouds Universal Admin SDK \u2014 the thin, policy-free client for the Operator Gateway's governance reads: Projects/enrollment, Personalities and their governed records, effective authority envelopes, and Operative Type rosters. Types + HTTP wrappers only; every authorization decision belongs to the Operator Gateway and the Control Plane.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|