Repository navigation
Architecture
restless is an Electron app, written in TypeScript with React and React Router.
| Package | Purpose |
|---|---|
packages/insomnia |
The desktop app |
packages/insomnia-data |
Data models, services and NeDB storage |
packages/insomnia-inso |
The rl CLI |
packages/insomnia-scripting-environment |
Script APIs |
packages/insomnia-testing |
Test generation and runner |
packages/insomnia-smoke-test |
End-to-end tests |
packages/restless-plugin-secret-managers |
Secret manager plugin |
Internal folders keep their insomnia names on purpose. It keeps future merges from Insomnia practical. See Decisions.
| Process | Role |
|---|---|
| Main | Windows, menus, network, Git and files |
| Renderer | React interface |
| Plugin window | Runs plugins |
| Hidden window | Runs user scripts |
| Utility processes | AI generation and spec linting |
| Web worker | Template rendering |
The renderer calls the main process over IPC. Handlers live in src/main/ipc, and are exposed in src/entry.preload.ts.
Organization
Project
Workspace (collection, spec, mock server, MCP or environment)
Environment and sub-environments
Cookie jar
Folders
Requests
There is one built-in local organization.
HTTP goes through libcurl using node-libcurl. Release builds on Linux and macOS link a static libcurl, built in CI by .github/actions/static-libcurl. Local builds use the system libcurl.
macOS uses the native menu and window controls.
On Windows and Linux, the window is frameless. The menu bar is drawn by the app from the Electron menu, in title-bar-menu.tsx. Window controls come from Chromium's window controls overlay.
-
nativeTheme.themeSourceis set before the window is created, so the controls match the theme. - The overlay sits above the page, so
syncTitleBarColorsrecolors it when a dialog opens. - On Linux, the icons follow the GTK theme.
Git runs through isomorphic-git, so a Git install isn't required.
These pages are generated from docs/wiki in the repository. Edit them there, not on the wiki.