apps 0.0.1-beta.19 → 0.0.1-beta.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -2
- package/framework-reference.json +1 -1
- package/js/{chunk-4EMWIFFJ.js → chunk-OZ4UK3CD.js} +8 -0
- package/js/graphql.js +14 -10
- package/js/mcp.js +15 -12
- package/js/skills.js +1 -1
- package/package.json +1 -1
- package/runtime.json +1 -1
- package/types/apps/src/implementation/catalog-cache.d.ts +25 -2
- package/types/apps/src/implementation/graphql-catalog.d.ts +3 -3
- package/types/apps/src/implementation/mcp-catalog.d.ts +6 -4
package/README.md
CHANGED
|
@@ -80,6 +80,7 @@ export default defineApp(
|
|
|
80
80
|
(account) =>
|
|
81
81
|
mcpRouter({
|
|
82
82
|
url: "https://example.com/mcp",
|
|
83
|
+
account,
|
|
83
84
|
headers: { Authorization: "Bearer " + account.fields.token },
|
|
84
85
|
signal,
|
|
85
86
|
}),
|
|
@@ -89,8 +90,9 @@ export default defineApp(
|
|
|
89
90
|
);
|
|
90
91
|
```
|
|
91
92
|
|
|
92
|
-
MCP and GraphQL helpers
|
|
93
|
-
`ctx.cache
|
|
93
|
+
MCP and GraphQL helpers take the account their headers come from, and accept
|
|
94
|
+
`cache: ctx.cache`; an account's catalog is kept in that account's scope and
|
|
95
|
+
credentials never enter its key. They return a dynamic router, cache remote
|
|
94
96
|
metadata, and compile only the selected tool. The defaults are five minutes fresh
|
|
95
97
|
plus five minutes stale. Use `freshFor` / `staleFor` to change the windows, or
|
|
96
98
|
`revalidate: true` to await a refresh. Tool results are never cached.
|