API Test CLI
A command-line tool for testing HTTP APIs. Send requests, save them, create templates, search response content, and optionally analyze response sentiment.
Installation
pip install apitest-cli
Usage
Run apitest --help for a list of commands. Below are examples:
Send a GET Request
apitest get https://jsonplaceholder.typicode.com/posts
Search in Response
apitest get https://jsonplaceholder.typicode.com/posts --search "title"
Analyze Sentiment
apitest get https://jsonplaceholder.typicode.com/posts --analyze
Send a POST Request
apitest post https://jsonplaceholder.typicode.com/posts --data '{"title": "Hello", "body": "Test"}' --header "Content-Type: application/json"
Save a Request
apitest save myrequest
Replay a Saved Request
apitest replay myrequest
Create a Template
apitest template mytemplate --url https://jsonplaceholder.typicode.com/posts --method GET --header "Content-Type: application/json"
Use a Template
apitest use-template mytemplate
Features
- Send GET/POST requests with custom headers and JSON data.
- Save and replay requests.
- Create and use request templates.
- Search keywords in responses with highlighted results.
- Optional sentiment analysis of response text (English only).
- Responses saved as JSON files in
responses/directory.
Requirements
- Python 3.8+
- Install dependencies:
pip install click requests rich textblob - Download TextBlob corpora (optional):
python -m textblob.download_corpora
License
MIT
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
apitest_cli-0.1.1.tar.gz
(4.9 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file apitest_cli-0.1.1.tar.gz.
File metadata
- Download URL: apitest_cli-0.1.1.tar.gz
- Upload date:
- Size: 4.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/6.2.0 CPython/3.10.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
418a3679cf46f0d61e48f973f7925ebaae7ee156d93e3eb1b1a5347c426e7d1a
|
|
| MD5 |
656ea58dd9b7eab25e5a5d25eb233f5e
|
|
| BLAKE2b-256 |
364e6d66e0714b32bb7b0da59d75e8ba282744378f5bf6b1250c2fcba9e88d3c
|
File details
Details for the file apitest_cli-0.1.1-py3-none-any.whl.
File metadata
- Download URL: apitest_cli-0.1.1-py3-none-any.whl
- Upload date:
- Size: 5.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/6.2.0 CPython/3.10.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
743a457c79a2c48cedec60bcb85df7737df7776958c9ac2266f98d0394fada82
|
|
| MD5 |
3e7ded1bb315abe68073bec2c012b196
|
|
| BLAKE2b-256 |
c5c1a160735ae1a4b2d49b4dda31d47949f8396e26b720e7ce5081c91300ae57
|