@cortexkit/claustrum-client 0.6.1 → 0.6.2

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/README.md CHANGED
@@ -23,6 +23,11 @@ credential caching, refresh, account scheduling, and retry policy.
23
23
  as a version older than every real one.
24
24
  • Unknown server error classes are bounded to `transient`; callers must retry them
25
25
  rather than treating a forward-compatible class as permanent.
26
+ • `listScoped` rows always carry `providerIds` (a required field since 0.6.0, so code
27
+ that builds rows by hand, such as test fixtures, must set it). An empty array means
28
+ no provider ids are set. Since 0.6.2 a daemon too old to send the field decodes the
29
+ same way, so a newer client still lists against an older daemon. `authMethod` stays
30
+ optional.
26
31
 
27
32
  The client sends `consumerIdentity: null` for every managed request so inherited
28
33
  `SUBC_MODULE_ID` and `SUBC_LAUNCH_NONCE` cannot impersonate a supervising host.
package/dist/wire.d.ts CHANGED
@@ -206,7 +206,11 @@ export interface ScopedInventoryRow {
206
206
  readonly categories: readonly string[];
207
207
  readonly credentialType: string;
208
208
  readonly serves: readonly string[];
209
- /** Operator-assigned catalog ids, always present, including an empty set. */
209
+ /**
210
+ * Operator-assigned catalog ids; empty when none are set. Always present on this type.
211
+ * A daemon older than the field omits it from the wire, and that decodes as empty,
212
+ * which is also what an unmapped credential reports.
213
+ */
210
214
  readonly providerIds: readonly string[];
211
215
  readonly authMethod?: 'apikey' | 'chatgpt' | 'antigravity' | 'oauth';
212
216
  /**
package/dist/wire.js CHANGED
@@ -418,7 +418,11 @@ export function decodeScopedInventory(response, logUnknownClass) {
418
418
  categories: strings(row.categories),
419
419
  credentialType: row.type,
420
420
  serves: strings(row.serves),
421
- providerIds: strings(row.provider_ids),
421
+ // ABSENT DECODES AS EMPTY, PRESENT MUST BE AN ARRAY. Daemons before provider ids
422
+ // existed omit the key, and refusing that would fail the whole listing against a
423
+ // still-supported daemon. Absent and empty mean the same thing to every consumer:
424
+ // no ids set. A present non-array is a malformed reply and still refuses.
425
+ providerIds: row.provider_ids === undefined ? [] : strings(row.provider_ids),
422
426
  authMethod,
423
427
  state: row.state,
424
428
  refreshAdapter: row.refresh_adapter,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cortexkit/claustrum-client",
3
- "version": "0.6.1",
3
+ "version": "0.6.2",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",