{"id":37130761,"url":"https://github.com/nativebpm/httpstream","last_synced_at":"2026-01-14T15:01:57.296Z","repository":{"id":317067724,"uuid":"1065859692","full_name":"nativebpm/httpstream","owner":"nativebpm","description":"Stream-first HTTP client for Go","archived":false,"fork":false,"pushed_at":"2025-10-11T06:44:17.000Z","size":21,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-10-11T23:07:46.882Z","etag":null,"topics":["fluent-api","go","golang","http","http-client","http-requests","httpclient","httprequest","io-pipe","low-overhead","middleware","multipart","multipart-formdata","pipe","streaming"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nativebpm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-28T15:15:44.000Z","updated_at":"2025-10-11T06:44:20.000Z","dependencies_parsed_at":null,"dependency_job_id":"e812f87b-47d9-45ad-933a-f455d576150e","html_url":"https://github.com/nativebpm/httpstream","commit_stats":null,"previous_names":["nativebpm/http-client","nativebpm/httpclient","nativebpm/httpstream","nativebpm/streamhttp"],"tags_count":39,"template":false,"template_full_name":null,"purl":"pkg:github/nativebpm/httpstream","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nativebpm%2Fhttpstream","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nativebpm%2Fhttpstream/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nativebpm%2Fhttpstream/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nativebpm%2Fhttpstream/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nativebpm","download_url":"https://codeload.github.com/nativebpm/httpstream/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nativebpm%2Fhttpstream/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28424039,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T13:30:50.153Z","status":"ssl_error","status_checked_at":"2026-01-14T13:29:08.907Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["fluent-api","go","golang","http","http-client","http-requests","httpclient","httprequest","io-pipe","low-overhead","middleware","multipart","multipart-formdata","pipe","streaming"],"created_at":"2026-01-14T15:01:56.475Z","updated_at":"2026-01-14T15:01:57.283Z","avatar_url":"https://github.com/nativebpm.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# httpstream — Stream-first HTTP client for Go\n\nEfficient, zero-buffer streaming for large HTTP payloads — built on top of `net/http`.\n\n```bash\ngo get github.com/nativebpm/httpstream\n```\n\n## Overview\n\n`httpstream` provides a minimal, streaming-oriented API for building HTTP requests without buffering entire payloads in memory.  \nIdeal for large JSON bodies, multipart uploads, generated archives, or continuous data feeds.\n\n### Key Features\n\n- Stream data directly via `io.Pipe` — no intermediate buffers\n- Constant memory usage (`O(1)`), regardless of payload size\n- Natural backpressure (writes block when receiver is slow)\n- Thin `net/http` wrapper — fully compatible\n- Middleware support: `func(http.RoundTripper) http.RoundTripper`\n- Fluent API for readability (`GET`, `POST`, `Multipart`, etc.)\n- No goroutine leaks, no globals\n\n## How It Works\n\n`httpstream` connects your writer directly to the HTTP transport.  \nData is transmitted as it’s produced — the server can start processing immediately,  \nwithout waiting for the full body to be buffered.\n\n```mermaid\nflowchart TB\n    subgraph P[\"io.Pipe()\"]\n        PW[\"PipeWriter\"] --\u003e PR[\"PipeReader\"]\n    end\n\n    W[\"Writer (goroutine)\"] --\u003e|\"writes into\"| P\n    P --\u003e|\"provides data to\"| R[\"Reader\"]\n```\n\n## Why Streaming Matters\n\nTraditional HTTP clients buffer request bodies entirely before sending.  \nFor large or dynamically generated payloads, this leads to:\n\n- High memory usage (`O(n)` where n = payload size)\n- Slow transmission start (server waits for full upload)\n- Out-of-memory errors in constrained environments\n\n`httpstream` eliminates these issues by design.\n\n## Examples\n\n- [Streaming multipart upload](examples/multipart_streaming_example)\n- [Without fluent API (for comparison)](examples/multipart_streaming_example/multipart_streaming_without_fluent_api)\n- [Logger middleware](examples/logger_slog_example)\n- [Gotenbergo Client: Built on httpstream for efficient multipart uploads](https://github.com/nativebpm/gotenberg)\n\n## License\n\nMIT — see [`LICENSE`](../LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnativebpm%2Fhttpstream","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnativebpm%2Fhttpstream","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnativebpm%2Fhttpstream/lists"}