juststeveking/companies-house-laravel
A Laravel client for the UK Companies House API, giving you a clean, fluent interface to look up company profiles, officers, filing history, and related records. Configuration is handled through a simple config file, with support for API authentication and typical Laravel conventions.
Architecture fit. This is an anti-corruption layer, not a domain model. The package wraps the UK Companies House REST API behind a Laravel facade and a publishable config file: no migrations, no Eloquent entities, no tables. That framing is the single most important thing a TPM can hold steady with stakeholders, because it determines the decision shape — adoption is a tactical integration with near-zero architectural gravity, so the question worth spending time on is whether company verification belongs on the roadmap, not whether this is the right wrapper.
Where a TPM extracts value. The commercially meaningful capability is entity validation and enrichment at the moments trust is decided: B2B signup, supplier onboarding, marketplace seller checks, internal admin lookups. Concretely — validate a company number at signup, pre-fill registered name and address, flag dissolved or dormant status, surface officers and filing history for a due-diligence view. These map to KYB-adjacent, vendor-risk, and fraud-reduction outcomes, and they are the profile of work a TPM should sequence as a small, flag-gated experiment ahead of any system build.
Integration feasibility. Conventional Laravel install and service-provider registration; API key stays server-side via config and is environment-swappable. A spike against three endpoints is hours, not days. The honest cost sits outside the package: caching, rate-limit budgeting, retry/backoff, filing-history pagination, and a coherent error taxonomy are all ours. Net: the package is the entry point to a small feature, not the feature.
Technical risk.
Key questions for the spike.
start_index/items_per_page) supported for search and filing history? Without it, list features are capped.composer.json, and is there a supported-version policy?Stack fit. Assume Laravel on PHP 8.x, but read composer.json first — a 2021 package may declare Laravel 8/9 ceilings. If we are on a newer framework line, the answer is a fork or a reimplementation, not --ignore-platform-reqs. Because the package is stateless, multi-tenancy is not a package concern; it becomes ours only in cache keys and in attributing which tenant's onboarding triggered a lookup.
Migration path. No data migration, because there is no schema — the low-risk property that makes trialling easy. The only real migration is behavioural: consolidate scattered hand-rolled Http::get('api.company-information.service.gov.uk/...') calls behind one interface. Inventory those first; the usual win is deleting duplicated plumbing and inconsistent error handling, not adding capability.
Compatibility. Two concrete checks before commitment: framework/PHP constraints against our pinned versions, and whether the suite runs without live credentials. If the package cannot be faked, price that in as a testability tax rather than absorbing it silently.
Sequencing.
CompanyRegistry interface so facade calls never reach controllers or Blade. Incompatible → reimplement the two or three endpoints we actually need; the MIT licence makes forking legitimate and low-drama.Verified / NotFound / Dissolved / Unavailable. These are distinct product states and must not collapse into one.Maintenance. Effectively unmaintained upstream: one maintainer, no release since September 2021, no security policy, no changelog discipline. Budget for owning it. Practically that means pinning the exact version, vendoring or forking under MIT, and reading the few hundred lines of source so we are not debugging blind. Treat replacement as a contained afternoon, not a migration project — that is the escape hatch, and it should be written down before adoption rather than discovered after.
Support. There is no SLA beyond GitHub issues and no maintainer commitment. Support for the feature is therefore entirely internal: whoever owns the CompanyRegistry interface owns the behaviour, the error taxonomy, and the on-call story. Escalation to the upstream project does not exist as a real path.
Scaling. Scaling concerns are almost entirely upstream, not in the package. Companies House enforces per-window quotas and returns 429s; without caching, every page view or signup attempt spends quota. Caching keyed by company number with an hours-scale TTL is the primary lever and also the primary cost control. Watch for: uncached lookups triggered from list views, filing-history pagination that fans out into request storms, and any flow that re-checks the same entity repeatedly within a session. Rate-limit budgeting and backoff are ours to design and monitor — the package provides none.
Failure modes.
Ramp-up. Low. Any Laravel developer can integrate this in an afternoon; the learning curve is in the Companies House API's pagination, rate limits, and terms, not in the wrapper. The genuine ramp-up cost is organisational: getting a legal read on UK GDPR and register terms, and agreeing an error taxonomy with product before code ships. Plan for the legal review to be on the critical path — it is the item most likely to delay a launch that engineering considers finished.
How can I help you explore Laravel packages today?