Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Http Laravel Package

delight-im/http

A lightweight, framework-agnostic HTTP utility library for PHP. It provides simple objects for requests, responses, URLs, and headers, plus helpers for methods, status codes, and content types, so you can read and build HTTP messages in any PHP application.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • API contract standardization. A single source of truth for HTTP status codes, methods, and header names lets you enforce consistent semantics (e.g., 422 for validation, 409 for conflicts) across services, SDKs, and docs — a decision that otherwise drifts team by team.
  • Build vs. buy vs. copy. At 18 stars, 0 dependents, and a low composite score (0.21), this is not a strategic dependency. The real product decision is whether to (a) vendor the constants, (b) adopt the package pinned, or (c) use framework-native equivalents (Laravel's Symfony\Component\HttpFoundation\Response, PSR-7/PSR-17 implementations). Recommend "copy or vendor" over "depend on."
  • Error-taxonomy and client-facing behavior. Informs the decision on how errors surface to API consumers — machine-readable codes, retry semantics (429/503 + Retry-After), and idempotency headers — which directly affects SDK ergonomics and support load.
  • Gateway / BFF and middleware design. Useful as a shared vocabulary when specifying middleware, rate limiting, caching, and webhook signature handling, especially in polyglot or framework-light services.
  • Roadmap sequencing for platform hygiene. Cheap to adopt now; lets you defer a heavier "API governance" initiative until you actually need schema linting, contract tests, or a generated OpenAPI pipeline.
  • Use cases: internal service scaffolding, API style-guide enforcement, documentation generators, test fixtures asserting status/header correctness, and small CLI or edge services without a full HTTP stack.

When to Consider This Package

Consider it when:

  • You are on PHP without a framework, or on a framework that does not cleanly expose HTTP constants, and you want readable, non-magic-number code for status codes, methods, and headers.
  • You need a tiny, MIT-licensed, dependency-free vocabulary layer — no client, no PSR implementation, no runtime machinery.
  • You want to standardize terminology across a small team before investing in formal API governance.
  • You are prototyping and want to defer lock-in to a specific HTTP abstraction.

Look elsewhere when:

  • You are on Laravel or Symfony — you already ship HttpFoundation/symfony/http-foundation and native constants; adding a parallel vocabulary creates two sources of truth.
  • You need PSR-7/PSR-15/PSR-18 messages, middleware, or clients — this package is not that. Use guzzlehttp/psr7, laminas-diactoros, symfony/http-client.
  • You are on PHP 8.1+ and native backed enums already solve the constant problem with better type safety.
  • Supply-chain or maintenance risk matters — 18 stars and 0 dependents means no ecosystem pressure to patch issues; assume you own the code. Do not put it on a critical path without vendoring and a review SLA.
  • You need security responsiveness, long-term support, or a vendor who will answer a CVE within days.

How to Pitch It (Stakeholders)

Executive summary. A micro-library (MIT) that names HTTP status codes, methods, and headers for PHP. It is not a client, framework, or platform — it is vocabulary. Cost is negligible; risk is supply-chain, not licensing.

Recommendation. Treat it as a reference and convenience layer, not a dependency of record. Vendor the constants or wrap them behind our own enum/interface, so we get consistency without coupling to an unmaintained package.

Why it matters (business). Inconsistent status codes and header conventions are a recurring source of client bugs, SDK churn, and support tickets. A shared vocabulary is a cheap, durable fix that compounds as we add endpoints — and it makes API style guides enforceable rather than aspirational.

For engineering. Removes magic numbers, gives one place to review HTTP semantics, and is trivial to fork or inline (≈constants only). Adopt behind an internal interface and pin/vendor it; treat upstream as read-only reference.

Caveats to state openly. Low adoption (18 stars, 0 dependents, score 0.21) means no community backstop. Do not adopt it where framework-native constants or PSR-7 already exist, and do not let it become the reason we skip a real HTTP abstraction when we need one.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
shitoudev/permissionmanager
johannesclimacus/laravel-tui
hocvt/seotools
vitalybaev/sypexgeo
amphibee/themosis-ignition
gito-me/fast-excel
frankyso/laravel-ipaymu
geolize-studio/laravel-chile
boomerangui/chat
jinas/dhivatar
store-doc/laravel-storage-driver
plus-it/laravel-translation-manager
diephp/perhaps
diephp/telegraph
osmaviation/spreadsheet
microsoft/fluentui-system-icons
mmccook/php-json-canonicalization-scheme
middlewares/firewall
qubiqx/montapacking
nyoncode/laravel-package-console