Posting is an powerful HTTP client which brings Postman-like functionality to your terminal.
It's designed for those who prefer working in a terminal environment and enjoy fast, keyboard-centric user interfaces.
![screenshot-01jul24-2](https://private-user-images.githubusercontent.com/5740731/344808950-d0e9f640-a0ba-41af-b2ae-7bda67e18026.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjU3MzAyNjcsIm5iZiI6MTcyNTcyOTk2NywicGF0aCI6Ii81NzQwNzMxLzM0NDgwODk1MC1kMGU5ZjY0MC1hMGJhLTQxYWYtYjJhZS03YmRhNjdlMTgwMjYucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDkwNyUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA5MDdUMTcyNjA3WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9MDg4NzZlNTJmNWExMWYwZmRlYmZjYjJmM2UzODZlZWUyOTQxNjZlYTc3N2YxY2I3ZWYyYzJjMWZmMGUzZTJkYSZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.Bzr35hzRu3cnH3WFFDbkk6FEng8t7_uifz-sPWOLDI8)
Posting is still under development and not yet feature complete.
Some notable missing features include variables/environments, pre/post-request scripts, and the ability to send form data and files.
Posting can be installed via pipx
:
pipx install posting
Python 3.11 or later is required.
More installation methods (brew
, etc) will be added soon.
Requests can be stored inside "collections" on your file system. A collection is simply a directory containing one or more requests.
Each request is stored as a simple YAML file, suffixed with .posting.yaml
- easy to read, understand, and version control!
Here's a quick example of a *.posting.yaml
file.
name: Create user
description: Adds a new user to the system.
method: POST
url: https://jsonplaceholder.typicode.com/users
body: |-
{
"firstName": "John",
"lastName": "Doe",
"email": "[email protected]"
}
headers:
- name: Content-Type
value: application/json
- name: Some-Header
value: Some value
enabled: false
params:
- name: sendWelcomeEmail
value: 'true'
To open a collection, simply pass the path to the --collection
option when launching Posting:
posting --collection path/to/collection
The supplied directory will be recursively searched for files matching **/*.posting.yaml
, and they'll appear in the sidebar.
If you don't supply a directory, Posting will use the default collection directory.
You can check where this is by running posting locate collection
.
To save the currently open request, press ctrl+s.
Posting can be navigated using either mouse or keyboard.
Jump mode is the fastest way to get around in Posting.
Press ctrl+o to enter jump mode.
A key overlay will appear on the screen, allowing you to jump to any widget by pressing the corresponding key.
jumpmode.mov
tab and shift+tab will move focus between widgets, and j/k will move around within a widget.
Important keyboard shortcuts are displayed at the bottom of the screen.
However, there are many other shortcuts available - these will be documented soon.
Press ctrl+m to expand the section which currently has focus (the request or response section). Press it again to reset the UI.
Some functionality in Posting doesn't warrant a dedicated keyboard shortcut (for example, switching to a specific theme), and can instead be accessed via the command palette.
To open the command palette, press ctrl+p.
posting-theme-switching-10jun24.mov
Posting can be configured using a configuration file, environment variables, and/or .env
files.
Configuration values are loaded in the following order of precedence (highest to lowest):
- Configuration file
- Environment variables
.env
files
The range of available configuration will be greatly expanded in the future.
You can write configuration for Posting using YAML.
The location of the config file can be checked using the command posting locate config
.
Here's an example configuration file:
theme: galaxy
layout: horizontal
heading:
visible: true
show_host: false
All configuration values can also be set as environment variables.
Simply prefix the name of the config with POSTING_
and set it as an environment variable.
For nested configuration values, use __
as the delimiter. So to set heading.visible
to false
, you can set the environment variable POSTING_HEADING__VISIBLE=false
.
For example, to set the theme to galaxy
, you can set the environment variable POSTING_THEME=galaxy
.
Posting also supports .env
(dotenv) files, which are useful if you want to keep your configuration in a file rather than in your shell's environment variables.
You can tell Posting to use a .env
file using the --env-file
option.
Here's an example .env
file:
POSTING_THEME="cobalt"
POSTING_LAYOUT="vertical"
POSTING_HEADING__VISIBLE="false"
Config Key | Environment Variable | Possible Values | Default | Description |
---|---|---|---|---|
theme |
POSTING_THEME |
"posting" , "galaxy" , "monokai" , "solarized-light" , "nautilus" , "nebula" , "alpine" , "cobalt" , "twilight" , "hacker" |
"posting" |
Sets the theme of the application. |
layout |
POSTING_LAYOUT |
"vertical" , "horizontal" |
"horizontal" |
Sets the layout of the application. |
heading.visible |
POSTING_HEADING__VISIBLE |
true , false |
true |
Show/hide the app header. |
heading.show_host |
POSTING_HEADING__SHOW_HOST |
true , false |
true |
Show/hide the hostname in the app header. |
animation |
POSTING_ANIMATION |
"none" , "basic" , "full" |
"none" |
Controls the animation level. |
- Keyboard Friendly: Navigate and iterate on your APIs using simple keyboard shortcuts.
- File System Storage: Your collections are saved as files, meaning you can easily sync them using version control or your favorite cloud provider.
- Multiplatform: Run on MacOS, Linux and Windows.
- Template Variables: Define variables and substitute them into your requests.
- Powerful Text and JSON Editor: Offers tree-sitter powered syntax highlighting, undo/redo, copy/paste, and more.
- Runs Over SSH: Send requests from a remote host via SSH.
- Your Idea Here: Please let me know if you have opinions on the features above, or any other ideas!