@every-app/sdk 0.3.0-rc.9 → 0.3.1

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 (131) hide show
  1. package/README.md +79 -74
  2. package/dist/cloudflare/catalogSettings.generated.d.ts +19 -6
  3. package/dist/cloudflare/catalogSettings.generated.d.ts.map +1 -1
  4. package/dist/cloudflare/catalogSettings.generated.js +43 -14
  5. package/dist/cloudflare/index.d.ts +1 -1
  6. package/dist/cloudflare/index.d.ts.map +1 -1
  7. package/dist/cloudflare/worker.d.ts +63 -9
  8. package/dist/cloudflare/worker.d.ts.map +1 -1
  9. package/dist/cloudflare/worker.js +45 -9
  10. package/dist/index.d.ts +1 -1
  11. package/dist/index.d.ts.map +1 -1
  12. package/dist/internal/aiDefault.d.ts +36 -79
  13. package/dist/internal/aiDefault.d.ts.map +1 -1
  14. package/dist/internal/aiDefault.js +47 -149
  15. package/dist/internal/aiProviders.d.ts +1 -1
  16. package/dist/internal/aiProviders.d.ts.map +1 -1
  17. package/dist/internal/aiProviders.js +2 -2
  18. package/dist/internal/appSettings.d.ts +140 -89
  19. package/dist/internal/appSettings.d.ts.map +1 -1
  20. package/dist/internal/appSettings.js +264 -156
  21. package/dist/internal/capabilities.d.ts +109 -503
  22. package/dist/internal/capabilities.d.ts.map +1 -1
  23. package/dist/internal/capabilities.js +30 -550
  24. package/dist/internal/catalog/commerce.js +1 -1
  25. package/dist/internal/catalog/index.d.ts +35 -0
  26. package/dist/internal/catalog/index.d.ts.map +1 -1
  27. package/dist/internal/catalog/infra.d.ts +35 -0
  28. package/dist/internal/catalog/infra.d.ts.map +1 -1
  29. package/dist/internal/catalog/infra.js +65 -0
  30. package/dist/internal/devProviders.d.ts +1 -19
  31. package/dist/internal/devProviders.d.ts.map +1 -1
  32. package/dist/internal/devProviders.js +7 -1
  33. package/dist/internal/events.d.ts +52 -1
  34. package/dist/internal/events.d.ts.map +1 -1
  35. package/dist/internal/events.js +66 -4
  36. package/dist/internal/gatewaySettings.d.ts +6 -16
  37. package/dist/internal/gatewaySettings.d.ts.map +1 -1
  38. package/dist/internal/gatewaySettings.js +5 -23
  39. package/dist/internal/index.d.ts +1 -0
  40. package/dist/internal/index.d.ts.map +1 -1
  41. package/dist/internal/index.js +1 -0
  42. package/dist/internal/mcpOAuth.d.ts +210 -0
  43. package/dist/internal/mcpOAuth.d.ts.map +1 -0
  44. package/dist/internal/mcpOAuth.js +735 -0
  45. package/dist/internal/oauthClient.d.ts +36 -44
  46. package/dist/internal/oauthClient.d.ts.map +1 -1
  47. package/dist/internal/oauthClient.js +30 -113
  48. package/dist/internal/oauthPresets.d.ts +356 -20
  49. package/dist/internal/oauthPresets.d.ts.map +1 -1
  50. package/dist/internal/oauthPresets.js +183 -861
  51. package/dist/internal/oauthScopes.d.ts +43 -155
  52. package/dist/internal/oauthScopes.d.ts.map +1 -1
  53. package/dist/internal/oauthScopes.js +82 -475
  54. package/dist/internal/oauthSpec.d.ts +28 -71
  55. package/dist/internal/oauthSpec.d.ts.map +1 -1
  56. package/dist/internal/oauthSpec.js +172 -448
  57. package/dist/internal/protocol.d.ts +24 -14
  58. package/dist/internal/protocol.d.ts.map +1 -1
  59. package/dist/internal/protocol.js +26 -7
  60. package/dist/internal/providerApps.d.ts +2 -2
  61. package/dist/internal/providerApps.js +2 -2
  62. package/dist/internal/providerRegistry.d.ts +5 -64
  63. package/dist/internal/providerRegistry.d.ts.map +1 -1
  64. package/dist/internal/providerRegistry.js +19 -118
  65. package/dist/internal/providerSpec.d.ts.map +1 -1
  66. package/dist/internal/providerSpec.js +14 -36
  67. package/dist/internal/remoteMcp.d.ts +191 -47
  68. package/dist/internal/remoteMcp.d.ts.map +1 -1
  69. package/dist/internal/remoteMcp.js +338 -133
  70. package/dist/internal/signInProviders.d.ts +1 -1
  71. package/dist/internal/signInProviders.d.ts.map +1 -1
  72. package/dist/internal/tools.d.ts +15 -8
  73. package/dist/internal/tools.d.ts.map +1 -1
  74. package/dist/internal/tools.js +9 -8
  75. package/dist/manifest.d.ts +96 -40
  76. package/dist/manifest.d.ts.map +1 -1
  77. package/dist/manifest.js +1 -1
  78. package/dist/server/ai.d.ts +1 -93
  79. package/dist/server/ai.d.ts.map +1 -1
  80. package/dist/server/ai.js +17 -111
  81. package/dist/server/attribution.d.ts +11 -1
  82. package/dist/server/attribution.d.ts.map +1 -1
  83. package/dist/server/attribution.js +7 -1
  84. package/dist/server/connectUrl.d.ts +5 -10
  85. package/dist/server/connectUrl.d.ts.map +1 -1
  86. package/dist/server/connectUrl.js +22 -14
  87. package/dist/server/context.d.ts +12 -14
  88. package/dist/server/context.d.ts.map +1 -1
  89. package/dist/server/context.js +23 -25
  90. package/dist/server/eventsEndpoint.d.ts +48 -0
  91. package/dist/server/eventsEndpoint.d.ts.map +1 -0
  92. package/dist/server/eventsEndpoint.js +145 -0
  93. package/dist/server/everyApp.d.ts +16 -26
  94. package/dist/server/everyApp.d.ts.map +1 -1
  95. package/dist/server/everyApp.js +22 -46
  96. package/dist/server/gatewayFetch.d.ts +1 -1
  97. package/dist/server/gatewayFetch.js +1 -1
  98. package/dist/server/index.d.ts +6 -9
  99. package/dist/server/index.d.ts.map +1 -1
  100. package/dist/server/index.js +4 -8
  101. package/dist/server/integrationFetch.d.ts +66 -72
  102. package/dist/server/integrationFetch.d.ts.map +1 -1
  103. package/dist/server/integrationFetch.js +120 -392
  104. package/dist/server/refusal.d.ts +0 -9
  105. package/dist/server/refusal.d.ts.map +1 -1
  106. package/dist/server/refusal.js +0 -22
  107. package/dist/server/tools.d.ts +18 -7
  108. package/dist/server/tools.d.ts.map +1 -1
  109. package/dist/server/tools.js +15 -5
  110. package/dist/server/toolsEndpoint.d.ts +2 -1
  111. package/dist/server/toolsEndpoint.d.ts.map +1 -1
  112. package/dist/server/toolsEndpoint.js +4 -3
  113. package/dist/server/webhooks.d.ts +56 -0
  114. package/dist/server/webhooks.d.ts.map +1 -0
  115. package/dist/server/webhooks.js +205 -0
  116. package/dist/testing/index.d.ts +2 -3
  117. package/dist/testing/index.d.ts.map +1 -1
  118. package/dist/testing/index.js +2 -6
  119. package/package.json +6 -1
  120. package/dist/server/aiBinding.d.ts +0 -68
  121. package/dist/server/aiBinding.d.ts.map +0 -1
  122. package/dist/server/aiBinding.js +0 -294
  123. package/dist/server/authorizeUrl.d.ts +0 -43
  124. package/dist/server/authorizeUrl.d.ts.map +0 -1
  125. package/dist/server/authorizeUrl.js +0 -106
  126. package/dist/server/emailBinding.d.ts +0 -72
  127. package/dist/server/emailBinding.d.ts.map +0 -1
  128. package/dist/server/emailBinding.js +0 -124
  129. package/dist/server/fromMcpTools.d.ts +0 -89
  130. package/dist/server/fromMcpTools.d.ts.map +0 -1
  131. package/dist/server/fromMcpTools.js +0 -192
@@ -8,17 +8,20 @@
8
8
  * (`providers`) and a capability (`capabilities`) are the Gateway's: their
9
9
  * keys and clients live on the Gateway Worker, set once for every app
10
10
  * with `everyapp secret set <NAME>`. The app's own secrets (`secrets`)
11
- * live on its Worker, set from its directory. Each declaration carries a
12
- * need: required (the default; the app doesn't open until it is set),
13
- * optional (the app opens, and the feature says what is missing where it
14
- * is used), or a member of a named any-of group (the app opens once any
15
- * member is set; only for an app that picks among the set members at run
16
- * time). Each may say `why` it is needed and where it comes from
17
- * (`docs`, an https URL); for providers and capabilities the registries
18
- * here supply a default. An app's plain settings (`settings`: a host, a
19
- * project id, a region) are held like its secrets, on its Worker, but are
20
- * values rather than keys: each says what it takes (a URL, a number, one
21
- * of a list) and may give a default.
11
+ * live on its Worker, set from its directory. Everything the manifest
12
+ * lists at its top level is required: the app doesn't open until it is
13
+ * set. The rest is grouped into features (`features`): each a named set of
14
+ * secrets, settings and the Gateway capabilities and providers it needs,
15
+ * with numbered setup steps. A required feature's values are required; an
16
+ * optional feature is all or nothing, never blocking: off while none of
17
+ * its own values is set, incomplete while some are, ready once all are.
18
+ * Each declaration may say `why` it is needed, where it comes from
19
+ * (`docs`, an https URL) and, for an app's own value, `how` to get it;
20
+ * for providers and capabilities the registries here supply a default. An
21
+ * app's plain settings (`settings`: a host, a project id, a region) are
22
+ * held like its secrets, on its Worker, but are values rather than keys:
23
+ * each says what it takes (a URL, a number, one of a list) and may give a
24
+ * default.
22
25
  *
23
26
  * Everything in this module is pure and tenant-neutral: a manifest ships
24
27
  * in a release, and what is set is asked of the caller (`isSet`), which
@@ -27,27 +30,40 @@
27
30
  */
28
31
  import { type ApiKeyCapability, type CapabilityLookup } from "./capabilities.js";
29
32
  import { type IsSet } from "./aiDefault.js";
30
- /** A provider as `providers` lists it: its id, or an entry with a need. */
33
+ /** A provider as `providers` lists it: its id, or an entry with why and docs. */
31
34
  export interface ProviderEntry extends SettingNeedFields {
32
35
  id: string;
33
36
  }
34
- /** A secret as `secrets` lists it: its name, or an entry with a need. */
35
- export interface SecretEntry extends SettingNeedFields {
37
+ /** Where one of the app's own values comes from, for whoever sets it. */
38
+ export interface OwnValueFields {
39
+ /** Where the value lives and what permission it needs (200 characters at most); may hold `{appUrl}` and `{gatewayUrl}`. */
40
+ how?: string;
41
+ /**
42
+ * The feature the value belongs to (its `features` key); absent for one
43
+ * the manifest lists at its top level.
44
+ */
45
+ feature?: string;
46
+ }
47
+ /** A secret as `secrets` (or a feature's `secrets`) lists it: its name, or an entry. */
48
+ export interface SecretEntry extends SettingNeedFields, OwnValueFields {
36
49
  name: string;
50
+ /** `everyapp configure` (and the deploy, for a top-level one) makes it: 32 random bytes, base64url. */
51
+ generate?: boolean;
52
+ /** The value is a file's contents (a .pem): the prompt takes a path. */
53
+ file?: boolean;
37
54
  }
38
55
  /** What a plain setting's value is: text by default, or a URL, a number, a switch. */
39
56
  export type SettingValueType = "text" | "url" | "number" | "boolean";
40
57
  /**
41
- * An app's plain setting as `settings` lists it: a value that isn't a
42
- * secret (a PostHog host, a project id, a region) and differs per
43
- * install, set like a secret with `everyapp configure <app>` and read
58
+ * An app's plain setting as `settings` (or a feature's) lists it: a value
59
+ * that isn't a secret (a PostHog host, a project id, a region) and differs
60
+ * per install, set like a secret with `everyapp configure <app>` and read
44
61
  * from `env` as a string.
45
62
  */
46
- export interface SettingEntry {
63
+ export interface SettingEntry extends OwnValueFields {
47
64
  name: string;
48
65
  why?: string;
49
66
  docs?: string;
50
- optional?: boolean;
51
67
  /** What it takes; `text` when not given. */
52
68
  type?: SettingValueType;
53
69
  /** The values it may take, for a `text` setting that is one of a list. */
@@ -55,33 +71,32 @@ export interface SettingEntry {
55
71
  /** What the deploy sets it to while nobody has set it. */
56
72
  default?: string;
57
73
  }
74
+ /** One feature as the manifest declares it (`features.<id>`). */
75
+ export interface FeatureEntry {
76
+ id: string;
77
+ /** What people read: "GitHub". */
78
+ name: string;
79
+ /** Required features keep the app closed until set; optional ones (the default) are all or nothing. */
80
+ required: boolean;
81
+ why?: string;
82
+ /** Short Markdown lines, in order; may hold `{appUrl}` and `{gatewayUrl}`. */
83
+ steps: string[];
84
+ /** The Gateway capabilities and providers it needs, by id (declared under `capabilities` and `providers` too). */
85
+ capabilities: string[];
86
+ providers: string[];
87
+ }
58
88
  /** What a plain setting's value must be: what `configure` checks and every surface says. */
59
89
  export interface SettingValueRule {
60
90
  type: SettingValueType;
61
91
  values?: string[];
62
92
  default?: string;
63
93
  }
64
- /** What any declaration may say about its need. */
94
+ /** What any declaration may say about why it is needed. */
65
95
  export interface SettingNeedFields {
66
96
  /** Why the app needs it, for whoever sets it (200 characters at most). */
67
97
  why?: string;
68
98
  /** Where the key or client comes from: an https URL. */
69
99
  docs?: string;
70
- /** The app works without it; the feature using it says so where it is used. */
71
- optional?: boolean;
72
- /**
73
- * For an app's own secret: its setup guide, relative to the everyapp
74
- * skill (`setup/main-secret.md`). Providers and capabilities take theirs
75
- * from the registries and can't override it.
76
- */
77
- setup?: string;
78
- /**
79
- * The name of a group of which one set member is enough ("AI model").
80
- * Only for an app that picks among the set members at run time: the
81
- * gateway refuses a call to a provider whose key isn't set, whichever
82
- * others are.
83
- */
84
- anyOf?: string;
85
100
  }
86
101
  /** The manifest fields this module reads, as a stored or authored manifest has them. */
87
102
  export interface SettingsManifestLike {
@@ -91,21 +106,34 @@ export interface SettingsManifestLike {
91
106
  };
92
107
  readonly secrets?: ReadonlyArray<string | SecretEntry>;
93
108
  readonly settings?: ReadonlyArray<SettingEntry>;
109
+ /** Feature id → its name, need, steps and values (`features` in everyapp.config.ts). */
110
+ readonly features?: {
111
+ readonly [id: string]: unknown;
112
+ };
94
113
  readonly ai?: {
95
- readonly routes?: readonly string[];
96
114
  /** The app needs the Gateway's default chat model (`/api/ai/default`): `true`, or an entry with its need. */
97
115
  readonly chat?: boolean | SettingNeedFields;
98
116
  };
99
- /** A remote MCP app's registration (./remoteMcp.ts): its credential is a required Gateway setting. */
117
+ /**
118
+ * A remote MCP app's registration (./remoteMcp.ts). Its credential is
119
+ * the provider it lists under `capabilities`; a block that can't be read
120
+ * (one from before provider credentials) is a `remote-mcp` setting that
121
+ * is never set: remove the app and add it again.
122
+ */
100
123
  readonly remote?: unknown;
101
124
  readonly name?: string;
102
125
  }
103
126
  export type SettingKind = "provider" | "capability" | "secret"
104
127
  /** An app's plain setting (`settings`): a value on its Worker, not a key. */
105
- | "setting" | "ai-routes"
128
+ | "setting"
106
129
  /** The Gateway's default model provider (`ai.chat`): one key of any provider in the order, or the operator's choice. */
107
130
  | "ai-default"
108
- /** A remote MCP app's credential (./remoteMcp.ts): one Gateway setting named by the row. */
131
+ /**
132
+ * A remote MCP app's registration that can't be read (./remoteMcp.ts:
133
+ * one from before provider credentials): no names, never set, fixed by
134
+ * removing the app and adding it again. A readable registration's
135
+ * credential is the provider under `capabilities`, a `capability`.
136
+ */
109
137
  | "remote-mcp";
110
138
  /** Which Worker holds a setting: the Gateway's, or the app's own. */
111
139
  export type SettingHolder = "gateway" | "app";
@@ -113,23 +141,18 @@ export type SettingNeed = {
113
141
  kind: "required";
114
142
  } | {
115
143
  kind: "optional";
116
- } | {
117
- kind: "anyOf";
118
- group: string;
119
144
  };
120
145
  /** What `appSettings` may be told about the Gateway, for the default model provider. */
121
146
  export interface AppSettingsOptions {
122
- /** The operator's stored default provider (`everyapp ai default`), or none. */
123
- aiDefault?: string | null;
124
147
  /** What is set, to put the configured provider first; absent, the order decides. */
125
148
  isSet?: IsSet;
126
149
  }
127
150
  /** One thing the app needs set, as the manifest declares it. */
128
151
  export interface AppSetting {
129
152
  kind: SettingKind;
130
- /** The provider id, capability id or secret name; "ai-routes" for the AI proxy's extra routes. */
153
+ /** The provider id, capability id or secret name. */
131
154
  id: string;
132
- /** "OpenRouter", "DataForSEO", "MAIN_SECRET", "AI proxy routes". */
155
+ /** "OpenRouter", "DataForSEO", "MAIN_SECRET". */
133
156
  label: string;
134
157
  holder: SettingHolder;
135
158
  /** Every one of these must be set for the setting to count as set (or any one group of `alternatives`). */
@@ -146,13 +169,21 @@ export interface AppSetting {
146
169
  why?: string;
147
170
  docs?: string;
148
171
  /**
149
- * The everyapp skill's setup guide for it, relative to the skill
150
- * (`setup/dataforseo.md`; in an app `.claude/skills/everyapp/setup/…`, in
151
- * the checkout `packages/cli/skills/everyapp/setup/…`): what an agent
152
- * reads to set it up end to end. From the registries for providers and
153
- * capabilities; from the manifest entry for an app's own secret.
172
+ * What an agent reads to set a Gateway setting up end to end: the
173
+ * registry's setup guide, relative to the agent docs (`setup/dataforseo.md`
174
+ * is https://everyapp.com/docs/agent/setup/dataforseo.md; in the checkout
175
+ * `landing-page/content/agent/setup/…`). An app's own value has its
176
+ * feature's steps and its `how` instead.
154
177
  */
155
178
  setup?: string;
179
+ /** The feature it belongs to (a `features` key); absent for a top-level declaration. */
180
+ feature?: string;
181
+ /** For an app's own value: where it lives and what permission it needs, placeholders unfilled. */
182
+ how?: string;
183
+ /** An app's own secret `configure` makes when unset. */
184
+ generate?: boolean;
185
+ /** An app's own secret whose value is a file's contents. */
186
+ file?: boolean;
156
187
  /**
157
188
  * What the key is and where it comes from, in a sentence or three, from
158
189
  * the provider's entry (its `hint`, and each secret's own after it):
@@ -175,45 +206,56 @@ export interface EvaluatedSetting extends AppSetting {
175
206
  * Worker whose secret names were never recorded), which never blocks.
176
207
  */
177
208
  set: boolean | null;
178
- /** This setting keeps the app from opening: required and unset, or a member of an any-of group none of whose members is set. */
209
+ /** This setting keeps the app from opening: required and unset. */
179
210
  blocking: boolean;
180
211
  }
181
- /** An any-of group: met once any member is set. */
182
- export interface AnyOfGroup {
183
- group: string;
184
- members: EvaluatedSetting[];
185
- met: boolean;
212
+ /**
213
+ * A feature's state: `off` while none of its own values is set (an
214
+ * optional feature that's off never blocks), `incomplete` while some are
215
+ * and others aren't (a warning, never a block, for an optional one),
216
+ * `ready` once every value and every Gateway setting it needs is set.
217
+ */
218
+ export type FeatureState = "off" | "incomplete" | "ready";
219
+ /** A feature with its settings evaluated. */
220
+ export interface FeatureReport extends FeatureEntry {
221
+ state: FeatureState;
222
+ /** Its own values and the Gateway settings it needs, in manifest order. */
223
+ settings: EvaluatedSetting[];
186
224
  }
187
225
  /** What `evaluateAppSettings` finds: whether the app opens, and every setting's state. */
188
226
  export interface AppSettingsReport {
189
- /** No required setting is unset and every any-of group is met. */
227
+ /** No required setting is unset. */
190
228
  ready: boolean;
191
- /** Every setting, in manifest order: providers, capabilities, the AI routes, secrets. */
229
+ /** Every setting, in manifest order: providers, capabilities, secrets, settings. */
192
230
  settings: EvaluatedSetting[];
193
- groups: AnyOfGroup[];
194
231
  /** The settings that keep the app closed, in manifest order. */
195
232
  unmet: EvaluatedSetting[];
233
+ /** Every feature, in manifest order. */
234
+ features: FeatureReport[];
196
235
  }
197
- /** The need an entry declares; required unless it says otherwise. */
198
- export declare function needOf(entry: SettingNeedFields | undefined): SettingNeed;
236
+ /** The features the manifest declares, in order, each read whatever a stored row holds. */
237
+ export declare function featureEntries(manifest: Pick<SettingsManifestLike, "features">): FeatureEntry[];
199
238
  /** The providers the manifest lists, each as an entry whatever form it took. */
200
239
  export declare function providerEntries(manifest: Pick<SettingsManifestLike, "providers">): ProviderEntry[];
201
240
  /** The provider ids the manifest lists, in order. */
202
241
  export declare function providerIds(manifest: Pick<SettingsManifestLike, "providers">): string[];
203
- /** The app's own secrets the manifest lists, each as an entry whatever form it took. */
204
- export declare function secretEntries(manifest: Pick<SettingsManifestLike, "secrets">): SecretEntry[];
242
+ /**
243
+ * The app's own secrets the manifest lists, each as an entry whatever form
244
+ * it took: the top-level ones, then each feature's (tagged with it).
245
+ */
246
+ export declare function secretEntries(manifest: Pick<SettingsManifestLike, "secrets" | "features">): SecretEntry[];
205
247
  /** The names of the app's own secrets, in order. */
206
- export declare function secretNames(manifest: Pick<SettingsManifestLike, "secrets">): string[];
207
- /** The app's plain settings the manifest lists, each as an entry. */
208
- export declare function settingEntries(manifest: Pick<SettingsManifestLike, "settings">): SettingEntry[];
248
+ export declare function secretNames(manifest: Pick<SettingsManifestLike, "secrets" | "features">): string[];
249
+ /** The app's plain settings the manifest lists, each as an entry: the top-level ones, then each feature's. */
250
+ export declare function settingEntries(manifest: Pick<SettingsManifestLike, "settings" | "features">): SettingEntry[];
209
251
  /** The names of the app's plain settings, in order. */
210
- export declare function settingNames(manifest: Pick<SettingsManifestLike, "settings">): string[];
252
+ export declare function settingNames(manifest: Pick<SettingsManifestLike, "settings" | "features">): string[];
211
253
  /**
212
254
  * Every name the manifest puts on the app's own Workers: its secrets,
213
255
  * then its plain settings. What `secret set` routes to the app and what
214
256
  * `apps.secret_names` records.
215
257
  */
216
- export declare function appWorkerNames(manifest: Pick<SettingsManifestLike, "secrets" | "settings">): string[];
258
+ export declare function appWorkerNames(manifest: Pick<SettingsManifestLike, "secrets" | "settings" | "features">): string[];
217
259
  /** A plain setting's rule, from its entry. */
218
260
  export declare function settingValueRule(entry: SettingEntry): SettingValueRule;
219
261
  /**
@@ -228,8 +270,7 @@ export declare function settingValueTakes(rule: SettingValueRule): string;
228
270
  export declare function settingValueProblem(rule: Pick<SettingValueRule, "type" | "values">, value: string): string | null;
229
271
  /**
230
272
  * Every setting the manifest declares, in manifest order: its AI
231
- * providers, its capabilities, the AI proxy's extra routes when `ai.routes`
232
- * asks for any, then the app's own secrets. A provider or capability the
273
+ * providers, its capabilities, then the app's own secrets. A provider or capability the
233
274
  * gateway doesn't offer contributes nothing (the manifest validator refuses
234
275
  * it elsewhere); so does a capability with nothing to set (`members`),
235
276
  * which is always set. `lookup` is where ids are found: the catalog alone
@@ -244,38 +285,39 @@ export interface EvaluateOptions {
244
285
  * to them.
245
286
  */
246
287
  readiness?: (setting: AppSetting) => boolean | null | undefined;
288
+ /** The manifest's features ({@link featureEntries}), for their states; none by default. */
289
+ features?: readonly FeatureEntry[];
247
290
  }
248
291
  /**
249
292
  * Every setting against what is set. `isSet` answers per holder and name:
250
293
  * true, false, or null when it can't tell (the registry never recorded
251
- * the app Worker's secret names), which never blocks. An any-of group is
252
- * met once any member is set; while none is and none is unknown, every
253
- * member blocks.
294
+ * the app Worker's secret names), which never blocks. A required setting
295
+ * that is unset blocks; an optional one (an optional feature's) never does.
254
296
  */
255
297
  export declare function evaluateAppSettings(settings: readonly AppSetting[], isSet: (holder: SettingHolder, name: string) => boolean | null, options?: EvaluateOptions): AppSettingsReport;
256
298
  /** The one command that opens the app. */
257
299
  export interface SetupCommand {
258
300
  /**
259
301
  * `everyapp configure <app>`: asks for every required setting the app
260
- * lacks, then offers the optional ones, and sets each where it is held.
302
+ * lacks, feature by feature, then offers its optional features, and sets
303
+ * each where it is held.
261
304
  */
262
305
  command: string;
263
306
  }
264
307
  /**
265
308
  * What to run for an app that needs setup: `everyapp configure <app>`,
266
309
  * which reads the app's manifest (from the registry, so it runs from
267
- * anywhere), prompts for each unmet setting (one member of an any-of group
268
- * is enough: it asks which) and sets them where they are held. Null when
310
+ * anywhere), prompts for each unmet setting, feature by feature, and sets
311
+ * them where they are held. Null when
269
312
  * the app is ready. `cli` is how the operator runs everyapp (`pnpm
270
313
  * everyapp` from a checkout). Scripts that set one name at a time use
271
314
  * `everyapp secret set NAME [--app <id>]` instead.
272
315
  *
273
316
  * A provider app (`provider`: the gateway's own, with no Worker and no
274
317
  * directory; `everyapp mcp on <id>`, an MCP app) has nothing to configure: its
275
- * command is the `secret set` of its Gateway key (the first member of an
276
- * unmet any-of group), as `mcp list` says it.
318
+ * command is the `secret set` of its Gateway key, as `mcp list` says it.
277
319
  */
278
- export declare function setupCommand(report: Pick<AppSettingsReport, "unmet" | "groups">, { cli, appId, provider, }: {
320
+ export declare function setupCommand(report: Pick<AppSettingsReport, "unmet">, { cli, appId, provider, }: {
279
321
  cli: string;
280
322
  appId: string;
281
323
  provider?: boolean;
@@ -286,22 +328,25 @@ export type AppSetupSetting = Omit<EvaluatedSetting, "alsoReads">;
286
328
  * An app's setup state as every surface shows it, the same on the
287
329
  * gateway's app lists (`setup`), `everyapp status --json`
288
330
  * (`apps[].setup`) and `everyapp secret list --json`: whether it opens,
289
- * every setting with its state, the any-of groups, and the one command
290
- * that opens it, `everyapp configure <app>` (null when it is ready, or
291
- * when whoever reads this can't run it: a shared app seen from another
292
- * organization).
331
+ * every setting with its state, every feature with its state, and the
332
+ * one command that opens it, `everyapp configure <app>` (null when it is
333
+ * ready, or when whoever reads this can't run it: a shared app seen from
334
+ * another organization).
293
335
  */
294
336
  export interface AppSetup {
295
337
  ready: boolean;
296
338
  settings: AppSetupSetting[];
297
339
  unmet: AppSetupSetting[];
298
- groups: Array<{
299
- group: string;
300
- met: boolean;
301
- members: string[];
302
- }>;
340
+ /** Each feature: its name, need, steps (placeholders unfilled), state, and its settings' ids. */
341
+ features: AppSetupFeature[];
303
342
  command: SetupCommand | null;
304
343
  }
344
+ /** One feature as `AppSetup` carries it. */
345
+ export interface AppSetupFeature extends FeatureEntry {
346
+ state: FeatureState;
347
+ /** The ids of its settings (in `settings`), in manifest order. */
348
+ settings: string[];
349
+ }
305
350
  export declare function appSetupOf(report: AppSettingsReport, options: {
306
351
  cli: string;
307
352
  appId: string;
@@ -312,4 +357,10 @@ export declare function appSetupOf(report: AppSettingsReport, options: {
312
357
  export declare function providerLabel(id: string, lookup?: CapabilityLookup): string;
313
358
  /** The capability `id` names in `lookup`, as an API-key provider, or undefined. */
314
359
  export declare function apiKeyCapabilityOf(id: string, lookup?: CapabilityLookup): ApiKeyCapability | undefined;
360
+ /**
361
+ * A fresh value for a secret the manifest marks `generate: true`: 32
362
+ * bytes from the platform's cryptographic random source, base64url
363
+ * without padding (43 characters).
364
+ */
365
+ export declare function generatedSecret(): string;
315
366
  //# sourceMappingURL=appSettings.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"appSettings.d.ts","sourceRoot":"","sources":["../../src/internal/appSettings.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,OAAO,EAKL,KAAK,gBAAgB,EAErB,KAAK,gBAAgB,EACtB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAIL,KAAK,KAAK,EACX,MAAM,gBAAgB,CAAC;AAWxB,2EAA2E;AAC3E,MAAM,WAAW,aAAc,SAAQ,iBAAiB;IACtD,EAAE,EAAE,MAAM,CAAC;CACZ;AAED,yEAAyE;AACzE,MAAM,WAAW,WAAY,SAAQ,iBAAiB;IACpD,IAAI,EAAE,MAAM,CAAC;CACd;AAED,sFAAsF;AACtF,MAAM,MAAM,gBAAgB,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,GAAG,SAAS,CAAC;AAErE;;;;;GAKG;AACH,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,4CAA4C;IAC5C,IAAI,CAAC,EAAE,gBAAgB,CAAC;IACxB,0EAA0E;IAC1E,MAAM,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC3B,0DAA0D;IAC1D,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,4FAA4F;AAC5F,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,gBAAgB,CAAC;IACvB,MAAM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