A Postman-like WebSocket and HTTP client inside Neovim. Compose requests in familiar buffer types, send them with a keypress, and inspect responses in a split window — all without leaving the editor.
Two components communicate over JSON Lines via stdin/stdout:
- Rust CLI binary (
nvim-postman) — handles real WebSocket connections (viatokio-tungstenite) and HTTP requests (viareqwest), with full TLS/mTLS support. - Neovim Lua plugin — provides file-type detection, keybindings, output split windows, and configuration.
git clone https://github.com/your-name/nvim-postman \
~/.local/share/nvim/site/pack/plugins/start/nvim-postman
cd ~/.local/share/nvim/site/pack/plugins/start/nvim-postman && makeWith lazy.nvim
{
"your-name/nvim-postman",
build = "make",
}- Build the Rust client:
cargo build --release --manifest-path rust-client/Cargo.toml - Copy
rust-client/target/release/nvim-postmanto a directory on your$PATH. - Copy the plugin files into your Neovim
packpath.
- Create a
.wssfile. The first line is the WebSocket URL; subsequent lines are JSON payloads to send.
wss://echo.example.com/ws
{"message": "hello"}
{"message": "world"}
- Press
<F7>to connect — a split window opens showing connection status. - Position cursor on a JSON payload and press
<F6>to send it. Response timing and size are displayed. - Press
<F5>to close the connection.
- Create a
.httpfile with a JSON object containingurl,method, and optionalheaders/body:
{
"url": "https://api.example.com/data",
"method": "POST",
"headers": {
"Authorization": "Bearer token"
},
"body": "{\"key\": \"value\"}"
}- Press
<F7>to send the request. The response appears in the split window with timing and size.
Run :BurstSend <count> <interval_ms> to send the current JSON payload repeatedly.
| Command | Description |
|---|---|
:NvimPostmanWsConnect |
Connect to WebSocket URL on line 1 |
:NvimPostmanWsSend |
Send the current JSON payload |
:NvimPostmanWsClose |
Close the WebSocket connection |
:NvimPostmanHttpSend |
Send HTTP request from current buffer |
:BurstSend <n> <ms> |
Send payload <n> times at <ms> interval |
:NvimPostmanInstall |
Download pre-built binary for your platform |
require("nvim-postman").setup({
rust_binary = "nvim-postman", -- path to the Rust binary
cert = nil, -- TLS client certificate (PEM)
key = nil, -- TLS client key (PEM)
ca = nil, -- CA certificate bundle (PEM)
timeout_ms = 5000, -- request timeout
output_max_lines = 5000, -- max lines in output buffer
})Responses are displayed with metadata: (145ms | 0.5 KB): followed by the pretty-printed body. Errors, connection status, and closure events are also shown.
make test # run all tests
make test-rust # run Rust integration tests
make test-lua # run Lua unit tests
make clean # remove build artifactsMIT