@farthershore/client 0.0.0-stage → 0.1.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.
Files changed (42) hide show
  1. package/CHANGELOG.md +34 -0
  2. package/README.md +251 -2
  3. package/dist/index.js +6997 -0
  4. package/dist/types/api.generated.d.ts +1356 -0
  5. package/dist/types/credentials.d.ts +78 -0
  6. package/dist/types/envelope.d.ts +48 -0
  7. package/dist/types/errors.d.ts +86 -0
  8. package/dist/types/helpers/abort.d.ts +7 -0
  9. package/dist/types/helpers/paginate.d.ts +32 -0
  10. package/dist/types/helpers/poll.d.ts +26 -0
  11. package/dist/types/helpers/refs.d.ts +84 -0
  12. package/dist/types/helpers/wait-for-frontend-build.d.ts +43 -0
  13. package/dist/types/index.d.ts +24 -0
  14. package/dist/types/operations/agents.d.ts +48 -0
  15. package/dist/types/operations/agreements.d.ts +44 -0
  16. package/dist/types/operations/analytics.d.ts +25 -0
  17. package/dist/types/operations/audit-notifications.d.ts +33 -0
  18. package/dist/types/operations/auth.d.ts +16 -0
  19. package/dist/types/operations/backends.d.ts +53 -0
  20. package/dist/types/operations/billing.d.ts +15 -0
  21. package/dist/types/operations/businesses.d.ts +92 -0
  22. package/dist/types/operations/change-sets.d.ts +43 -0
  23. package/dist/types/operations/consumers.d.ts +49 -0
  24. package/dist/types/operations/define.d.ts +91 -0
  25. package/dist/types/operations/environments.d.ts +19 -0
  26. package/dist/types/operations/frontend.d.ts +13 -0
  27. package/dist/types/operations/index.d.ts +1036 -0
  28. package/dist/types/operations/maker-tokens.d.ts +30 -0
  29. package/dist/types/operations/organizations.d.ts +71 -0
  30. package/dist/types/operations/personas.d.ts +46 -0
  31. package/dist/types/operations/plans-usage.d.ts +18 -0
  32. package/dist/types/operations/platform.d.ts +47 -0
  33. package/dist/types/operations/portal.d.ts +49 -0
  34. package/dist/types/operations/promo-codes.d.ts +19 -0
  35. package/dist/types/operations/variables.d.ts +25 -0
  36. package/dist/types/operations/webhooks.d.ts +67 -0
  37. package/dist/types/surface-types.d.ts +54 -0
  38. package/dist/types/surface.d.ts +35 -0
  39. package/dist/types/transport.d.ts +119 -0
  40. package/dist/types/types.d.ts +469 -0
  41. package/dist/types/version.d.ts +8 -0
  42. package/package.json +53 -3
@@ -0,0 +1,1356 @@
1
+ import type { Method } from "./surface-types.js";
2
+ /** The namespaced Farther Shore API (`createFartherShore`). */
3
+ export interface FartherShoreApi {
4
+ readonly agents: {
5
+ /**
6
+ * Turn the Operator off (stops runs + billing)
7
+ *
8
+ * Turn the Operator off: the dispatcher stops scheduling runs and agent-work billing stops accruing. Re-enable at any time.
9
+ *
10
+ * Operation `agents.disable` · write · requires `agent:configure` · reconcile an unknown outcome with `agents.status`.
11
+ */
12
+ readonly disable: Method<"agents.disable">;
13
+ /**
14
+ * Turn the Operator on (creates it on first enable)
15
+ *
16
+ * Turn the business's Operator agent on (created on first enable). It runs autonomously on its cadence; agent-work billing accrues while enabled.
17
+ *
18
+ * Operation `agents.enable` · write · requires `agent:configure` · reconcile an unknown outcome with `agents.status`.
19
+ */
20
+ readonly enable: Method<"agents.enable">;
21
+ /**
22
+ * List a business's operating agents + enableable roles
23
+ *
24
+ * The agent roster for a business: the enabled/disabled Operator plus any roles that can still be enabled. Read-only.
25
+ *
26
+ * Operation `agents.list` · read · requires `agent:read`.
27
+ */
28
+ readonly list: Method<"agents.list">;
29
+ readonly runs: {
30
+ /**
31
+ * One run's full paper trail: trace, launches, action receipts
32
+ *
33
+ * One run's full audit view: the orchestrator's trace summary (composed launches, verify flags, catalog changes), the per-launch performance ledger, and every platform-action receipt. Read-only.
34
+ *
35
+ * Operation `agents.runs.show` · read · requires `agent:read`.
36
+ */
37
+ readonly show: Method<"agents.runs.show">;
38
+ };
39
+ /**
40
+ * The Operator's activation state, recent runs, and usage totals
41
+ *
42
+ * The Operator's activation state, recent run history (newest-first), and lifetime usage totals (LLM tokens + actions). Read-only.
43
+ *
44
+ * Operation `agents.status` · read · requires `agent:read`.
45
+ */
46
+ readonly status: Method<"agents.status">;
47
+ };
48
+ readonly agreements: {
49
+ /**
50
+ * Amend an agreement's contract terms (append-only; previews first; commits with the confirmation token)
51
+ *
52
+ * Amend an agreement's contract terms (append-only; confirm-gated: previews first; pass --confirm <token> to commit)
53
+ *
54
+ * Operation `agreement.amend` · write · requires `agreement:amend` · reconcile an unknown outcome with `agreement.read`.
55
+ */
56
+ readonly amend: Method<"agreements.amend">;
57
+ /**
58
+ * Create an economic agreement (previews first; commits with the confirmation token)
59
+ *
60
+ * Create an economic agreement (confirm-gated: previews first; pass --confirm <token> to commit)
61
+ *
62
+ * Operation `agreement.create` · write · requires `agreement:create` · reconcile an unknown outcome with `agreement.read`.
63
+ */
64
+ readonly create: Method<"agreements.create">;
65
+ /**
66
+ * Show one economic agreement
67
+ *
68
+ * Operation `agreement.read` · read · requires `agreement:read`.
69
+ */
70
+ readonly get: Method<"agreements.get">;
71
+ /**
72
+ * Show the price pins in force for one subject
73
+ *
74
+ * Operation `agreement.read` · read · requires `agreement:read`.
75
+ */
76
+ readonly pins: Method<"agreements.pins">;
77
+ /**
78
+ * Preview an amendment's effect and get its confirmation token
79
+ *
80
+ * Operation `agreement.amend` · read · requires `agreement:amend` · reconcile an unknown outcome with `agreement.read`.
81
+ */
82
+ readonly previewAmend: Method<"agreements.previewAmend">;
83
+ /**
84
+ * Preview a new agreement's effect and get its confirmation token
85
+ *
86
+ * Operation `agreement.create` · read · requires `agreement:create` · reconcile an unknown outcome with `agreement.read`.
87
+ */
88
+ readonly previewCreate: Method<"agreements.previewCreate">;
89
+ /**
90
+ * List or show a business's economic agreements and their pins
91
+ *
92
+ * Lists a business's economic agreements, shows one agreement with its terms, and shows the agreement pins that bind subscribers to a version.
93
+ *
94
+ * Operation `agreement.read` · read · requires `agreement:read` · offset pagination.
95
+ */
96
+ readonly read: Method<"agreements.read">;
97
+ };
98
+ readonly analytics: {
99
+ /**
100
+ * Request latency percentiles (p50 / p95 / p99)
101
+ *
102
+ * Gateway request latency at p50/p95/p99 for one business. NOTE: this is the WHOLE request including the builder's own backend, so a high number is not necessarily platform overhead. Read-only.
103
+ *
104
+ * Operation `analytics.latency` · read · requires `analytics:read`.
105
+ */
106
+ readonly latency: Method<"analytics.latency">;
107
+ /**
108
+ * Recent requests — the live metering signal, newest first
109
+ *
110
+ * The most recent archived events for one business, newest first. Each row's `payload` carries the request detail (path, statusCode, latencyMs, orgId). Read-only.
111
+ *
112
+ * Operation `analytics.log` · read · requires `analytics:read`.
113
+ */
114
+ readonly log: Method<"analytics.log">;
115
+ /**
116
+ * Run any analytics DSL verb against a business's event archive
117
+ *
118
+ * No opKey · read.
119
+ */
120
+ readonly query: Method<"analytics.query">;
121
+ /**
122
+ * Request (or denial) volume over time
123
+ *
124
+ * Event volume bucketed over time for one business, from the event archive. Read-only. Scoped to production unless environmentId is given.
125
+ *
126
+ * Operation `analytics.timeseries` · read · requires `analytics:read`.
127
+ */
128
+ readonly timeseries: Method<"analytics.timeseries">;
129
+ /**
130
+ * Top callers / event types / environments by volume
131
+ *
132
+ * Ranked breakdown of archive events by caller, event type, or environment. Read-only.
133
+ *
134
+ * Operation `analytics.top` · read · requires `analytics:read`.
135
+ */
136
+ readonly top: Method<"analytics.top">;
137
+ };
138
+ readonly auditLogs: {
139
+ readonly business: {
140
+ /**
141
+ * Export one business's audit logs as CSV
142
+ *
143
+ * Operation `audit_log.business.export` · read · requires `audit_log:export`.
144
+ */
145
+ readonly export: Method<"auditLogs.business.export">;
146
+ /**
147
+ * List one business's audit-log rows
148
+ *
149
+ * Operation `audit_log.business.read` · read · requires `audit_log:read` · cursor pagination.
150
+ */
151
+ readonly read: Method<"auditLogs.business.read">;
152
+ };
153
+ /**
154
+ * Export organization or business-scoped audit logs as CSV
155
+ *
156
+ * Operation `audit_log.export` · read · requires `audit_log:export`.
157
+ */
158
+ readonly export: Method<"auditLogs.export">;
159
+ /**
160
+ * List organization or business-scoped audit-log rows
161
+ *
162
+ * Operation `audit_log.read` · read · requires `audit_log:read` · cursor pagination.
163
+ */
164
+ readonly read: Method<"auditLogs.read">;
165
+ };
166
+ readonly auth: {
167
+ readonly context: {
168
+ /**
169
+ * Issue a short-lived gateway context token for a subscriber member
170
+ *
171
+ * Operation `auth.context.issue` · write · requires `auth_context:issue` · returns a one-time secret.
172
+ */
173
+ readonly issue: Method<"auth.context.issue">;
174
+ /**
175
+ * Read the authenticated caller's identity and runtime context
176
+ *
177
+ * Returns metadata about the authenticated credential and the caller's resolved runtime context (never secrets).
178
+ *
179
+ * Operation `auth.context.read` · read · requires `auth_context:read`.
180
+ */
181
+ readonly read: Method<"auth.context.read">;
182
+ };
183
+ /**
184
+ * List the organizations a user login can act in
185
+ *
186
+ * No opKey · read.
187
+ */
188
+ readonly listOrganizations: Method<"auth.listOrganizations">;
189
+ /**
190
+ * The organization this credential acts in
191
+ *
192
+ * No opKey · read.
193
+ */
194
+ readonly selectedOrganization: Method<"auth.selectedOrganization">;
195
+ };
196
+ readonly automationRules: {
197
+ /**
198
+ * Create an automation rule
199
+ *
200
+ * Operation `automation_rule.create` · write · requires `automation_rule:create` · reconcile an unknown outcome with `automation_rule.read`.
201
+ */
202
+ readonly create: Method<"automationRules.create">;
203
+ /**
204
+ * Delete an automation rule
205
+ *
206
+ * Operation `automation_rule.delete` · write · requires `automation_rule:delete` · destructive · reconcile an unknown outcome with `automation_rule.read`.
207
+ */
208
+ readonly delete: Method<"automationRules.delete">;
209
+ /**
210
+ * Show one automation rule
211
+ *
212
+ * Operation `automation_rule.read` · read · requires `automation_rule:read`.
213
+ */
214
+ readonly get: Method<"automationRules.get">;
215
+ /**
216
+ * List automation rules
217
+ *
218
+ * Operation `automation_rule.read` · read · requires `automation_rule:read` · cursor pagination.
219
+ */
220
+ readonly read: Method<"automationRules.read">;
221
+ /**
222
+ * Update an automation rule
223
+ *
224
+ * Operation `automation_rule.update` · write · requires `automation_rule:update` · reconcile an unknown outcome with `automation_rule.read`.
225
+ */
226
+ readonly update: Method<"automationRules.update">;
227
+ };
228
+ readonly backends: {
229
+ /**
230
+ * Bind a logical backend to a direct upstream in one environment
231
+ *
232
+ * Bind a logical backend id to a concrete direct upstream URL in one environment. Previews inherit the production backend until a concrete override is bound. Omit environmentId for production.
233
+ *
234
+ * Operation `backend.bind` · write · requires `backend:bind` · supports `dryRun` · reconcile an unknown outcome with `backend.read`.
235
+ */
236
+ readonly bind: Method<"backends.bind">;
237
+ /**
238
+ * Create a backend (default transport: direct)
239
+ *
240
+ * Create a backend (origin) for a business. Pick a transport mode: direct (public HTTPS URL, secured by Ed25519 request signing) or tunnel (private outbound-only cloudflared, secure bring-your-own-backend). Mark it default to route traffic to it.
241
+ *
242
+ * Operation `backend.create` · write · requires `backend:create` · supports `dryRun` · reconcile an unknown outcome with `backend.read`.
243
+ */
244
+ readonly create: Method<"backends.create">;
245
+ /**
246
+ * Delete a backend (revokes its runtime tokens)
247
+ *
248
+ * Delete a backend (origin). Traffic routed to it stops; re-create to restore.
249
+ *
250
+ * Operation `backend.delete` · write · requires `backend:delete` · destructive · reconcile an unknown outcome with `backend.read`.
251
+ */
252
+ readonly delete: Method<"backends.delete">;
253
+ /**
254
+ * List backends for a business (id, scope, name, transport, status)
255
+ *
256
+ * List a business's backends (origins) — id, scope (production|environment), environmentId, name, slug, transport (direct|tunnel), default flag, and derived status. Backends are per-(business, environment) rows, so the same declared backend can legitimately appear once per scope and be default in each. Read-only.
257
+ *
258
+ * Operation `backend.read` · read · requires `backend:read` · offset pagination.
259
+ */
260
+ readonly read: Method<"backends.read">;
261
+ };
262
+ readonly billing: {
263
+ readonly stripe: {
264
+ /**
265
+ * Remove a business's per-business Stripe override so it bills through the org default again
266
+ *
267
+ * Remove a business's per-business Stripe Connect override so it bills through the organization default again. Refused while any subscription is still money-bearing. Destructive live-state operation; it does not edit repo-authored business behavior.
268
+ *
269
+ * Operation `stripe_connection.delete` · write · requires `stripe_connection:delete` · destructive · reconcile an unknown outcome with `stripe_connection.read`.
270
+ */
271
+ readonly delete: Method<"billing.stripe.delete">;
272
+ /**
273
+ * Show the Stripe connection a business bills through (business override or org default)
274
+ *
275
+ * Read the Stripe Connect account a business bills through — a per-business override when present, otherwise the organization default — including onboarding and tax-enrollment state. Read-only. Connecting Stripe is browser-only and has no tool.
276
+ *
277
+ * Operation `stripe_connection.read` · read · requires `stripe_connection:read`.
278
+ */
279
+ readonly read: Method<"billing.stripe.read">;
280
+ };
281
+ readonly taxSettings: {
282
+ /**
283
+ * Show a business's Stripe Tax settings
284
+ *
285
+ * Operation `tax_settings.read` · read · requires `tax_settings:read`.
286
+ */
287
+ readonly read: Method<"billing.taxSettings.read">;
288
+ /**
289
+ * Update a business's Stripe Tax settings
290
+ *
291
+ * Operation `tax_settings.update` · write · requires `tax_settings:update` · reconcile an unknown outcome with `tax_settings.read`.
292
+ */
293
+ readonly update: Method<"billing.taxSettings.update">;
294
+ };
295
+ };
296
+ readonly bulletin: {
297
+ /**
298
+ * Acknowledge a post (the coding agent picked it up)
299
+ *
300
+ * Mark a bulletin post acknowledged — the hand-off signal that the coding agent (or builder) has picked the item up. Forward-only; acknowledging an already-acknowledged post changes nothing.
301
+ *
302
+ * Operation `bulletin.ack` · write · requires `bulletin:ack` · reconcile an unknown outcome with `bulletin.read`.
303
+ */
304
+ readonly ack: Method<"bulletin.ack">;
305
+ /**
306
+ * List the agents' bulletin feed (trends + change requests)
307
+ *
308
+ * The agents' bulletin feed for a business: trend/insight posts (aggregated data + deltas) and change_request posts (the coding agent's backlog — filter --kind change_request --status open). Read-only.
309
+ *
310
+ * Operation `bulletin.list` · read · requires `bulletin:read` · cursor pagination.
311
+ */
312
+ readonly list: Method<"bulletin.list">;
313
+ /**
314
+ * Show one bulletin post (full body + data payload)
315
+ *
316
+ * One bulletin post in full: markdown body, the dataJson payload backing the claim, and for change requests the referenced ChangeSet id + proposal. Read-only.
317
+ *
318
+ * Operation `bulletin.read` · read · requires `bulletin:read`.
319
+ */
320
+ readonly read: Method<"bulletin.read">;
321
+ /**
322
+ * Resolve a post (the work landed)
323
+ *
324
+ * Mark a bulletin post resolved — the referenced work landed (or the trend was addressed). Terminal state.
325
+ *
326
+ * Operation `bulletin.resolve` · write · requires `bulletin:resolve` · reconcile an unknown outcome with `bulletin.read`.
327
+ */
328
+ readonly resolve: Method<"bulletin.resolve">;
329
+ };
330
+ readonly businesses: {
331
+ readonly brand: {
332
+ /**
333
+ * Remove a business icon or logo image
334
+ *
335
+ * Operation `brand.update` · write · requires `brand:update` · reconcile an unknown outcome with `business.read`.
336
+ */
337
+ readonly deleteAsset: Method<"businesses.brand.deleteAsset">;
338
+ /**
339
+ * Update business presentation metadata
340
+ *
341
+ * Update a business's brand and presentation — display name, description, icon, logo (wordmark), key prefix, and organization-page visibility. Plans, pricing, routes, and backend origins are managed through their dedicated surfaces. Only the fields you pass are changed.
342
+ *
343
+ * Operation `brand.update` · write · requires `brand:update` · reconcile an unknown outcome with `business.read`.
344
+ */
345
+ readonly update: Method<"businesses.brand.update">;
346
+ /**
347
+ * Upload a business icon or logo image
348
+ *
349
+ * Operation `brand.update` · write · requires `brand:update` · reconcile an unknown outcome with `business.read`.
350
+ */
351
+ readonly uploadAsset: Method<"businesses.brand.uploadAsset">;
352
+ };
353
+ /**
354
+ * Validate a business-as-code Manifest IR envelope (dry-run compile)
355
+ *
356
+ * Operation `business.compile` · read · requires `business:compile`.
357
+ */
358
+ readonly compile: Method<"businesses.compile">;
359
+ readonly config: {
360
+ /**
361
+ * Show a business's accepted configuration as JSON
362
+ *
363
+ * Operation `rbac.read` · read · requires `business:read`.
364
+ */
365
+ readonly read: Method<"businesses.config.read">;
366
+ };
367
+ readonly configAttempts: {
368
+ /**
369
+ * List rejected configuration attempts for a business
370
+ *
371
+ * Operation `business.config_attempts.read` · read · requires `business:read`.
372
+ */
373
+ readonly read: Method<"businesses.configAttempts.read">;
374
+ };
375
+ readonly contract: {
376
+ /**
377
+ * Show a business's accepted contract synopsis
378
+ *
379
+ * Operation `business.contract.read` · read · requires `business:read`.
380
+ */
381
+ readonly read: Method<"businesses.contract.read">;
382
+ };
383
+ readonly cors: {
384
+ /**
385
+ * Update a business's CORS settings
386
+ *
387
+ * Updates the business's platform-owned CORS settings through the business PATCH surface.
388
+ *
389
+ * Operation `business.cors.update` · write · requires `business:cors_update` · reconcile an unknown outcome with `business.read`.
390
+ */
391
+ readonly update: Method<"businesses.cors.update">;
392
+ };
393
+ /**
394
+ * Create a new business and provision its managed GitHub repo
395
+ *
396
+ * Operation `business.create` · write · requires `business:create` · reconcile an unknown outcome with `business.list`.
397
+ */
398
+ readonly create: Method<"businesses.create">;
399
+ /**
400
+ * Permanently delete a business (stage only)
401
+ *
402
+ * (stage only) Permanently delete a business. Requires --yes. Registered only in the stage channel (`make cli-stage`); production businesses are deleted from the dashboard.
403
+ *
404
+ * Operation `business.delete` · write · requires `business:delete` · destructive · reconcile an unknown outcome with `business.list`.
405
+ */
406
+ readonly delete: Method<"businesses.delete">;
407
+ readonly docs: {
408
+ /**
409
+ * Disable docs for a business (stop publishing/serving docs; scaffold kept in the repo)
410
+ *
411
+ * Disable docs for a business — docs are no longer shown in the portal. The docs scaffold stays in the repo, so enabling them again restores them. Safe to repeat: disabling them when already disabled changes nothing.
412
+ *
413
+ * Operation `business.docs.disable` · write · requires `business:docs_update` · reconcile an unknown outcome with `business.read`.
414
+ */
415
+ readonly disable: Method<"businesses.docs.disable">;
416
+ /**
417
+ * Enable docs for a business (publish/serve docs scaffold)
418
+ *
419
+ * Enable docs for a business — published docs become available in the portal. Safe to repeat: enabling them when already enabled changes nothing.
420
+ *
421
+ * Operation `business.docs.enable` · write · requires `business:docs_update` · reconcile an unknown outcome with `business.read`.
422
+ */
423
+ readonly enable: Method<"businesses.docs.enable">;
424
+ };
425
+ /**
426
+ * List businesses in the current org
427
+ *
428
+ * List every business in the authenticated FartherShore workspace (id, name, status). Read-only; use this to discover business ids for the other tools.
429
+ *
430
+ * Operation `business.list` · read · requires `business:read` · offset pagination.
431
+ */
432
+ readonly list: Method<"businesses.list">;
433
+ readonly previewEnv: {
434
+ /**
435
+ * Configure automatic preview-environment creation for a business
436
+ *
437
+ * Configure automatic preview environment creation for a business. Modes: BRANCH_PREFIX creates previews from matching env branches, PULL_REQUEST creates previews for PRs against the default branch, and DISABLED stops automatic creation while explicit `farthershore env create` continues to work. Pass envBranchPrefix to customize the branch-prefix mode, or null to reset to env/.
438
+ *
439
+ * Operation `business.preview_env.set` · write · requires `business:preview_env_update` · reconcile an unknown outcome with `environment.read`.
440
+ */
441
+ readonly set: Method<"businesses.previewEnv.set">;
442
+ };
443
+ /**
444
+ * Publish a draft business (make it live) and cut a versioned release with an auto-computed semver. Requires at least one plan, a bound backend, and a verified Stripe connection
445
+ *
446
+ * Publish a business — validate its current spec and queue a versioned release with an auto-computed semver. Use business status to prove it is live.
447
+ *
448
+ * Operation `business.publish` · write · requires `business:publish` · supports `dryRun` · reconcile an unknown outcome with `business.status`.
449
+ */
450
+ readonly publish: Method<"businesses.publish">;
451
+ readonly rbac: {
452
+ /**
453
+ * Disable Managed RBAC for a business
454
+ *
455
+ * Disable Managed RBAC for a business. Subscriber roles and assignments are kept, so enabling it again restores them. Safe to repeat: disabling it when already disabled changes nothing.
456
+ *
457
+ * Operation `rbac.disable` · write · requires `business:rbac_update` · destructive · reconcile an unknown outcome with `rbac.read`.
458
+ */
459
+ readonly disable: Method<"businesses.rbac.disable">;
460
+ /**
461
+ * Enable Managed RBAC for a business
462
+ *
463
+ * Enable Managed RBAC for a business. Subscriber organizations can then manage roles in their portal. Safe to repeat: enabling it when already enabled changes nothing.
464
+ *
465
+ * Operation `rbac.enable` · write · requires `business:rbac_update` · reconcile an unknown outcome with `rbac.read`.
466
+ */
467
+ readonly enable: Method<"businesses.rbac.enable">;
468
+ /**
469
+ * Show a business's Managed-RBAC state: the platform `rbacEnabled` flag
470
+ *
471
+ * Show a business's Managed-RBAC state: the platform `rbacEnabled` flag.
472
+ *
473
+ * Operation `rbac.read` · read · requires `business:read`.
474
+ */
475
+ readonly read: Method<"businesses.rbac.read">;
476
+ readonly subjects: {
477
+ /**
478
+ * List the raw permission subjects subscriber organizations can assemble into their own roles (repo-owned: authored via fs.group permission config in business/)
479
+ *
480
+ * List a business's raw permission vocabulary (subject, verbs, escalatory verbs, description). The SDK/compiler do not create roles: each subscribing organization assembles this catalog into its own CUSTOM roles, default, and assignments. Subjects are declared via permission-carrying `fs.group(id, routes, { permission })` in the business/ repo; run `farthershore validate` and push to change them. Read-only.
481
+ *
482
+ * Operation `rbac.subjects.read` · read · requires `rbac:read`.
483
+ */
484
+ readonly read: Method<"businesses.rbac.subjects.read">;
485
+ };
486
+ };
487
+ /**
488
+ * Show a business
489
+ *
490
+ * Operation `business.read` · read · requires `business:read`.
491
+ */
492
+ readonly read: Method<"businesses.read">;
493
+ /**
494
+ * Roll back a prior business publish workflow
495
+ *
496
+ * Operation `business.rollback` · write · requires `business:rollback` · destructive · reconcile an unknown outcome with `business.status`.
497
+ */
498
+ readonly rollback: Method<"businesses.rollback">;
499
+ readonly routes: {
500
+ /**
501
+ * List a business's compiled routes
502
+ *
503
+ * Operation `business.routes.read` · read · requires `business:read`.
504
+ */
505
+ readonly read: Method<"businesses.routes.read">;
506
+ };
507
+ /**
508
+ * Show whether one environment is fully live: its lifecycle, release, and whether every part serves that release
509
+ *
510
+ * Check one environment of a business, by id or slug: its lifecycle state, the release it should serve, and whether every part of the environment is serving exactly that release yet. Use it to prove a publish is fully live. Read-only.
511
+ *
512
+ * Operation `business.status` · read · requires `business:read`.
513
+ */
514
+ readonly status: Method<"businesses.status">;
515
+ readonly subdomainAvailability: {
516
+ /**
517
+ * Check whether a slug is free to use as a business subdomain before creating it
518
+ *
519
+ * Check whether a candidate slug is free to use as a business subdomain (normalized, blocked-word and collision checked). Read-only; run before fs_business_create.
520
+ *
521
+ * Operation `business.subdomain_availability.read` · read · requires `business:read`.
522
+ */
523
+ readonly read: Method<"businesses.subdomainAvailability.read">;
524
+ };
525
+ };
526
+ readonly changeSets: {
527
+ /**
528
+ * Simulate + store a preview on a proposed ChangeSet (rides the propose authority)
529
+ *
530
+ * Simulate the impact of a proposed ChangeSet and store the preview (Agent Proposal Flow). Enforced by the same authority as propose — there is no separate preview permission. Read-shaped but writes the stored simulation; does not apply the change.
531
+ *
532
+ * Operation `change_set.preview` · write · requires `change_set:propose` · reconcile an unknown outcome with `change_set.proposal_read`.
533
+ */
534
+ readonly preview: Method<"changeSets.preview">;
535
+ /**
536
+ * List governed ChangeSets proposed against a subscriber
537
+ *
538
+ * List governed ChangeSets proposed against a subscriber (Agent Proposal Flow). Read-only; use it to discover proposal ids + their status before previewing.
539
+ *
540
+ * Operation `change_set.proposal_list` · read · requires `change_set:read` · cursor pagination.
541
+ */
542
+ readonly proposalList: Method<"changeSets.proposalList">;
543
+ /**
544
+ * Read one governed ChangeSet proposed against a subscriber
545
+ *
546
+ * Read one governed ChangeSet proposed against a subscriber (Agent Proposal Flow) — its operations, risk, simulation, approvals, and status. Read-only.
547
+ *
548
+ * Operation `change_set.proposal_read` · read · requires `change_set:read`.
549
+ */
550
+ readonly proposalRead: Method<"changeSets.proposalRead">;
551
+ /**
552
+ * Propose a governed ChangeSet against a subscriber (agent/builder proposer; a human approves + applies in the portal)
553
+ *
554
+ * Propose a governed ChangeSet against a subscriber's live RBAC state (Agent Proposal Flow). Creates a DRAFT proposal that a HUMAN in the subscriber org must preview, approve, and apply in the portal — an agent can propose but never self-approve or apply. Operate-class live-state action; does not edit repo-authored business behavior.
555
+ *
556
+ * Operation `change_set.propose` · write · requires `change_set:propose` · supports `dryRun` · reconcile an unknown outcome with `change_set.proposal_list`.
557
+ */
558
+ readonly propose: Method<"changeSets.propose">;
559
+ readonly timeline: {
560
+ /**
561
+ * List a business's Apply Timeline: repo-triggered manifest applies (PRs, pushes, releases), checks, semantic diffs, and apply phases
562
+ *
563
+ * List a business's Apply Timeline: repo-triggered manifest applies (PRs, pushes, releases), checks, semantic diffs, and apply phases.
564
+ *
565
+ * Operation `apply_timeline.list` · read · requires `apply_timeline:read`.
566
+ */
567
+ readonly list: Method<"changeSets.timeline.list">;
568
+ /**
569
+ * Inspect one Apply Timeline entry by id, release tag, PR number, branch, or commit SHA
570
+ *
571
+ * Inspect one Apply Timeline entry by id, release tag, PR number, branch, or commit SHA.
572
+ *
573
+ * Operation `apply_timeline.read` · read · requires `apply_timeline:read`.
574
+ */
575
+ readonly read: Method<"changeSets.timeline.read">;
576
+ };
577
+ };
578
+ readonly consumers: {
579
+ readonly apiKeys: {
580
+ /**
581
+ * List one subscriber's API keys (metadata only)
582
+ *
583
+ * Operation `consumer.read` · read · requires `consumer:read`.
584
+ */
585
+ readonly list: Method<"consumers.apiKeys.list">;
586
+ /**
587
+ * Revoke one subscriber API key
588
+ *
589
+ * Operation `consumer.block` · write · requires `consumer:block` · destructive · reconcile an unknown outcome with `consumer.read`.
590
+ */
591
+ readonly revoke: Method<"consumers.apiKeys.revoke">;
592
+ };
593
+ /**
594
+ * Block a consumer (revoking every API key) or revoke one of its API keys
595
+ *
596
+ * Blocks a consumer and revokes every active API key, or surgically revokes ONE of the consumer's API keys. Revoked keys stop authenticating.
597
+ *
598
+ * Operation `consumer.block` · write · requires `consumer:block` · destructive · reconcile an unknown outcome with `consumer.read`.
599
+ */
600
+ readonly block: Method<"consumers.block">;
601
+ /**
602
+ * Move one consumer to the active head of their plan lineage
603
+ *
604
+ * Move one consumer onto the current head of their plan lineage immediately. Operates on live subscription state.
605
+ *
606
+ * Operation `consumer.migrate_latest` · write · requires `consumer:migrate_latest` · destructive · reconcile an unknown outcome with `consumer.read`.
607
+ */
608
+ readonly migrateLatest: Method<"consumers.migrateLatest">;
609
+ readonly rbac: {
610
+ /**
611
+ * Turn Managed-RBAC enforcement off for one subscriber
612
+ *
613
+ * Turn Managed-RBAC enforcement OFF for ONE subscriber. This is an ACCESS EXPANSION — with enforcement off, credential permission resolution can return ['*']. Role definitions are preserved for re-enable. Live-state operation; it does not edit repo-authored business behavior.
614
+ *
615
+ * Operation `consumer.rbac.disable` · write · requires `consumer:roles_assign` · destructive · reconcile an unknown outcome with `consumer.read`.
616
+ */
617
+ readonly disable: Method<"consumers.rbac.disable">;
618
+ /**
619
+ * Turn Managed-RBAC enforcement on for one subscriber
620
+ *
621
+ * Turn Managed-RBAC enforcement ON for ONE subscriber, and optionally set the org's default role. Enforcement requires BOTH this flag and the product flag (rbac.enable). Safe to repeat. Live-state operation; it does not edit repo-authored business behavior.
622
+ *
623
+ * Operation `consumer.rbac.enable` · write · requires `consumer:roles_assign` · reconcile an unknown outcome with `consumer.read`.
624
+ */
625
+ readonly enable: Method<"consumers.rbac.enable">;
626
+ };
627
+ /**
628
+ * List a business's consumers, one consumer's API keys, or its Managed-RBAC roles
629
+ *
630
+ * Reads a business's consumers (subscribers). The same capability lists one consumer's API keys (metadata only; key material is never returned) and one subscriber's Managed-RBAC roles.
631
+ *
632
+ * Operation `consumer.read` · read · requires `consumer:read`.
633
+ */
634
+ readonly read: Method<"consumers.read">;
635
+ /**
636
+ * Remove a user from live business access
637
+ *
638
+ * Remove a user/consumer from live business access: cancel subscriptions, revoke credentials, purge related live state, and archive the subscriber while retaining billing/audit history. Destructive and convergent on retry; it does not edit repo-authored business behavior.
639
+ *
640
+ * Operation `consumer.remove` · write · requires `consumer:remove` · destructive · reconcile an unknown outcome with `consumer.read`.
641
+ */
642
+ readonly remove: Method<"consumers.remove">;
643
+ readonly role: {
644
+ /**
645
+ * Create a CUSTOM Managed-RBAC role for one subscriber
646
+ *
647
+ * Create a CUSTOM Managed-RBAC role for ONE subscriber from the business's derived permission catalog. A duplicate role key is refused. Live-state operation; it does not edit repo-authored business behavior.
648
+ *
649
+ * Operation `consumer.role.create` · write · requires `consumer:roles_assign` · reconcile an unknown outcome with `consumer.read`.
650
+ */
651
+ readonly create: Method<"consumers.role.create">;
652
+ /**
653
+ * Delete one subscriber Managed-RBAC role
654
+ *
655
+ * Delete ONE subscriber Managed-RBAC role. The key is stripped from every member and credential that holds it and cleared as the org default. Live-state operation; it does not edit repo-authored business behavior.
656
+ *
657
+ * Operation `consumer.role.delete` · write · requires `consumer:roles_assign` · destructive · reconcile an unknown outcome with `consumer.read`.
658
+ */
659
+ readonly delete: Method<"consumers.role.delete">;
660
+ /**
661
+ * List one subscriber's own roles
662
+ *
663
+ * Operation `consumer.read` · read · requires `consumer:read`.
664
+ */
665
+ readonly list: Method<"consumers.role.list">;
666
+ /**
667
+ * Rename or re-permission one subscriber Managed-RBAC role
668
+ *
669
+ * Rename and/or re-permission ONE subscriber Managed-RBAC role. `permissions` is set-replace — the given list becomes the role's full grant. Live-state operation; it does not edit repo-authored business behavior.
670
+ *
671
+ * Operation `consumer.role.update` · write · requires `consumer:roles_assign` · reconcile an unknown outcome with `consumer.read`.
672
+ */
673
+ readonly update: Method<"consumers.role.update">;
674
+ };
675
+ readonly roles: {
676
+ /**
677
+ * Replace a client-org member's Managed-RBAC business roles (builder support override)
678
+ *
679
+ * Support override: replace a client-org member's Managed-RBAC business-role assignment on a business (set-replace — the given list becomes the member's full assignment; an empty list clears it). Role keys must exist in the org's role set. Live-state operation; it does not edit repo-authored business behavior.
680
+ *
681
+ * Operation `consumer.roles.assign` · write · requires `consumer:roles_assign` · reconcile an unknown outcome with `consumer.read`.
682
+ */
683
+ readonly assign: Method<"consumers.roles.assign">;
684
+ };
685
+ };
686
+ readonly environments: {
687
+ /**
688
+ * Create a preview environment bound to a git branch
689
+ *
690
+ * Create a preview environment bound to a git branch. Provide a name and the git branch it tracks.
691
+ *
692
+ * Operation `environment.create` · write · requires `environment:create` · reconcile an unknown outcome with `environment.read`.
693
+ */
694
+ readonly create: Method<"environments.create">;
695
+ /**
696
+ * Delete an environment by name
697
+ *
698
+ * Delete an environment by name. Requires --yes.
699
+ *
700
+ * Operation `environment.delete` · write · requires `environment:delete` · destructive · reconcile an unknown outcome with `environment.read`.
701
+ */
702
+ readonly delete: Method<"environments.delete">;
703
+ /**
704
+ * List environments for a business
705
+ *
706
+ * List a business's preview environments (name, branch, hostnames). Production is not an environment row: it is the live business, addressed with `--env production` (or by omitting the environment) on every verb that takes one. The API returns only preview environment rows; the CLI and MCP listings prepend a synthetic `production` row with `id: null` and no branch. Read-only.
707
+ *
708
+ * Operation `environment.read` · read · requires `environment:read` · offset pagination.
709
+ */
710
+ readonly read: Method<"environments.read">;
711
+ };
712
+ readonly frontend: {
713
+ /**
714
+ * Roll the business frontend back to a prior release (re-activate its releaseId)
715
+ *
716
+ * Roll a business's frontend back to a prior release by its releaseId (manifest hash, from fs_frontend_status). Flips the live pointer back and pins it. The releaseId must belong to this target's build history.
717
+ *
718
+ * Operation `frontend.rollback` · write · requires `frontend:rollback` · destructive · supports `dryRun` · reconcile an unknown outcome with `frontend.status`.
719
+ */
720
+ readonly rollback: Method<"frontend.rollback">;
721
+ /**
722
+ * Show the current frontend release, recent releases, and recent builds (incl. failure reasons)
723
+ *
724
+ * Read a business's current frontend serve state (uiMode, active release hash + producing build, pin flag), the recent SUCCEEDED releases (rollback targets), and the recent builds — a FAILED build's `error` explains why a deploy didn't go live. Read-only.
725
+ *
726
+ * Operation `frontend.status` · read · requires `frontend:read`.
727
+ */
728
+ readonly status: Method<"frontend.status">;
729
+ };
730
+ readonly knowledge: {
731
+ readonly business: {
732
+ /**
733
+ * List one business's knowledge resources
734
+ *
735
+ * Operation `knowledge.business.read` · read · requires `knowledge:read` · cursor pagination.
736
+ */
737
+ readonly read: Method<"knowledge.business.read">;
738
+ };
739
+ readonly guide: {
740
+ /**
741
+ * List platform guide resources
742
+ *
743
+ * Operation `knowledge.guide.read` · read · requires `knowledge:read` · cursor pagination.
744
+ */
745
+ readonly read: Method<"knowledge.guide.read">;
746
+ };
747
+ };
748
+ readonly makerTokens: {
749
+ /**
750
+ * List pending org MakerToken approval requests
751
+ *
752
+ * Operation `org_maker_token.approval_list` · read · requires `maker_token:create_org`.
753
+ */
754
+ readonly approvalList: Method<"makerTokens.approvalList">;
755
+ /**
756
+ * Approve an org MakerToken request, optionally trimming its grants
757
+ *
758
+ * Operation `org_maker_token.approve` · write · requires `maker_token:create_org` · returns a one-time secret · reconcile an unknown outcome with `org_maker_token.approval_list`.
759
+ */
760
+ readonly approve: Method<"makerTokens.approve">;
761
+ /**
762
+ * Create or request approval for an organization-owned MakerToken
763
+ *
764
+ * Operation `org_maker_token.create` · write · requires `maker_token:create_org` · returns a one-time secret · reconcile an unknown outcome with `org_maker_token.list`.
765
+ */
766
+ readonly create: Method<"makerTokens.create">;
767
+ /**
768
+ * Deny an org MakerToken approval request
769
+ *
770
+ * Operation `org_maker_token.deny` · write · requires `maker_token:create_org` · reconcile an unknown outcome with `org_maker_token.approval_list`.
771
+ */
772
+ readonly deny: Method<"makerTokens.deny">;
773
+ /**
774
+ * List organization-owned MakerTokens
775
+ *
776
+ * Operation `org_maker_token.list` · read · requires `maker_token:read` · offset pagination.
777
+ */
778
+ readonly list: Method<"makerTokens.list">;
779
+ readonly permissionCatalog: {
780
+ /**
781
+ * List the exact permissions a human may delegate to an org MakerToken
782
+ *
783
+ * Operation `org_maker_token.permission_catalog.read` · read · requires `maker_token:read`.
784
+ */
785
+ readonly read: Method<"makerTokens.permissionCatalog.read">;
786
+ };
787
+ /**
788
+ * Permanently revoke an org MakerToken
789
+ *
790
+ * Operation `org_maker_token.revoke` · write · requires `maker_token:create_org` · destructive · reconcile an unknown outcome with `org_maker_token.list`.
791
+ */
792
+ readonly revoke: Method<"makerTokens.revoke">;
793
+ /**
794
+ * Rotate an org MakerToken and reveal its replacement once
795
+ *
796
+ * Operation `org_maker_token.rotate` · write · requires `maker_token:create_org` · destructive · returns a one-time secret · reconcile an unknown outcome with `org_maker_token.list`.
797
+ */
798
+ readonly rotate: Method<"makerTokens.rotate">;
799
+ /**
800
+ * Replace an org MakerToken's grants or request approval for the change
801
+ *
802
+ * Operation `org_maker_token.update` · write · requires `maker_token:create_org` · reconcile an unknown outcome with `org_maker_token.list`.
803
+ */
804
+ readonly update: Method<"makerTokens.update">;
805
+ };
806
+ readonly notifications: {
807
+ readonly preferences: {
808
+ /**
809
+ * Get notification (email) opt-out preferences
810
+ *
811
+ * Operation `notification.preferences.read` · read · requires `notification:preferences_read`.
812
+ */
813
+ readonly read: Method<"notifications.preferences.read">;
814
+ /**
815
+ * Patch notification (email) opt-out preferences
816
+ *
817
+ * Operation `notification.preferences.update` · write · requires `notification:preferences_update` · reconcile an unknown outcome with `notification.preferences.read`.
818
+ */
819
+ readonly update: Method<"notifications.preferences.update">;
820
+ };
821
+ };
822
+ readonly organizations: {
823
+ readonly bulletin: {
824
+ /**
825
+ * List the consolidated bulletin across the organization
826
+ *
827
+ * Operation `organization.bulletin.read` · read · requires `organization_bulletin:read` · cursor pagination.
828
+ */
829
+ readonly read: Method<"organizations.bulletin.read">;
830
+ };
831
+ /**
832
+ * Create a team or company organization
833
+ *
834
+ * Operation `organization.create` · write · requires `organization:create` · reconcile an unknown outcome with `organization.list`.
835
+ */
836
+ readonly create: Method<"organizations.create">;
837
+ /**
838
+ * Delete an organization and its managed state
839
+ *
840
+ * Operation `organization.delete` · write · requires `organization:delete` · destructive · reconcile an unknown outcome with `organization.list`.
841
+ */
842
+ readonly delete: Method<"organizations.delete">;
843
+ readonly invitation: {
844
+ /**
845
+ * Accept an organization invitation
846
+ *
847
+ * Operation `organization.invitation.accept` · write · requires `organization_invitation:accept` · reconcile an unknown outcome with `organization.list`.
848
+ */
849
+ readonly accept: Method<"organizations.invitation.accept">;
850
+ /**
851
+ * Invite a member to an organization
852
+ *
853
+ * Invite a member to an organization. Returns the raw invitation token once; invitation listings never show it.
854
+ *
855
+ * Operation `organization.invitation.create` · write · requires `organization_invitation:create` · returns a one-time secret · reconcile an unknown outcome with `organization.invitation.list_sent`.
856
+ */
857
+ readonly create: Method<"organizations.invitation.create">;
858
+ /**
859
+ * List the caller's pending organization invitations
860
+ *
861
+ * Operation `organization.invitation.list` · read · requires `organization_invitation:list`.
862
+ */
863
+ readonly list: Method<"organizations.invitation.list">;
864
+ /**
865
+ * List an organization's outstanding sent invitations
866
+ *
867
+ * Operation `organization.invitation.list_sent` · read · requires `organization_invitation:list`.
868
+ */
869
+ readonly listSent: Method<"organizations.invitation.listSent">;
870
+ /**
871
+ * Revoke a pending organization invitation
872
+ *
873
+ * Operation `organization.invitation.revoke` · write · requires `organization_invitation:revoke` · destructive · reconcile an unknown outcome with `organization.invitation.list_sent`.
874
+ */
875
+ readonly revoke: Method<"organizations.invitation.revoke">;
876
+ };
877
+ /**
878
+ * List builder organizations available to the caller
879
+ *
880
+ * Operation `organization.list` · read · requires `organization:read`.
881
+ */
882
+ readonly list: Method<"organizations.list">;
883
+ readonly member: {
884
+ /**
885
+ * List organization members
886
+ *
887
+ * Operation `organization.member.list` · read · requires `organization_member:list` · offset pagination.
888
+ */
889
+ readonly list: Method<"organizations.member.list">;
890
+ /**
891
+ * Remove a member from an organization
892
+ *
893
+ * Operation `organization.member.remove` · write · requires `organization_member:remove` · destructive · reconcile an unknown outcome with `organization.member.list`.
894
+ */
895
+ readonly remove: Method<"organizations.member.remove">;
896
+ /**
897
+ * Change an organization member's role
898
+ *
899
+ * Operation `organization.member.update` · write · requires `organization_member:update` · reconcile an unknown outcome with `organization.member.list`.
900
+ */
901
+ readonly update: Method<"organizations.member.update">;
902
+ };
903
+ readonly overview: {
904
+ /**
905
+ * Read the organization overview shown on the dashboard
906
+ *
907
+ * Operation `organization.overview.read` · read · requires `organization:read`.
908
+ */
909
+ readonly read: Method<"organizations.overview.read">;
910
+ };
911
+ readonly ownership: {
912
+ /**
913
+ * Transfer primary ownership of a team or company organization to another member
914
+ *
915
+ * Transfer primary ownership of a team or company organization to another existing member. Destructive and irreversible for the caller; requires the signed-in owner's session.
916
+ *
917
+ * Operation `organization.ownership.transfer` · write · requires `organization:ownership_transfer` · destructive · reconcile an unknown outcome with `organization.overview.read`.
918
+ */
919
+ readonly transfer: Method<"organizations.ownership.transfer">;
920
+ };
921
+ readonly role: {
922
+ /**
923
+ * Create a custom organization role
924
+ *
925
+ * Operation `organization.role.create` · write · requires `organization_role:create` · reconcile an unknown outcome with `organization.role.list`.
926
+ */
927
+ readonly create: Method<"organizations.role.create">;
928
+ /**
929
+ * Delete an unused custom organization role
930
+ *
931
+ * Operation `organization.role.delete` · write · requires `organization_role:delete` · destructive · reconcile an unknown outcome with `organization.role.list`.
932
+ */
933
+ readonly delete: Method<"organizations.role.delete">;
934
+ /**
935
+ * List the roles available in an organization
936
+ *
937
+ * Operation `organization.role.list` · read · requires `organization_role:read`.
938
+ */
939
+ readonly list: Method<"organizations.role.list">;
940
+ /**
941
+ * Show one organization role and its exact permissions
942
+ *
943
+ * Operation `organization.role.show` · read · requires `organization_role:read`.
944
+ */
945
+ readonly show: Method<"organizations.role.show">;
946
+ /**
947
+ * Update a built-in or custom organization role
948
+ *
949
+ * Operation `organization.role.update` · write · requires `organization_role:update` · reconcile an unknown outcome with `organization.role.show`.
950
+ */
951
+ readonly update: Method<"organizations.role.update">;
952
+ };
953
+ };
954
+ readonly personas: {
955
+ /**
956
+ * Issue a fresh fsk_test_ API key in a test environment
957
+ *
958
+ * Issue a one-time test bootstrap key for a business environment — use it to provision a test persona. Returns the key ONCE; store it now.
959
+ *
960
+ * Operation `persona.bootstrap` · write · requires `persona:issue` · returns a one-time secret · reconcile an unknown outcome with `persona.read`.
961
+ */
962
+ readonly bootstrap: Method<"personas.bootstrap">;
963
+ /**
964
+ * Delete a temporary persona and its test-owned identity state
965
+ *
966
+ * Delete a temporary test persona, including its credential, browser access, and test-owned identity state.
967
+ *
968
+ * Operation `persona.delete` · write · requires `persona:revoke` · destructive · reconcile an unknown outcome with `persona.read`.
969
+ */
970
+ readonly delete: Method<"personas.delete">;
971
+ readonly localPreview: {
972
+ /**
973
+ * Create a local-preview persona handoff and proxy lease
974
+ *
975
+ * Operation `persona.local_preview.issue` · write · requires `persona:issue` · returns a one-time secret.
976
+ */
977
+ readonly issue: Method<"personas.localPreview.issue">;
978
+ /**
979
+ * Renew a CLI local-preview proxy lease
980
+ *
981
+ * Operation `persona.local_preview.renew` · write · requires `persona:issue` · destructive · returns a one-time secret.
982
+ */
983
+ readonly renew: Method<"personas.localPreview.renew">;
984
+ /**
985
+ * Revoke a CLI local-preview proxy lease
986
+ *
987
+ * Operation `persona.local_preview.revoke` · write · requires `persona:issue` · destructive.
988
+ */
989
+ readonly revoke: Method<"personas.localPreview.revoke">;
990
+ };
991
+ /**
992
+ * Open a browser signed in as a test persona
993
+ *
994
+ * Operation `persona.login` · write · requires `persona:issue` · returns a one-time secret.
995
+ */
996
+ readonly login: Method<"personas.login">;
997
+ /**
998
+ * List personas for a test environment
999
+ *
1000
+ * List a business environment's test personas (id, label, status). Read-only.
1001
+ *
1002
+ * Operation `persona.read` · read · requires `persona:read`.
1003
+ */
1004
+ readonly read: Method<"personas.read">;
1005
+ /**
1006
+ * Rotate a persona's test API key and return the new key once
1007
+ *
1008
+ * Rotate a test persona's API key. Returns the replacement key once.
1009
+ *
1010
+ * Operation `persona.rotate` · write · requires `persona:rotate` · destructive · returns a one-time secret · reconcile an unknown outcome with `persona.read`.
1011
+ */
1012
+ readonly rotate: Method<"personas.rotate">;
1013
+ };
1014
+ readonly plans: {
1015
+ /**
1016
+ * List plans for a business
1017
+ *
1018
+ * List a business's pricing plans (read-only). Plans are managed as code in the business's GitHub repo — to add/change/remove a plan, edit business/ and push; this tool only reads the current state. Without environmentId the PRODUCTION plans are returned; pass environmentId to see what a preview environment serves. Pass the business id from fs_business_list.
1019
+ *
1020
+ * Operation `plan.read` · read · requires `plan:read` · offset pagination.
1021
+ */
1022
+ readonly read: Method<"plans.read">;
1023
+ };
1024
+ readonly platform: {
1025
+ readonly denials: {
1026
+ /**
1027
+ * Explain a denied request
1028
+ *
1029
+ * Operation `denial.read` · read · requires `denial:read`.
1030
+ */
1031
+ readonly read: Method<"platform.denials.read">;
1032
+ };
1033
+ readonly dependents: {
1034
+ /**
1035
+ * List active dependents for a business route
1036
+ *
1037
+ * Operation `business_dependents.read` · read · requires `business_dependents:read`.
1038
+ */
1039
+ readonly read: Method<"platform.dependents.read">;
1040
+ };
1041
+ readonly resourceCounts: {
1042
+ /**
1043
+ * Report a subscription resource count
1044
+ *
1045
+ * Operation `resource_count.report` · write · requires `resource_count:report` · reconcile an unknown outcome with `usage.read`.
1046
+ */
1047
+ readonly report: Method<"platform.resourceCounts.report">;
1048
+ };
1049
+ readonly workflowControl: {
1050
+ /**
1051
+ * Preview a historical billing replay
1052
+ *
1053
+ * Operation `workflow.replay` · read · requires `workflow:replay`.
1054
+ */
1055
+ readonly replay: Method<"platform.workflowControl.replay">;
1056
+ /**
1057
+ * Preview restoring a business config commit
1058
+ *
1059
+ * Operation `workflow.rollback` · read · requires `workflow:rollback`.
1060
+ */
1061
+ readonly rollback: Method<"platform.workflowControl.rollback">;
1062
+ };
1063
+ };
1064
+ readonly portal: {
1065
+ readonly serviceAccounts: {
1066
+ /**
1067
+ * List pending service-account approvals
1068
+ *
1069
+ * No opKey · read · offset pagination.
1070
+ */
1071
+ readonly approvals: Method<"portal.serviceAccounts.approvals">;
1072
+ /**
1073
+ * Approve a pending service-account change (an approved creation returns its one-time secret)
1074
+ *
1075
+ * No opKey · write · returns a one-time secret.
1076
+ */
1077
+ readonly approve: Method<"portal.serviceAccounts.approve">;
1078
+ /**
1079
+ * Create a service account (may return its one-time secret)
1080
+ *
1081
+ * No opKey · write · returns a one-time secret.
1082
+ */
1083
+ readonly create: Method<"portal.serviceAccounts.create">;
1084
+ /**
1085
+ * Deny a pending service-account change
1086
+ *
1087
+ * No opKey · write.
1088
+ */
1089
+ readonly deny: Method<"portal.serviceAccounts.deny">;
1090
+ /**
1091
+ * List the subscribing organization's service accounts
1092
+ *
1093
+ * No opKey · read · offset pagination.
1094
+ */
1095
+ readonly list: Method<"portal.serviceAccounts.list">;
1096
+ /**
1097
+ * Revoke a service account
1098
+ *
1099
+ * No opKey · write · destructive.
1100
+ */
1101
+ readonly revoke: Method<"portal.serviceAccounts.revoke">;
1102
+ /**
1103
+ * Rotate a service account's key (returns the new one-time secret)
1104
+ *
1105
+ * No opKey · write · destructive · returns a one-time secret.
1106
+ */
1107
+ readonly rotate: Method<"portal.serviceAccounts.rotate">;
1108
+ /**
1109
+ * Update a service account (may open a pending approval)
1110
+ *
1111
+ * No opKey · write.
1112
+ */
1113
+ readonly update: Method<"portal.serviceAccounts.update">;
1114
+ };
1115
+ readonly usageLimits: {
1116
+ /**
1117
+ * List the subscribing organization's usage limits
1118
+ *
1119
+ * No opKey · read · offset pagination.
1120
+ */
1121
+ readonly list: Method<"portal.usageLimits.list">;
1122
+ /**
1123
+ * Remove a usage limit
1124
+ *
1125
+ * No opKey · write · destructive.
1126
+ */
1127
+ readonly remove: Method<"portal.usageLimits.remove">;
1128
+ /**
1129
+ * Create a usage limit, or update one by id
1130
+ *
1131
+ * No opKey · write.
1132
+ */
1133
+ readonly set: Method<"portal.usageLimits.set">;
1134
+ };
1135
+ };
1136
+ readonly promoCodes: {
1137
+ /**
1138
+ * Archive a checkout promo code
1139
+ *
1140
+ * Archive an API-managed checkout promo code.
1141
+ *
1142
+ * Operation `promo_code.archive` · write · requires `promo_code:archive` · reconcile an unknown outcome with `promo_code.read`.
1143
+ */
1144
+ readonly archive: Method<"promoCodes.archive">;
1145
+ /**
1146
+ * Create an API-managed checkout promo code
1147
+ *
1148
+ * Create an API-managed checkout promo code. Use percent for percent_off, amountCents for amount_off, and no amount for free_months.
1149
+ *
1150
+ * Operation `promo_code.create` · write · requires `promo_code:create` · reconcile an unknown outcome with `promo_code.read`.
1151
+ */
1152
+ readonly create: Method<"promoCodes.create">;
1153
+ /**
1154
+ * Reactivate an archived checkout promo code
1155
+ *
1156
+ * Reactivate an archived API-managed checkout promo code.
1157
+ *
1158
+ * Operation `promo_code.reactivate` · write · requires `promo_code:reactivate` · reconcile an unknown outcome with `promo_code.read`.
1159
+ */
1160
+ readonly reactivate: Method<"promoCodes.reactivate">;
1161
+ /**
1162
+ * List API-managed promo codes for checkout
1163
+ *
1164
+ * List API-managed promo codes for a business. Promo codes are checkout operational state, not repo-authored Business SDK state.
1165
+ *
1166
+ * Operation `promo_code.read` · read · requires `promo_code:read`.
1167
+ */
1168
+ readonly read: Method<"promoCodes.read">;
1169
+ /**
1170
+ * Update an API-managed checkout promo code
1171
+ *
1172
+ * Update an API-managed checkout promo code. Spec changes rotate the Stripe coupon/promotion code behind the scenes.
1173
+ *
1174
+ * Operation `promo_code.update` · write · requires `promo_code:update` · reconcile an unknown outcome with `promo_code.read`.
1175
+ */
1176
+ readonly update: Method<"promoCodes.update">;
1177
+ };
1178
+ readonly runtimeTokens: {
1179
+ /**
1180
+ * Create a runtime token (returns FS_RUNTIME_TOKEN once)
1181
+ *
1182
+ * Mint a new runtime token (fsrt_) for a backend. Returns the plaintext token ONCE — store it now (e.g. as FS_RUNTIME_TOKEN). Operations default to the backend's needs (gateway_verification, metering, health).
1183
+ *
1184
+ * Operation `runtime_token.mint` · write · requires `runtime_token:mint` · returns a one-time secret · reconcile an unknown outcome with `runtime_token.read`.
1185
+ */
1186
+ readonly mint: Method<"runtimeTokens.mint">;
1187
+ /**
1188
+ * List runtime tokens for a business
1189
+ *
1190
+ * List a business's runtime tokens (fsrt_) — id, last-four, operations, status, and env scope. Read-only; secrets are never shown.
1191
+ *
1192
+ * Operation `runtime_token.read` · read · requires `runtime_token:read` · offset pagination.
1193
+ */
1194
+ readonly read: Method<"runtimeTokens.read">;
1195
+ /**
1196
+ * Revoke a runtime token
1197
+ *
1198
+ * Revoke a runtime token. The backend using it stops verifying.
1199
+ *
1200
+ * Operation `runtime_token.revoke` · write · requires `runtime_token:revoke` · destructive · reconcile an unknown outcome with `runtime_token.read`.
1201
+ */
1202
+ readonly revoke: Method<"runtimeTokens.revoke">;
1203
+ /**
1204
+ * Rotate a runtime token (returns a fresh FS_RUNTIME_TOKEN once)
1205
+ *
1206
+ * Rotate a runtime token: mint a fresh secret carrying the same scope and revoke the old one. Returns the new plaintext token ONCE.
1207
+ *
1208
+ * Operation `runtime_token.rotate` · write · requires `runtime_token:rotate` · destructive · returns a one-time secret · reconcile an unknown outcome with `runtime_token.read`.
1209
+ */
1210
+ readonly rotate: Method<"runtimeTokens.rotate">;
1211
+ };
1212
+ readonly usage: {
1213
+ /**
1214
+ * List subscriber-owned usage limits with their current aggregate utilization
1215
+ *
1216
+ * Operation `usage.read` · read · requires `usage:read` · offset pagination.
1217
+ */
1218
+ readonly limits: Method<"usage.limits">;
1219
+ /**
1220
+ * Show usage summary for the last 30 days
1221
+ *
1222
+ * Read a business's usage summary — metered request counts and tier utilization. Without environmentId this rolls up EVERY environment. Read-only.
1223
+ *
1224
+ * Operation `usage.read` · read · requires `usage:read`.
1225
+ */
1226
+ readonly read: Method<"usage.read">;
1227
+ };
1228
+ readonly variables: {
1229
+ /**
1230
+ * Create a variable from stdin (secret unless named FS_PUBLIC_*)
1231
+ *
1232
+ * Creates an immutable variable generation. An FS_PUBLIC_-prefixed name is public (inlined into the frontend bundle); any other name is a write-only secret whose plaintext is accepted once and never returned.
1233
+ *
1234
+ * Operation `business_variable.create` · write · requires `business_variable:create` · reconcile an unknown outcome with `business_variable.read`.
1235
+ */
1236
+ readonly create: Method<"variables.create">;
1237
+ /**
1238
+ * Destroy a revoked secret in Main or preview
1239
+ *
1240
+ * Permanently destroys ciphertext after acknowledged revocation. Main and preview use the same contract.
1241
+ *
1242
+ * Operation `business_variable.delete` · write · requires `business_variable:delete` · destructive · reconcile an unknown outcome with `business_variable.read`.
1243
+ */
1244
+ readonly delete: Method<"variables.delete">;
1245
+ readonly operation: {
1246
+ /**
1247
+ * Read a durable secret mutation operation
1248
+ *
1249
+ * Reads publication status and frozen impact metadata.
1250
+ *
1251
+ * Operation `business_variable.operation.read` · read · requires `business_variable:operation_read`.
1252
+ */
1253
+ readonly read: Method<"variables.operation.read">;
1254
+ };
1255
+ /**
1256
+ * List variables: FS_PUBLIC_* values, secret metadata only
1257
+ *
1258
+ * Lists variables. Returns readable FS_PUBLIC_* values; every other variable is a write-only secret and only its lifecycle metadata is returned.
1259
+ *
1260
+ * Operation `business_variable.read` · read · requires `business_variable:read`.
1261
+ */
1262
+ readonly read: Method<"variables.read">;
1263
+ /**
1264
+ * Revoke runtime access to a secret
1265
+ *
1266
+ * Revokes runtime access after explicit confirmation and returns a durable operation.
1267
+ *
1268
+ * Operation `business_variable.revoke` · write · requires `business_variable:revoke` · destructive · reconcile an unknown outcome with `business_variable.read`.
1269
+ */
1270
+ readonly revoke: Method<"variables.revoke">;
1271
+ /**
1272
+ * Rotate a variable from stdin (the name, and so the class, is unchanged)
1273
+ *
1274
+ * Creates an immutable variable generation. An FS_PUBLIC_-prefixed name is public (inlined into the frontend bundle); any other name is a write-only secret whose plaintext is accepted once and never returned.
1275
+ *
1276
+ * Operation `business_variable.rotate` · write · requires `business_variable:rotate` · reconcile an unknown outcome with `business_variable.read`.
1277
+ */
1278
+ readonly rotate: Method<"variables.rotate">;
1279
+ };
1280
+ readonly webhooks: {
1281
+ /**
1282
+ * Create an API-managed webhook endpoint
1283
+ *
1284
+ * Create an outbound webhook endpoint for a business. Returns the signing secret once.
1285
+ *
1286
+ * Operation `webhook.create` · write · requires `webhook:create` · returns a one-time secret · reconcile an unknown outcome with `webhook.read`.
1287
+ */
1288
+ readonly create: Method<"webhooks.create">;
1289
+ /**
1290
+ * Delete an API-managed webhook endpoint
1291
+ *
1292
+ * Delete an outbound webhook endpoint.
1293
+ *
1294
+ * Operation `webhook.delete` · write · requires `webhook:delete` · destructive · reconcile an unknown outcome with `webhook.read`.
1295
+ */
1296
+ readonly delete: Method<"webhooks.delete">;
1297
+ readonly delivery: {
1298
+ /**
1299
+ * List recent delivery attempts for a webhook endpoint
1300
+ *
1301
+ * List recent delivery attempts for a webhook endpoint. Payload and response body are intentionally omitted.
1302
+ *
1303
+ * Operation `webhook.delivery.read` · read · requires `webhook:delivery_read` · offset pagination.
1304
+ */
1305
+ readonly read: Method<"webhooks.delivery.read">;
1306
+ };
1307
+ readonly eventType: {
1308
+ /**
1309
+ * List the event names a webhook endpoint can subscribe to
1310
+ *
1311
+ * List the event names a webhook endpoint can subscribe to, with descriptions.
1312
+ *
1313
+ * Operation `webhook.event_type.read` · read · requires `webhook:read`.
1314
+ */
1315
+ readonly read: Method<"webhooks.eventType.read">;
1316
+ };
1317
+ /**
1318
+ * List API-managed webhook endpoints
1319
+ *
1320
+ * List API-managed outbound webhook endpoints for a business. Read-only; signing secrets are never returned.
1321
+ *
1322
+ * Operation `webhook.read` · read · requires `webhook:read` · offset pagination.
1323
+ */
1324
+ readonly read: Method<"webhooks.read">;
1325
+ /**
1326
+ * Issue a new signing secret (returned once); the old one keeps verifying for 24h
1327
+ *
1328
+ * Issue a replacement signing secret for a webhook endpoint. Returns the new secret once; deliveries carry both signatures for 24 hours so the receiver can roll over without a gap.
1329
+ *
1330
+ * Operation `webhook.rotate_secret` · write · requires `webhook:update` · destructive · returns a one-time secret · reconcile an unknown outcome with `webhook.read`.
1331
+ */
1332
+ readonly rotateSecret: Method<"webhooks.rotateSecret">;
1333
+ /**
1334
+ * Send a signed test event to a webhook endpoint
1335
+ *
1336
+ * Send a signed test event to an API-managed webhook endpoint and persist the delivery result.
1337
+ *
1338
+ * Operation `webhook.test` · write · requires `webhook:test` · reconcile an unknown outcome with `webhook.delivery.read`.
1339
+ */
1340
+ readonly test: Method<"webhooks.test">;
1341
+ /**
1342
+ * Send a signed sample of a specific event (e.g. payment.failed) to a webhook endpoint
1343
+ *
1344
+ * Operation `webhook.trigger` · write · requires `webhook:test` · reconcile an unknown outcome with `webhook.delivery.read`.
1345
+ */
1346
+ readonly trigger: Method<"webhooks.trigger">;
1347
+ /**
1348
+ * Update a webhook endpoint's URL, events, environment or enabled state
1349
+ *
1350
+ * Update an API-managed webhook endpoint's URL, event list, environment scope and/or enabled state. Use fs_webhook_rotate_secret for a new signing secret.
1351
+ *
1352
+ * Operation `webhook.update` · write · requires `webhook:update` · reconcile an unknown outcome with `webhook.read`.
1353
+ */
1354
+ readonly update: Method<"webhooks.update">;
1355
+ };
1356
+ }