{"id":31848242,"url":"https://github.com/unkn0wn-root/resterm","last_synced_at":"2026-04-08T13:01:23.173Z","repository":{"id":317487991,"uuid":"1067109086","full_name":"unkn0wn-root/resterm","owner":"unkn0wn-root","description":"Terminal API client for HTTP/GraphQL/gRPC with support for SSH tunnels, WebSockets, SSE, Workflows, Profiling, OpenAPI, Kubernetes port-forwarding and response diffs.","archived":false,"fork":false,"pushed_at":"2026-04-03T08:25:44.000Z","size":51247,"stargazers_count":1435,"open_issues_count":0,"forks_count":36,"subscribers_count":7,"default_branch":"main","last_synced_at":"2026-04-03T09:39:46.466Z","etag":null,"topics":["api-client","api-testing","go","graphql","grpc","rest","rest-api","rest-client","testing","tui"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/unkn0wn-root.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-30T11:47:23.000Z","updated_at":"2026-04-03T08:25:47.000Z","dependencies_parsed_at":"2026-04-03T00:03:21.690Z","dependency_job_id":null,"html_url":"https://github.com/unkn0wn-root/resterm","commit_stats":null,"previous_names":["unkn0wn-root/resterm"],"tags_count":137,"template":false,"template_full_name":null,"purl":"pkg:github/unkn0wn-root/resterm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unkn0wn-root%2Fresterm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unkn0wn-root%2Fresterm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unkn0wn-root%2Fresterm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unkn0wn-root%2Fresterm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/unkn0wn-root","download_url":"https://codeload.github.com/unkn0wn-root/resterm/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unkn0wn-root%2Fresterm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31556239,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-08T10:21:54.569Z","status":"ssl_error","status_checked_at":"2026-04-08T10:21:38.171Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api-client","api-testing","go","graphql","grpc","rest","rest-api","rest-client","testing","tui"],"created_at":"2025-10-12T10:01:46.211Z","updated_at":"2026-04-08T13:01:23.167Z","avatar_url":"https://github.com/unkn0wn-root.png","language":"Go","funding_links":[],"categories":["Developer Tools","IDE","Go","Table of Contents"],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e\n  \u003cimg src=\"_media/resterm_logo.png\" alt=\"Resterm\" width=\"200\" /\u003e\n  \u003cbr\u003e\n  Resterm\n\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cem\u003eA terminal client for REST, GraphQL, gRPC, WebSocket, and SSE.\u003c/em\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"_media/resterm_base.png\" alt=\"Screenshot of Resterm TUI base\" width=\"720\" /\u003e\n\u003c/p\u003e\n\nResterm is a **keyboard-driven** API client that lives in your terminal and keeps everything local. It stores requests as plain files, supports **SSH tunnels**, **Kubernetes port-forwarding**, **OAuth 2.0**, and **command-backed auth**, and gives you a fast feedback loop with `history`, `diffs`, `tracing`, and `profiling`.\n\nQuick links: [Screenshots](#screenshot-tour), [Installation](#installation), [Quick Start](#quick-start), [Features](#overview) and [Documentation](#documentation).\n\n## Why Resterm\n\n- Requests live in plain `.http` / `.rest` files.\n- **Conditional logic** - `@when`, `@skip-if`, `@if`/`@elif`/`@else`, `@switch`/`@case`, and `@for-each`.\n- **Multi-step workflows** with `@workflow` / `@step`.\n- **Captures, variables, and assertions** (`@capture`, `@var`, `@assert`).\n- **RestermScript** - a small, safe expression language purpose.\n- **OAuth 2.0** (client credentials, password, auth code + PKCE), **command-backed auth** via existing CLIs, **SSH tunnels**, and **Kubernetes port-forwards** are built in - no extra tools.\n- **Timeline tracing**, **profiling**, and **compare runs** across environments.\n- **Streaming transcripts** and an interactive console for WebSocket and SSE sessions.\n- No cloud sync, no accounts, no telemetry. Everything stays local.\n- There is no AI integration and there will never be.\n\n## Screenshot tour\n\n\u003cdetails\u003e\n\u003csummary\u003eSee the UI in action\u003c/summary\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cstrong\u003eWorkflows\u003c/strong\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"_media/resterm_workflow.png\" alt=\"Screenshot of Resterm with Workflow\" width=\"720\" /\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cstrong\u003eTrace and Timeline\u003c/strong\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"_media/resterm_trace_timeline.png\" alt=\"Screenshot of Resterm with timeline\" width=\"720\" /\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cstrong\u003eProfiler\u003c/strong\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"_media/resterm_profiler.png\" alt=\"Screenshot of Resterm profiler\" width=\"720\" /\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cstrong\u003eExplain\u003c/strong\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"_media/resterm_explain.png\" alt=\"Screenshot of Resterm Explain Tab\" width=\"720\" /\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cstrong\u003eRestermScript\u003c/strong\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"_media/resterm_script.png\" alt=\"Screenshot of Resterm with RestermScript\" width=\"720\" /\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cstrong\u003eOAuth browser demo (old UI design)\u003c/strong\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"_media/oauth.gif\" alt=\"Resterm OAuth flow\" width=\"720\" /\u003e\n\u003c/p\u003e\n\n\u003c/details\u003e\n\n## Quick Start\n\n1. Install Resterm using the command that matches your OS.\n\n   ```bash\n   # Linux/macOS (Homebrew)\n   brew install resterm\n\n   # Linux (install script)\n   curl -fsSL https://raw.githubusercontent.com/unkn0wn-root/resterm/main/install.sh | bash\n   ```\n\n   ```powershell\n   # Windows (PowerShell)\n   iwr -useb https://raw.githubusercontent.com/unkn0wn-root/resterm/main/install.ps1 | iex\n   ```\n\n2. Bootstrap a tiny workspace.\n\n   ```bash\n   mkdir my-api \u0026\u0026 cd my-api\n   resterm init\n   ```\n\n3. Run it and send your first request.\n\n   ```bash\n   resterm\n   ```\n\n   Press `Ctrl+Enter` in the editor to send the highlighted request.\n\nIf you do not want files yet, just run `resterm`, type a URL in the editor, and press `Ctrl+Enter`.\nIf you already have a curl command, paste it into the editor and press `Ctrl+Enter` to import it.\n\n## Key files\n\nThese are the files you will see most often in a Resterm workspace.\n\n- `.http` / `.rest` files store your requests, metadata, and named steps.\n- `resterm.env.json` holds environment variables and secrets for one or more environments.\n- `resterm.env.example.json` is a safe template you can commit and share.\n- `.rts` files contain RestermScript helpers for reuse and small bits of logic.\n- `RESTERM.md` is optional project notes created by `resterm init`.\n\n## Overview\n\nProtocols and transports cover the following.\n\n- `HTTP`, `GraphQL`, `gRPC`, `WebSocket`, and `SSE` are supported out of the box.\n- `SSH tunnels` include host key verification, keep-alives, retries, and persistent sessions.\n- `Kubernetes port-forwards` target pods, services, deployments, and statefulsets with named port resolution, pod readiness checks, retries, and persistent sessions.\n\nWorkspace and files focus on the following.\n\n- `.http` / `.rest` files are discovered automatically and the request list stays in sync as you edit.\n- The request editor includes inline syntax highlighting, search, and contextual metadata hints.\n- Environment files are treated as first-class input. `resterm init` adds _resterm.env.json_ to _.gitignore_ but any custom env files passed via the CLI are **not** ignored automatically.\n\nAutomation and reuse include the following.\n\n- Variables, captures, constants, and multi-step workflows.\n- RestermScript (RTS) and optional JavaScript hooks handle request-time logic.\n- Curl commands and OpenAPI specs can be imported directly into request collections.\n\nDebugging and inspection provide the following.\n\n- `Pretty/raw/header/diff/history` views are available with split panes.\n- Streaming transcripts are recorded and an interactive console is available for WebSocket and SSE.\n- Timeline tracing and profiling help find slow or flaky endpoints.\n\nSecurity and auth cover the following.\n\n- OAuth 2.0 client credentials, password grant, and authorization code + PKCE are supported.\n- Command-backed auth can reuse existing CLIs without wrapping a shell.\n- Tokens can be cached per environment, and OAuth tokens are refreshed automatically.\n\nCustomization includes the following.\n\n- Custom themes and keybindings.\n\n## Navigation \u0026 layout cheat sheet\n\nA few keys that make Resterm feel “native” quickly:\n\n- **Pane focus \u0026 layout**\n  - `Tab` / `Shift+Tab` - move focus between sidebar, editor, and response.\n  - `g+r` - jump to **Requests** (sidebar).\n  - `g+i` - jump to **Editor**.\n  - `g+p` - jump to **Response**.\n  - `g+h` / `g+l` - adjust layout:\n    - When the **left pane** (sidebar) is focused: change sidebar width.\n    - Otherwise: change editor/response split.\n  - `g+v` / `g+s` - toggle response pane between inline and stacked layout.\n  - `g+1`, `g+2`, `g+3` + minimize/restore sidebar, editor, response.\n  - `g+z` / `g+Z` - zoom the focused pane / clear zoom.\n\n- **Environments \u0026 globals**\n  - `Ctrl+E` - switch environments.\n  - `Ctrl+G` - inspect captured globals.\n\n- **Working with responses**\n  - `Ctrl+V` / `Ctrl+U` - split the response pane for side-by-side comparison.\n  - When response pane is focused:\n    - `Ctrl+Shift+C` or `g y` - copy the entire Pretty/Raw/Headers tab\n      to the clipboard (no mouse selection needed).\n  - `g x` - build an Explain preview for the active request without sending it.\n\n---\n\n\u003e [!TIP]\n\u003e **If you only remember three shortcuts…**\n\u003e - `Ctrl+Enter` - send request\n\u003e - `Tab` / `Shift+Tab` - switch panes\n\u003e - `g+p` - jump to response\n\n## Installation\n\n**Linux / macOS (Homebrew)**\n\n```bash\nbrew install resterm\n```\n\n\u003e [!NOTE]\n\u003e Homebrew installs should be updated with Homebrew (`brew upgrade resterm`). The built-in `resterm --update` command is for binaries installed from GitHub releases or install scripts.\n\n**Linux / macOS (Shell script)**\n\n\u003e [!IMPORTANT]\n\u003e Pre-built Linux binaries depend on glibc **2.32 or newer**. If you run an older distro, build from source on a machine with a newer glibc toolchain or upgrade glibc before using the release archives.\n\n```bash\ncurl -fsSL https://raw.githubusercontent.com/unkn0wn-root/resterm/main/install.sh | bash\n```\n\nor with `wget`:\n\n```bash\nwget -qO- https://raw.githubusercontent.com/unkn0wn-root/resterm/main/install.sh | bash\n```\n\n**Windows (PowerShell)**\n\n```powershell\niwr -useb https://raw.githubusercontent.com/unkn0wn-root/resterm/main/install.ps1 | iex\n```\n\nThese scripts detect your architecture, download the latest release, and install the binary.\n\n### Manual installation\n\n\u003e [!NOTE]\n\u003e The manual install helper uses `curl` and `jq`. Install `jq` with your package manager (`brew install jq`, `sudo apt install jq`, etc.).\n\n**Linux / macOS**\n\n```bash\n# Detect latest tag\nLATEST_TAG=$(curl -fsSL https://api.github.com/repos/unkn0wn-root/resterm/releases/latest | jq -r .tag_name)\n\n# Download the matching binary (Darwin/Linux + amd64/arm64)\ncurl -fL -o resterm \"https://github.com/unkn0wn-root/resterm/releases/download/${LATEST_TAG}/resterm_$(uname -s)_$(uname -m)\"\n\n# Make it executable and move it onto your PATH\nchmod +x resterm\nsudo install -m 0755 resterm /usr/local/bin/resterm\n```\n\n**Windows (PowerShell)**\n\n```powershell\n$latest = Invoke-RestMethod https://api.github.com/repos/unkn0wn-root/resterm/releases/latest\n$asset  = $latest.assets | Where-Object { $_.name -like 'resterm_Windows_*' } | Select-Object -First 1\nInvoke-WebRequest -Uri $asset.browser_download_url -OutFile resterm.exe\n# Optionally relocate to a directory on PATH, e.g.:\nMove-Item resterm.exe \"$env:USERPROFILE\\bin\\resterm.exe\"\n```\n\n### From source\n\n```bash\ngo install github.com/unkn0wn-root/resterm/cmd/resterm@latest\n```\n\n## Update\n\n```bash\nresterm --check-update\nresterm --update\n```\n\nThe first command reports whether a newer release is available. The second downloads and installs it (Windows users receive a staged binary to swap on restart).\n\n## Quick Configuration Overview\n\n- Environments are JSON files (`resterm.env.json`) discovered in the request directory, workspace root, or CWD. Dotenv files (`.env`, `.env.*`) are opt-in via `--env-file` and are single-workspace. Prefer JSON when you need multiple environments in one file.\n- Flags you probably reach for most are `--workspace`, `--file`, `--env`, `--env-file`, `--timeout`, `--insecure`, `--follow`, `--proxy`, `--recursive`, `--from-curl`, `--from-openapi`, and `--http-out`.\n- Config is stored at `$HOME/Library/Application Support/resterm`, `%APPDATA%\\resterm`, or `$HOME/.config/resterm` and can be overridden with `RESTERM_CONFIG_DIR`.\n\n## Collections\n\nYou can export a workspace into a Git-friendly Resterm bundle. The exported bundle always includes a `manifest.json` with checksums, so imports can verify file integrity before writing anything.\n\nWhen Resterm sees `resterm.env.example.json` in your workspace, it includes that file as-is. If only `resterm.env.json` exists, Resterm generates `resterm.env.example.json` automatically and replaces values with `REPLACE_ME` placeholders so secrets are not exported.\n\n### Export a bundle\n\n```bash\nresterm collection export \\\n  --workspace ./my-api \\\n  --out ./shared/my-api-bundle \\\n  --recursive \\\n  --name \"my-api-v1\"\n```\n\n### Import a bundle\n\n```bash\nresterm collection import \\\n  --in ./shared/my-api-bundle \\\n  --workspace ./my-local-api\n```\n\nIf you want to preview actions first, you can run:\n\n```bash\nresterm collection import \\\n  --in ./shared/my-api-bundle \\\n  --workspace ./my-local-api \\\n  --dry-run\n```\n\nIf files already exist and should be replaced intentionally, add `--force`.\n\n## Inline curl import\n\nPaste a curl command into the editor and press `Ctrl+Enter` to convert it into a structured request. Resterm understands common flags, merges repeated data segments, and keeps multipart uploads intact.\n\n```bash\ncurl \\\n  --compressed \\\n  --url \"https://httpbin.org/post?source=resterm\u0026case=multipart\" \\\n  --request POST \\\n  -H \"Accept: application/json\" \\\n  -H \"X-Client: resterm-dev\" \\\n  --user resterm:test123 \\\n  -F file=@README.md \\\n  --form-string memo='Testing resterm inline curl\nwith multiline value' \\\n  --form-string meta='{\"env\":\"test\",\"attempt\":1}'\n```\n\nIf you copied the command from a shell, prefixes like `sudo` or `$` are ignored automatically.\n\n## RestermScript\n\nRestermScript (RTS) is a small expression language built specifically for Resterm. Because it targets Resterm features directly, it can evolve alongside Resterm and stay symbiotic with the request format, workflows, and directives. JavaScript hooks are still available when you want them, but RTS is the default because it is readable, predictable, and focused on Resterm’s domain.\n\nQuick example (RTS module + request):\n\n```rts\n// rts/helpers.rts\nmodule helpers\nexport fn authHeader(token) {\n  return token ? \"Bearer \" + token : \"\"\n}\n```\n\n```http\n# @use ./rts/helpers.rts\n# @when env.has(\"feature\")\n# @assert response.statusCode == 200\nGET https://api.example.com/users/{{= vars.get(\"user\") }}\nAuthorization: {{= helpers.authHeader(vars.get(\"auth.token\")) }}\n```\n\nFull reference: [`docs/restermscript.md`](docs/restermscript.md).\n\n## Deep dive\n\n#### OAuth 2.0\n\nResterm supports client credentials, password grant, and authorization code + PKCE. For auth code flows, it opens your system browser, spins up a local callback server on `127.0.0.1`, captures the redirect, and exchanges the code automatically. Tokens are cached per environment and refreshed when they expire. Docs: [`docs/resterm.md#oauth-20-directive`](./docs/resterm.md#oauth-20-directive) and `_examples/oauth2.http`.\n\n#### Workflows and scripting\n\nChain requests with `@workflow` and `@step`, pass data between steps, and add lightweight JS hooks where needed. Docs + sample: [`docs/resterm.md#workflows-multi-step-workflows`](./docs/resterm.md#workflows-multi-step-workflows) and `_examples/workflows.http`.\n\n#### Compare runs\n\nRun the same request across environments with `@compare` or `--compare`, then diff responses side by side with `g+c`. Docs: [`docs/resterm.md#compare-runs`](./docs/resterm.md#compare-runs).\n\n#### Tracing and timeline\n\nAdd `@trace` with budgets to capture DNS, connect, TLS, TTFB, and transfer timings. Resterm visualizes overruns and can export spans to OpenTelemetry. Docs: [`docs/resterm.md#timeline--tracing`](./docs/resterm.md#timeline--tracing).\n\n#### Streaming (WebSocket and SSE)\n\nUse `@websocket` with `@ws` steps or `@sse` to script and record streams. The Stream tab keeps transcripts and includes an interactive console. Docs: [`docs/resterm.md#streaming-sse--websocket`](./docs/resterm.md#streaming-sse--websocket).\n\n#### gRPC\n\nResterm supports unary and streaming calls with transcripts, metadata, and body expansion for gRPC files. Docs: [`docs/resterm.md#grpc`](./docs/resterm.md#grpc).\n\n#### OpenAPI import\n\nConvert OpenAPI 3 specs into Resterm-ready `.http` collections from the CLI with `--from-openapi`. Docs: [`docs/resterm.md#importing-openapi-specs`](./docs/resterm.md#importing-openapi-specs).\n\n#### Collection sharing\n\nExport a portable Resterm-native bundle with `resterm collection export` and import it into another workspace with `resterm collection import`. Docs: [`docs/resterm.md#collection-sharing`](./docs/resterm.md#collection-sharing).\n\n#### Curl import\n\nConvert curl commands into `.http` files from the CLI with `--from-curl`. Docs: [`docs/resterm.md#importing-curl-commands`](./docs/resterm.md#importing-curl-commands).\n\n#### SSH tunnels\n\nRoute HTTP, gRPC, WebSocket, and SSE traffic through bastions with `@ssh` profiles. Docs: [`docs/resterm.md#ssh-tunnels`](./docs/resterm.md#ssh-tunnels) and `_examples/ssh.http`.\n\n#### Kubernetes port-forwards\n\nRoute HTTP, gRPC, WebSocket, and SSE traffic through Kubernetes with `@k8s` profiles targeting pods/services/deployments/statefulsets. Docs: [`docs/resterm.md#kubernetes-port-forwards`](./docs/resterm.md#kubernetes-port-forwards) and `_examples/k8s.http`.\n\n#### Theming and bindings\n\nCustomize colors and keybindings via `themes/*.toml` and `bindings.toml` or `bindings.json` under the config directory. Docs: [`docs/resterm.md#theming`](./docs/resterm.md#theming) and [`docs/resterm.md#custom-bindings`](./docs/resterm.md#custom-bindings).\n\n## Documentation\n\nThe full reference, including request syntax, metadata, directive tables, scripting APIs, transport settings, and advanced workflows, lives in [`docs/resterm.md`](./docs/resterm.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funkn0wn-root%2Fresterm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Funkn0wn-root%2Fresterm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funkn0wn-root%2Fresterm/lists"}