diff --git a/components/landing/hanko.tsx b/components/landing/hanko.tsx index 2f8cc44..c03c82f 100644 --- a/components/landing/hanko.tsx +++ b/components/landing/hanko.tsx @@ -69,7 +69,7 @@ export function Hanko() { })}
- no official middleware brings a dependency along; otel wants @opentelemetry/api beside it + no official middleware brings a dependency along
印 coming in 0.11 · inkan studio
+印 new in 0.11 · inkan studio
Open /_inkan while you develop. No account, no agent, nothing to install: the studio is a
diff --git a/content/blog/inkan-0-11.mdx b/content/blog/inkan-0-11.mdx
new file mode 100644
index 0000000..0217d44
--- /dev/null
+++ b/content/blog/inkan-0-11.mdx
@@ -0,0 +1,66 @@
+---
+title: "inkan studio, and a lock for the pages inkan serves"
+description: "inkan 0.11 turns the inspector into a studio: live requests, every route with its numbers, a map, the MCP tools to call by hand and the jobs to cancel. And protect puts a password on /docs, /openapi.json and the studio."
+date: "2026-11-13"
+author: "Vensin"
+release:
+ version: "0.11.0"
+ badge: "inkan studio, and protect for your docs"
+---
+
+An inkan app knows a lot about itself: every route, its contract, its examples, its tool
+name, its jobs. Until now you saw most of that in the docs page, and the requests in the
+inspector at `/_inkan`. In 0.11 the inspector grows into a studio.
+
+## inkan studio
+
+Start the app in development and open `/_inkan`. Five tabs:
+
+- **live**: the requests as they come, with replay and copy as example as before, and above
+ them the last minute at a glance: requests, broken answers, p95 and the heap, each with a
+ sparkline.
+- **routes**: every route with its calls, what broke, p50 and p95 since the studio opened,
+ sortable. The slowest route is one click away.
+- **map**: the app as a tree of its paths, with the methods, the MCP tools and the routes
+ that ask for credentials.
+- **mcp**: the tools from 0.10, each with a form to call it as a client would. With MCP off
+ it shows what it would serve.
+- **jobs**: the queues, the next scheduled run, progress as it happens, a cancel button, and
+ the last jobs that ended with their results.
+
+It is a page the app serves itself. No account, no agent, nothing to install, and nothing
+on the request path in production: the numbers are only kept while the studio is on.
+
+## protect
+
+Someone asked me whether the docs page can be switched off, and whether it can have a
+password. Switching off was always there (`docs: false`, `openapi: false`), but a password
+was not, and could not be added from outside: the pages inkan serves itself are answered
+before any hook runs, so an auth hook never sees them.
+
+```ts
+inkan({ protect: { user: "team", password: env("DOCS_PASSWORD") } });
+```
+
+`protect` puts HTTP Basic auth on `/docs`, `/openapi.json` and the studio, compared in
+constant time, or takes a function that decides alone. With it the studio also answers
+beyond your own machine, so it can run on a server, behind the password. Your routes and the
+MCP endpoint keep their own `security`. The docs now have a page on
+[what is open in production](/docs/deploy#what-is-open-in-production) and how to close it.
+
+## About speed
+
+The studio is off in production, and nothing it needs runs on the path of a request there.
+The first bench said otherwise, by a little: 0.11 was behind 0.10 in all three runs. One
+small thing had moved, a request that is not GET left the built-in pages a few comparisons
+later than before. With that back as it was, on the same GitHub runner as always, inkan
+scores 91.8 (plain `node:http` as 100), 0.10.0 90.9, Fastify 89.6, Hono 85.1 and Express
+50.5, the median of three runs. The runs and every scenario are in
+[the report](https://github.com/inkanjs/inkan/blob/main/bench/reports/0.11.0.md).
+
+## Next
+
+Both the studio and `protect` are experimental in 0.11. Tell me what you miss in the studio:
+it is the part of inkan I most want to hear about from people who use it every day.
+
+See you next time ✨
diff --git a/content/docs/mcp.mdx b/content/docs/mcp.mdx
index f34bb79..51d2320 100644
--- a/content/docs/mcp.mdx
+++ b/content/docs/mcp.mdx
@@ -120,6 +120,13 @@ inkan mcp src/app.ts -H "authorization: Bearer $TEA_TOKEN"
`-H` sends a header with every call, such as the token a route asks for. What the app logs
goes to stderr, so stdout carries only the protocol.
+In Claude Code it is one line either way:
+
+```sh
+claude mcp add --transport http tea-shop http://localhost:3000/mcp
+claude mcp add tea-shop -- npx inkan mcp src/app.ts
+```
+
## Proven by check
```sh
diff --git a/lib/source.ts b/lib/source.ts
index 5bb2c70..e18cfae 100644
--- a/lib/source.ts
+++ b/lib/source.ts
@@ -22,9 +22,17 @@ export const published = (): Post[] => all.filter((post) => !post.draft);
/** What the blog shows: the published posts, and the drafts too in a preview. */
export const posts = (): Post[] => (showDrafts ? all : published());
-/** The newest published post that announces a release, for the badge on the landing page. */
+const versionOf = (v: string) => v.split(".").map(Number);
+const newer = (a: string, b: string) => {
+ const [x, y] = [versionOf(a), versionOf(b)];
+ for (let i = 0; i < 3; i++) if ((x[i] ?? 0) !== (y[i] ?? 0)) return (x[i] ?? 0) > (y[i] ?? 0);
+ return false;
+};
+
+/** The published post of the highest release, for the badge on the landing page; two posts on one day stay in order. */
export const latestRelease = () => {
- const post = published().find((p) => p.release);
+ let post: Post | undefined;
+ for (const p of published()) if (p.release && (!post || newer(p.release.version, post.release!.version))) post = p;
return post?.release && { ...post.release, url: post.url };
};