Akan.js 3.1

Release note · Oct 25, 2026

Akan.js 3.1: hardened for production

v3 let AI agents use your app alongside people. 3.1 is about running that app for real, with confidence. Upgrading alone makes it safer and faster, and the new features cover what production asks for: keeping the wrong people out, changing data safely, riding out bad networks, and updating devices nobody watches.

Security

Safer the moment you upgrade

Most of these close a gap between visitors, or between your server and others. None of them asks you to change a line of code, which makes them the best reason to upgrade even if you never touch a new feature.

Each visitor in their own lane
Two visitors pass through the same server in separate lanes divided by a wall, so neither ever sees the other's session.
  • Visitors' sessions never mix

    Under heavy traffic, part of a page streamed to one visitor could read another visitor's login cookie. Each render now sees only its own request.

  • Your users' login stays home

    When your server calls another company's API, it no longer forwards the visitor's login token or address. Only calls to your own server carry them.

  • No more redirect tricks

    A crafted link such as ?redirect=evil.com can no longer use your app's navigation to send a visitor to another site.

  • Requests can't grant themselves extra rights

    Fields a form was never meant to send, such as a role or a deleted flag, are dropped before they reach your code.

  • Switching accounts leaves nothing behind

    Pages kept for the previous account are dropped the moment someone signs in as someone else.

  • Fewer secrets in your logs

    Logs mask more kinds of secrets, such as webhook URLs, database connection strings and signing keys.

  • Updates nobody can tamper with

    A CDN in between can no longer alter a signed app update, and a signed desktop app refuses an update signed by anyone else.

  • The agent acts only on what's on screen

    If the screen changes while the in-page agent is acting, its call is refused instead of running against the wrong thing.

Every security fix in 3.1.0

New features

Seven things production asked for

01

Stop strangers before the page appears

No more flash of a private page before the redirect to sign-in.

Add one guard to a section's layout and every page under it checks who is asking before anything is drawn. A visitor who may not enter goes straight to the sign-in page, and a record they may not see answers as if it did not exist. AI agents connected to your app see only the screens they are allowed to open.

The guard checks first
A signed-in person passes the guard and reaches the page, while a guest is stopped at the guard and sent to the sign-in page before anything renders.
page/(app)/_layout.tsx
Routing

02

Your app's screens, inside the AI chat

Ask Claude about a ticket and get the real ticket card, not a wall of text.

Mark one component of a page as an app, and AI hosts such as claude.ai draw it right inside the conversation. It is the very component your website shows, so there is nothing to build twice. It runs with the user's own permissions and can only read, so it never changes data behind anyone's back.

Your endpoints can hand an AI a picture as well, such as a chart or a product photo, instead of describing it in words.

A real screen in the conversation
An AI chat window where, between the messages, the app's own screen appears as an interactive card.
MCP Apps

03

Change your data's shape, safely

Preview it, apply it, check it, and undo it if you need to.

When a release changes how data is stored, ship a migration script with it. It first shows what it would change without touching anything, refuses to run if the data moved after you reviewed it, and checks the result when it is done. Every value it changes is recorded, so a bad run can be rolled back.

Two servers never run the same migration at once, and the same script runs on your laptop and in your deployed containers.

Preview, apply, verify, undo
A migration first previews its changes, then applies them, then verifies the result, and an applied change can be undone.
Data migrations

04

Bad requests stopped at the door, with a clear reason

Fewer mysterious server errors, more answers that say exactly what went wrong.

Every request is checked against your models before your code runs. A wrong type or a missing field gets an error that names the exact field, and anything the request was not supposed to send is quietly dropped. Invalid input and missing records now answer 400 and 404 instead of a server error.

The errors an endpoint can return are now part of its contract. They appear in your API docs and in the tool descriptions AI agents read, so people and agents alike know what to expect before they call.

Errors

05

Calls that hold up on a shaky network

Retry as often as the network needs, and still charge the customer once.

A call to another server now retries by itself when that server is briefly down or busy, waiting a little longer each time and giving up within the deadline you set. Send a payment or an order with a duplicate-protection key, and it runs exactly once however many times it arrives.

Live screens recover as well. After a dropped connection the app reconnects as soon as the device is back online, and fills in whatever changed in the meantime.

Retried, but charged once
An app's payment call crosses a broken network and is retried several times, yet the payment server charges only once.
order.service.ts
Calling another server

06

Devices that update themselves safely, with nobody watching

Built for kiosks, signage and devices in the field.

Over-the-air updates for phone apps are now signed so that no CDN or middleman can tamper with them. You can rotate the signing key without shipping a new app, revoke a leaked key for good, and see how each release landed across devices without collecting anything about your users. A release that freezes on a phone rolls itself back.

Desktop apps gain a kiosk mode in which pages cannot open print or file dialogs, downloads or other programs. The server a desktop app carries restarts itself when it crashes or hangs, and it can be built without your secrets, so nothing sensitive sits on the installed machine.

Sealed on the way, locked on arrival
A release travels to a kiosk as a sealed, signed update; the kiosk is locked down and restarts itself if anything stops.

07

Your deploy pipeline, right next to your code

Build, test and deploy steps live in your repo and get reviewed like code.

List your pipeline's steps in akan.config.ts, from build and test to Docker and deploy, and add shell steps of your own. Before you push, preview exactly what Akan Cloud will run, locally and without running anything. Pipeline secrets are write-only: once uploaded they are never shown again, and each step reads only the secrets it names.

apps/web/akan.config.ts
Pipelines

Performance

Stricter, and faster anyway

Checking every request had to come for free, so the path a request takes was rebuilt. Each endpoint is prepared once, responses follow a plan made once per model, and every call skips the work it does not need. Live connections got lighter too: a signed-in socket checks its login once per connection instead of on every message, while a sign-out still takes effect at once.

2.5×

faster list responses

16 µs → 6.5 µs

1.5×

faster simple API calls

3.0 µs → 2.0 µs

+15%

more pages served per second

26.7k → 30.8k req/s

−14%

shorter slowest responses

p99 3.7 ms → 3.2 ms

Each figure was measured on one machine just before and just after the change behind it: API calls in process, pages on a cached page of the sample app.

Upgrading from 3.0

3.1 needs Bun 1.4.4 and React 19.3.1. Upgrade Bun, update the workspace, and run the commands below on each app and library. Most apps need nothing more. If yours accepts loosely shaped requests, calls other servers, or ships desktop or phone updates, the release notes have a short checklist, and lint and typecheck point at most of it.

Terminal
See the upgrade checklist

What comes next

3.1 makes everything v3 introduced safe to run for real. It already works hand in hand with Akan Cloud, which runs your pipeline, keeps your secrets and signs your phone updates. The roadmap shows where the cloud and the agent features go from here.

See the roadmap

Released under the MIT License

Connect your AI to these docs

MCPhttps://akanjs.com/mcp
Copyright © 2026 Akan.js All rights reserved.System managed bybassman