I built this project as a lightweight command-line HTTP client: a small, terminal-based alternative to using a full API tool when I want to quickly send requests, inspect responses, and reuse saved calls.
The goal of this project was to practice building a useful developer tool with a clear command interface, persistent local state, and practical HTTP request handling.
api_client lets me send HTTP requests from the terminal and inspect the response directly. It currently supports:
GET,POST,PUT, andDELETErequests- Custom request headers
- Query parameters
- Plain text request bodies
- JSON request bodies
- Response status, headers, and body output
- Saving named requests locally
- Reusing saved requests
- Listing and deleting saved requests
Saved requests are stored locally in:
~/.api_client/requests.json
I wanted to demonstrate that I can take a small product idea from a README-level specification to a working CLI tool. This project gave me a focused way to work with:
- Python CLI design with
argparse - HTTP requests using
requests - JSON serialization and local persistence
- Subcommands such as
send,save,run,list, anddelete - Basic package configuration with
setuptools - Practical error handling and command flow design
Send a request:
api_client send --method GET --URI https://example.comSend headers:
api_client send --method GET --URI https://example.com --headers Accept:application/jsonSend a JSON body:
api_client send --method POST --URI https://example.com --json-body '{"name": "Jonathon"}'Save a named request:
api_client save example-get --method GET --URI https://example.comRun a saved request:
api_client run example-getList saved requests:
api_client listDelete a saved request:
api_client delete example-getFrom the project directory:
pip install .Install directly from GitHub:
pip install git+https://github.com/jonathon-chew/api-client.gitThe package installs a console command:
api_clientThis is my v0.1.0 MVP. The core workflow is in place: I can send requests, inspect responses, save named requests, and reuse them later.
There are still areas I would improve next, especially around friendlier error messages, prettier saved-request output, stronger tests, and more polished response formatting.
The next things I would add are:
- Better validation for malformed headers and parameters
- Cleaner output for
listandget - Friendlier handling of HTTP errors
- Tests for request parsing and saved-request persistence
- Auth helpers
- File uploads
- Response timing metrics
This project shows my ability to break down a small developer-tooling problem, design a usable CLI interface, work with HTTP and JSON data, persist local configuration, and package a Python script as an installable command-line tool.