Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/violetbuse/httpp
A gleam http client with support for server-sent events and long-running requests, based on hackney
https://github.com/violetbuse/httpp
erlang gleam gleam-community
Last synced: about 1 month ago
JSON representation
A gleam http client with support for server-sent events and long-running requests, based on hackney
- Host: GitHub
- URL: https://github.com/violetbuse/httpp
- Owner: VioletBuse
- Created: 2024-06-05T21:56:03.000Z (5 months ago)
- Default Branch: master
- Last Pushed: 2024-06-18T12:12:00.000Z (5 months ago)
- Last Synced: 2024-10-12T18:41:35.769Z (about 1 month ago)
- Topics: erlang, gleam, gleam-community
- Language: Gleam
- Homepage: https://hexdocs.pm/httpp
- Size: 38.1 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# httpp
[![Package Version](https://img.shields.io/hexpm/v/httpp)](https://hex.pm/packages/httpp)
[![Hex Docs](https://img.shields.io/badge/hex-docs-ffaff3)](https://hexdocs.pm/httpp/)```sh
gleam add httpp
```
```gleam
import httpp/async
import gleam/http/request
import gleam/uri
import gleam/bytes_builder
import gleam/erlang/processpub fn main() {
let response_subject = uri.parse("https://example.com")
|> request.from_uri
|> request.map(bytes_builder.from_string)
|> async.send// asynchronously send an http request and receive it later
process.receive(response_subject, 2000)
}
```Further documentation can be found at .
## Development
```sh
gleam run # Run the project
gleam test # Run the tests
gleam shell # Run an Erlang shell
```