THIS IS STILL A WORK IN PROGRESS
Rust-based HTTP implementation for Emacs.
Reel strives to be non-interactive HTTP library for Emacs.
Emacs’s built-in url.el library is insufficient for a lot of uses and arcane to
use, and other popular libraries either depend on url.el or curl
.
My goal is to implement an HTTP client in Emacs that has a similar API to other programming languages. It shouldn’t use buffers excessively and it shouldn’t depend on the global environment for behavior.
- DONE Basic HTTP requests
- TODO Multipart form requests with file data
- TODO Send requests through a proxy
- TODO Cookies and sessions
- TODO Asynchronous requests
- TODO Streaming
- Basic synchronous HTTP requests
- REST clients
- REST server
Reel’s API is roughly based off of JavaScript’s fetch API.
;; GETs "https://example.com" synchronously
(reel "https://example.com")
A reel
request returns a reel-response
struct, with status
, headers
, and body
slots.
;; makes a POST request with headers
(reel "https://example.com"
:method "POST"
:headers '(("Content-Type" . "application/json"))
:body (json-serialize '(:id 123)))
:body
can also be an alist for form submission. Will raise an error if the alist contains anything but strings:
(reel "https://example.com"
:method "POST"
:body '(("key" . "value"))