@oddington/sdk 0.1.76 → 0.1.78

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
@@ -60,6 +60,15 @@ Inbox File previews and downloads use package-root `files.read(fileId)` with
60
60
  current workspace access. Item visibility does not grant File access. The SDK
61
61
  exposes no raw-credential API.
62
62
 
63
+ The first-party hosted Inbox uses `inbox.bootstrap()` for all visible items and
64
+ revision-associated authored Record hydration. `inbox.subscribe(onDirty,
65
+ onState)` returns an idempotent cleanup function. Dirty callbacks have no
66
+ arguments; state callbacks report `connected` (including reconnects),
67
+ `unavailable` (retryable), or `denied` (terminal). Treat hints as reasons for a
68
+ coalesced authoritative bootstrap read. Provider transport, scoped credentials,
69
+ renewal and reconnect remain inside the SDK. Focused and local apps cannot use
70
+ this complete-Inbox subscription.
71
+
63
72
  Apps use `inbox.questions.list({ routines })` for `QuestionWork[]`.
64
73
  Derive `routines` from `(await app.listRoutines()).map(({ id }) => id)`.
65
74
  These canonical names narrow relevance only; they grant no answer or
@@ -283,6 +292,7 @@ import { defineResponse, respond, resolveAsk } from '@oddington/sdk';
283
292
  // List this action in the owning defineRoutine({ responses: [setStatus], access, ... }).
284
293
  // The routine's single access declaration governs both its run and its actions.
285
294
  const setStatus = defineResponse<{ recordRef: string; status: string }>({ id: 'set-status', async run({ input }, os) {
295
+ await os.action.progress({ label: 'Updating the record' });
286
296
  const changes = os.data.repository('general').changes();
287
297
  changes.update(input.recordRef, { status: input.status });
288
298
  await changes.publish();
@@ -291,6 +301,11 @@ const setStatus = defineResponse<{ recordRef: string; status: string }>({ id: 's
291
301
  // Attach to a published Question with handler: respond(setStatus, { recordRef, status: 'complete' }).
292
302
  ```
293
303
 
304
+ `action.progress` replaces the Inbox's generic invoking copy while this action
305
+ is running. Use concise customer-facing text for meaningful waits. It does not
306
+ create timeline events, counted steps or a completion estimate; the next label
307
+ replaces it and the platform clears it when recording the outcome.
308
+
294
309
  The SDK owns browser provider setup, email/passcode actions, persisted restoration,
295
310
  refresh and expiry. Create one opaque handle outside rendering and bind the app's
296
311
  presentation to its state: