PHPackages                             krubio/perfect-web-kit - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [HTTP &amp; Networking](/categories/http)
4. /
5. krubio/perfect-web-kit

ActiveLibrary[HTTP &amp; Networking](/categories/http)

krubio/perfect-web-kit
======================

Shared PHP 8.5 web-UI toolkit: typed HTTP API client, request/session helpers, fail-closed auth guard, PSR-3 error handling, env loader, and asset utilities.

v0.5.0(1mo ago)01.6k↓100%MITPHPPHP ^8.5CI passing

Since Apr 21Pushed 1mo agoCompare

[ Source](https://github.com/benanamen/perfect-web-kit)[ Packagist](https://packagist.org/packages/krubio/perfect-web-kit)[ RSS](/packages/krubio-perfect-web-kit/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependencies (3)Versions (7)Used By (0)

perfect-web-kit
===============

[](#perfect-web-kit)

Shared PHP 8.5 web-UI toolkit used by the Consigngold storefront (`curser-pos-web`) and SaaS admin (`curser-pos-admin`). It centralizes cross-cutting infrastructure that was previously duplicated and drifted between the two UI applications.

Contents
--------

[](#contents)

ComponentPurpose`PerfectApp\WebKit\Http\ApiClient`JSON HTTP client with required timeouts, typed responses, transport exceptions, and bounded retries on idempotent requests only.`PerfectApp\WebKit\Http\ApiResponse`Immutable response with classified status helpers.`PerfectApp\WebKit\Http\ApiClientOptions`Validated options: base URL, connect/total timeout, TLS mode, retry policy.`PerfectApp\WebKit\Http\Cookie\CookieJar`Parse `Set-Cookie` headers and rebuild a single `Cookie` request header.`PerfectApp\WebKit\Request\StringKeyed`Narrow mixed-key arrays to string-keyed maps.`PerfectApp\WebKit\Request\ServerParam`Typed accessor over a `$_SERVER` snapshot.`PerfectApp\WebKit\Request\RequestValue`Narrow mixed values to string/int/float/bool without unsafe casts.`PerfectApp\WebKit\Session\SessionCookieConfig`Secure, `__Host-`-capable cookie parameter setter for `session_*`.`PerfectApp\WebKit\Auth\FailClosedAuthGuard`"Deny unless explicitly authenticated" guard for UI requests.`PerfectApp\WebKit\Bootstrap\PhpErrorHandling`PSR-3 error/shutdown handler install, with dev/prod display toggle.`PerfectApp\WebKit\Bootstrap\EnvFileLoader`Dotenv parser that produces an immutable `EnvConfig`; does not mutate `$_ENV`.`PerfectApp\WebKit\Logging\BootstrapLogger`Tiny STDERR PSR-3 logger for pre-container bootstrap use.`PerfectApp\WebKit\Util\UsDateDisplay`mm-dd-YYYY / dd-mm-YYYY formatting with naive-midnight and timezone rules.Assets
------

[](#assets)

- `assets/sortable-tables.js` — PHP-natural-order client-side `.data-table` sort.
- `assets/date-from-to-sync.js` — Keeps `#from` / `#to` date-range inputs coherent on the client.

Storefront / admin ship these files from their asset pipelines; they should be served directly by the web server with long-lived cache headers.

Bin
---

[](#bin)

- `vendor/bin/check-git-path-case-collisions.php` — fail CI when tracked paths collide case-insensitively.
- `vendor/bin/apply-codeception-windows-regex-fix.php` — patch vendor Codeception so `codecept run functional` works on Windows / PHP 8.5.

Testing
-------

[](#testing)

```
composer install
composer test
composer phpstan
```

###  Health Score

44

—

FairBetter than 90% of packages

Maintenance90

Actively maintained with recent releases

Popularity22

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity45

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

5

Last Release

49d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1039435?v=4)[benanamen](/maintainers/benanamen)[@benanamen](https://github.com/benanamen)

---

Top Contributors

[![benanamen](https://avatars.githubusercontent.com/u/1039435?v=4)](https://github.com/benanamen "benanamen (8 commits)")

---

Tags

psr-7psr-3http clientenvsessionauth-guard

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/krubio-perfect-web-kit/health.svg)

```
[![Health](https://phpackages.com/badges/krubio-perfect-web-kit/health.svg)](https://phpackages.com/packages/krubio-perfect-web-kit)
```

###  Alternatives

[symfony/http-kernel

Provides a structured process for converting a Request into a Response

8.1k853.6M8.2k](/packages/symfony-http-kernel)[react/http

Event-driven, streaming HTTP client and server implementation for ReactPHP

78927.2M451](/packages/react-http)[api-platform/metadata

API Resource-oriented metadata attributes and factories

244.5M180](/packages/api-platform-metadata)[phpro/http-tools

HTTP tools for developing more consistent HTTP implementations.

28146.3k](/packages/phpro-http-tools)[mezzio/mezzio-swoole

Swoole support for Mezzio

92247.8k3](/packages/mezzio-mezzio-swoole)[mezzio/mezzio-session

Session container and middleware for PSR-7 applications

241.1M20](/packages/mezzio-mezzio-session)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
