> ## Documentation Index
> Fetch the complete documentation index at: https://docs.skyvexsoftware.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ctx.server

> Mounting Express routes on the shell's local HTTP server from a background module.

`ctx.server` (`PluginServerRegistrar`) registers Express routers on the shell's internal HTTP server.

```ts theme={null}
import { Router } from "express";

const router = Router();

router.get("/status", (req, res) => {
  res.json({ ok: true });
});

export async function onStart(ctx) {
  ctx.server.registerRouter("/api/my-plugin", router);
}
```

Routes are mounted at `/api/my-plugin/status` — use `STRATOS_APP_BASE` from the SDK to build the full URL.

**When to use it:** to expose data or actions from your background module to your UI module over HTTP. Paired with TanStack Query in the renderer, it's the recommended request/response channel between the two modules — see [Background ↔ UI Communication](/sdk/background/communication) for the end-to-end pattern.
