Restish is a CLI for interacting with REST-ish HTTP APIs with some nice features built-in, like always having the latest API resources, fields, and operations available when they go live on the API without needing to install or update anything.
Every API deserves a CLI for quick access and for power users to script against the service. Building CLIs from scratch is a pain. Restish provides one tool your users can install that just works for multiple APIs and is always up to date, because the interface is defined by the server. See how it compares to cURL and HTTPie.
Start with the guide to learn how to install and configure Restish as well as getting an overview of all of its features.
- HTTP/2 (RFC 7540) with TLS by default with fallback to HTTP/1.1
- Generic HEAD/GET/POST/PUT/PATCH/DELETE verbs like
curl
or HTTPie - Generated commands for CLI operations, e.g.
restish my-api list-users
- Automatically discovers API descriptions
- Supported formats
- OpenAPI 3.0 / 3.1 and JSON Schema
- Automatic configuration of API auth if advertised by the API
- Shell command completion for Bash, Fish, Zsh, Powershell
- Automatic pagination of resource collections via RFC 5988
prev
andnext
hypermedia links - API endpoint-based auth built-in with support for profiles:
- Content negotiation, decoding & unmarshalling built-in:
- JSON (RFC 8259, https://www.json.org/)
- YAML (https://yaml.org/)
- CBOR (RFC 7049, http://cbor.io/)
- MessagePack (https://msgpack.org/)
- Amazon Ion (http://amzn.github.io/ion-docs/)
- Gzip (RFC 1952), Deflate (RFC 1951), and Brotli (RFC 7932) content encoding
- Automatic retries with support for
Retry-After
andX-Retry-In
headers when APIs are rate-limited. - Standardized hypermedia parsing into queryable/followable response links:
- HTTP Link relation headers (RFC 5988)
- HAL
- Siren
- Terrifically Simple JSON
- JSON:API
- Local caching that respects RFC 7234
Cache-Control
andExpires
headers - Client-side bulk resource management (like git for API resources)
- CLI shorthand for structured data input (e.g. for JSON)
- Shorthand query response filtering & projection
- Colorized prettified readable output
- Fast native zero-dependency binary