@faable/faable 4.16.0 → 4.17.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.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Faable Cloud SLU
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/dist/mcp/http.js CHANGED
@@ -233,6 +233,15 @@ const create_http_server = (opts) => {
233
233
  if (req.method === 'GET' && url.pathname === '/llms.txt') {
234
234
  return send(res, 200, llms_txt(base), 'text/plain; charset=utf-8');
235
235
  }
236
+ // ChatGPT app submission proves domain ownership by fetching this file;
237
+ // the token comes from the OpenAI platform, set as a secret of the app.
238
+ if (req.method === 'GET' &&
239
+ url.pathname === '/.well-known/openai-apps-challenge') {
240
+ const token = process.env.OPENAI_APPS_CHALLENGE?.trim();
241
+ return token
242
+ ? send(res, 200, token, 'text/plain; charset=utf-8')
243
+ : send(res, 404, { error: 'not_found' });
244
+ }
236
245
  // RFC 9728: at the root and with the resource path inserted (what MCP
237
246
  // clients derive from https://mcp.faable.com/mcp). Only with OAuth on.
238
247
  if (req.method === 'GET' &&
package/dist/mcp/oauth.js CHANGED
@@ -20,9 +20,16 @@ import { verify, createPublicKey, createHash } from 'node:crypto';
20
20
  const AUTH_ISSUER = process.env.FAABLE_MCP_AUTH_ISSUER ?? 'https://faable.auth.faable.link';
21
21
  const oauth_enabled = () => !!process.env.FAABLE_MCP_CLIENT_ID && !!process.env.FAABLE_MCP_CLIENT_SECRET;
22
22
  // What the consent screen asks for on a first connection (Marc, 05-10:
23
- // reads plus deploy, like the hosted server by default). deploy:write comes
24
- // by step-up, the first time an agent calls a tool that needs it.
25
- const DEFAULT_SCOPES = ['deploy:read', 'deploy:deploy'];
23
+ // reads plus deploy, like the hosted server by default; 18-10: plus the Auth
24
+ // reads). deploy:write and auth:write come by step-up, the first time an
25
+ // agent calls a tool that needs them. auth:read cannot: `tools/list` only
26
+ // shows what the connection was allowed, so without it the Auth tools never
27
+ // appear and no call ever asks for it (backlog §373).
28
+ const DEFAULT_SCOPES = [
29
+ 'deploy:read',
30
+ 'deploy:deploy',
31
+ 'auth:read'
32
+ ];
26
33
  const ALL_SCOPES = [
27
34
  'deploy:read',
28
35
  'deploy:deploy',
package/dist/mcp/tools.js CHANGED
@@ -16,7 +16,11 @@ const target = (a) => ['--app', a.app, ...scope(a)];
16
16
  const opt = (flag, value) => value === undefined || value === null || value === ''
17
17
  ? []
18
18
  : [flag, String(value)];
19
- const READ = { readOnlyHint: true, openWorldHint: true };
19
+ const READ = {
20
+ readOnlyHint: true,
21
+ destructiveHint: false,
22
+ openWorldHint: true
23
+ };
20
24
  // A value as a double-quoted .env value, escaping exactly what parse_env
21
25
  // (src/commands/deploy/secrets/parse_env.ts) unescapes — no more: JSON's
22
26
  // \b, \f or \uXXXX would arrive as literal text.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@faable/faable",
3
- "version": "4.16.0",
3
+ "version": "4.17.1",
4
4
  "main": "dist/index.js",
5
5
  "license": "MIT",
6
6
  "author": "Marc Pomar <marc@faable.com>",