shureban/laravel-sumsub-sdk
Laravel SDK that implements Sumsub API routes for identity verification workflows. Install via Composer, register the service provider, and publish the config to swap interfaces for concrete implementations.
Architecture fit
shureban/laravel-sumsub-sdk is a domain-specific adapter around SumSub's KYC/AML API, not infrastructure. Architecturally it buys us three things a TPM should value: service-provider registration (one line in config/app.php), a publishable config with interface-to-class bindings (dependency inversion for testability and vendor swapping), and modeled request/response objects for SumSub payloads (applicant info, fixed info, company/beneficiary structures, review results, reject labels, webhook bodies). The SumSub surface it covers — applicants, documents, review status, webhook signature verification via payload digest — maps to the full verification lifecycle we'd otherwise hand-roll.
The real architectural decision it encodes is where SumSub state lives. This package is a transport + DTO layer; it does not give us persistence, state machines, retry semantics, or webhook idempotency. That's the right boundary for a vendor SDK, but it means the TPM owns the surrounding design: our own applicant/verification entities, a webhook ingestion endpoint with replay protection, and a reconciliation job against SumSub's API as source of truth. Treat the package as the seam, not the system.
A secondary architectural coupling: the package depends on shureban/laravel-object-mapper, a second package by the same single author, and the install docs require publishing its config too. That's a transitive dependency on an equally small, equally young library sitting in our request/response path. It also implies reflection- or attribute-driven hydration of SumSub payloads — convenient, but a debugging hazard when SumSub adds or renames fields.
Integration feasibility Feasible for a Laravel shop in days, not weeks. Composer install, provider registration, config publish, credentials in env, then wrap calls behind our own service interface. The v2 line added per-jurisdiction API keys and secret keys (v2.0.2, v2.2.0), which matters if we onboard users across regions — a genuinely useful capability that removes the need for us to fork.
Blockers to a clean estimate:
## Usage section. There are no code examples of creating an applicant, generating an SDK access token, or handling a webhook. Onboarding cost is therefore "read the source and the SumSub public API docs side by side," not "follow the guide."src/.Technical risk Ranked for a TPM audience:
makeale, AlexeyHrynko). No evidence of a support commitment, security policy, or response SLA. If the author stops, we own the fork.0.0.1→0.0.33 in rapid succession, then a 1.0.0, then a full 2.0.0 rewrite eleven days later. That's a young library that has already broken its own API once. Semver discipline in the 0.x era was effectively absent.Key questions
src/ tree cover 100% of them — or will we be extending vendor code?PayloadDigest verifier constant-time and correct against SumSub's current signing spec?SumsubClient interface we control, so the package can be replaced by a direct Guzzle/cURL client in a day?laravel-object-mapper?Stack fit Strong if we are on Laravel 10–13 and PHP 8.1+. The service-provider + config-publish idiom is exactly what a Laravel team expects, and interface bindings in config let us swap the HTTP client, the mapper, or the whole client for a fake in tests. If we are on Lumen, Symfony, or a non-Laravel service, the package's value evaporates — the SumSub REST API is plain HTTP and we'd skip the wrapper.
Migration path If we already call SumSub directly (Guzzle + hand-parsed JSON), migrate seam-by-seam, not big-bang:
.env committed to a repo.KycProvider interface in the app. Implement it once with the legacy client, once with the SDK. Bind via config/env.Compatibility
^2.3 with a committed composer.lock, not ^2.0. Never let a CI job resolve a new 2.x minor without review.laravel-object-mapper peer requirement must be pinned in the same lockfile review. Two version constraints, one decision.ext-* requirements before committing to a base image.Sequencing (suggested 4–6 week envelope for one backend engineer, part-time)
src/ end to end, diff v2.2.6→v2.3.1, confirm endpoint coverage against our SumSub contract, run the signature verifier against SumSub's spec, write the exit-plan abstraction.KycProvider interface + fake, first read-path call in staging with a sandbox SumSub token.Maintenance Ongoing cost is dominated by SumSub's API evolution, not ours. Every new document subtype, reject label, or applicant field either arrives via an upstream release (upgrade + regression test) or requires us to patch vendor code (fork + divergence). Budget a recurring line item: one dependency-review pass per quarter plus an unplanned pass whenever a new verification flow ships. The single-maintainer profile means the review pass must include "is this package still alive?" — a cheap check that no dependency bot will do for us.
Support
No vendor, no SLA, no security policy visible. Internally this means the package cannot be a blind dependency: we need a named owner, a fork in our namespace ready to go, and the KycProvider abstraction in place so a fork is a configuration change rather than a refactor. Escalation path is "open a PR upstream, ship from our fork same day."
Scaling The package is not the bottleneck. SumSub's rate limits, per-applicant webhook volume, and our own webhook throughput are. Two concrete concerns:
Failure modes
KycProvider boundary and a typed app-level exception.fix null fields / fix null company info releases) → a nullable DTO property blows up a consumer that assumed non-null. Mitigate with defensive accessors and contract tests against recorded SumSub fixtures.shureban/laravel-object-mapper → supply-chain risk in a KYC path. Mitigate with lockfile pinning, composer audit in CI, and an allowlist of new Composer packages.Ramp-up
Realistic for one mid/senior Laravel engineer: 2–3 days to first successful sandbox applicant, 1–1.5 weeks to confident, flag-gated production use, contingent on reading src/ because the README's Usage section is empty. Add a half-day for a second engineer to review the webhook/signature path. Because there is no documentation to hand over, capture what we learn as an internal ADR plus a runbook — otherwise the bus factor is one inside our org as well as in the repo.
Net TPM read: adopt with guardrails, not by default. The package substitutes for maybe 300–600 lines of hand-written HTTP plumbing in a compliance-critical path, at the cost of a single-maintainer, zero-adopter dependency plus a second such dependency. That trade is defensible only behind our own thin interface, with a pinned lockfile, an owner, and a fork we could ship today. If we cannot commit those four things, calling SumSub's REST API directly with Guzzle is the lower-risk call — the SDK's surface is small enough that we would not miss much.
How can I help you explore Laravel packages today?