baks-dev/ozon-orders
Laravel module for managing Ozon marketplace orders with support for FBS and DBS schemes. Includes profile type, payment, and delivery console commands. Requires PHP 8.4+ and installs via Composer.
Architecture fit
bin/console, and the commands (baks:users-profile-type:ozon-fbs, baks:payment:ozon-fbs, baks:delivery:ozon-fbs) are registered against the BaksDev domain aggregates — user profile types, payments, deliveries. There is no service provider, no config publish tag, no migration set, and no Laravel facade documented. Treat the "Laravel/PHP" framing in the description as a hosting-environment claim, not a framework-integration claim.Client-Id/Api-Key live, how the Ozon API client is constructed, or how webhook/callback endpoints are exposed. Any architecture review must assume this is discovered by reading source.Integration feasibility
| Area | Feasibility | Basis / risk |
|---|---|---|
| Composer install | High | Single composer require, MIT licence, no private registry. |
| Laravel service container wiring | Low–Medium | Symfony bundle DI conventions don't auto-register in Laravel; expect a bridge or manual binding. |
| Database | Medium–Low | No migrations shipped; commands mutate existing tables (users_profile_type, payment, delivery). Schema collision with any existing Laravel commerce schema is a live risk. |
| Ozon API coverage | Unknown | No endpoint inventory published. Assumed to cover order intake, status, payment, delivery for FBS/DBS. Refunds/returns/partial cancellation unverified. |
| Webhooks / push notifications | Low (host-built) | Not self-contained; idempotency, retry, and dead-letter handling fall entirely to us. |
| Test coverage | Low | Only phpunit --group=ozon-orders is advertised — no integration or contract tests against the Ozon sandbox. |
| Observability | Unknown | No documented events, log channels, or metrics. Assume we build this. |
| Localisation | Low | Russian-only README and CLI output; release notes are empty strings (v7.4.48 contains only "v7.4.48"). |
Technical risk
| Risk | Severity | TPM read |
|---|---|---|
| Vendor concentration | High | 1 GitHub star, 0 dependents, single-maintainer signal. This is an unsupported dependency by any normal procurement standard. |
| Release provenance anomaly | High | Latest release is dated 2026-08-19 with ~48 sequential patch versions and empty changelogs. Either the metadata is wrong or releases are machine-generated without notes. Verify before it enters the dependency graph. |
| Silent breakage from Ozon API changes | High | No versioned API layer, no deprecation signalling documented. An upstream change becomes our incident. |
| Re-running setup commands | Medium–High | baks:payment:ozon-fbs etc. appear to be imperative seeders with no documented dry-run or idempotency. Re-running in the wrong environment is a data-integrity hazard. |
| PHP 8.4 floor | Medium | Constrains us to current Laravel (11/12) and recent runtime images; blocks reuse in older services and can force an upgrade cascade. |
| Compliance ambiguity | Medium | No statement on how payment data is stored or tokenised relative to Russian regulatory requirements. Assume we own that assessment. |
| Test/QA burden | Medium | With no upstream integration tests, our QA cost for this integration is effectively full custom coverage. |
Key questions (to resolve before a build commitment)
Stack fit
Migration path
| Phase | Duration (est.) | Scope | Exit gate |
|---|---|---|---|
| 1. Feasibility spike | 1–2 weeks | Install into a throwaway Laravel 12 app; identify real dependency closure; enumerate Ozon endpoints implemented; read source for credential and webhook handling. | Written go/no-go with a dependency list and endpoint coverage table. |
| 2. Architecture decision | 1 week | Compare (a) adopt package + ACL, (b) fork and own, (c) thin custom client against Ozon API. Score on time-to-market vs. long-term ownership cost. | Signed-off ADR; owner named. |
| 3. Sandbox build | 3–4 weeks | Ozon sandbox credentials, FBS flow end-to-end, webhook ingress, idempotency, queue retries, observability. | Order created → paid → fulfilled → delivered reproduced in sandbox with failure injection. |
| 4. Schema and data hardening | 2 weeks | Migrations or mapping layer, seeding commands run once via controlled release step, rollback plan, backup verification. | Repeatable environment build from scratch; command re-run proven safe or gated. |
| 5. Limited production (DBS first) | 3–4 weeks | One seller account, one warehouse, low volume, manual reconciliation daily. | Two weeks of zero unreconciled orders; error budget met. |
| 6. FBS scale-out | 3–4 weeks | Additional warehouses, volume ramp, on-call runbooks. | Documented runbook, alerting thresholds, on-call trained. |
Sequencing constraints
baks:*:ozon-* against an unexamined database is a one-way door.Compatibility
Maintenance
Support
Scaling
Failure modes
| Failure | Blast radius | Mitigation |
|---|---|---|
| Duplicate order ingestion (webhook redelivery) | Customer charged twice / duplicate fulfilment | Idempotency key on Ozon order ID, unique constraint at DB level |
| Dropped webhook | Order stuck in wrong state, fulfilment delay | Reconciliation poller against Ozon order list; daily drift report |
| Ozon API outage or 429 | Order backlog, SLA miss | Exponential backoff, circuit breaker, queue depth alerting, visible backlog dashboard |
| Setup command re-run in production | Duplicate payment/delivery records, corrupt profile types | Gate commands behind a release step, restrict permissions, verify idempotency in sandbox |
| Upstream schema change in a patch release | Silent data errors or fatal errors post-upgrade | Pinned versions, sandbox regression gate, schema diff in CI |
| Payment/delivery status mismatch | Reconciliation break, manual finance work | Daily automated reconciliation with exception queue and named owner |
| Package abandoned | Unpatched security issues, no Ozon API updates | Mirror + fork rights exercised early; internal PR capacity identified |
Ramp-up
Decision framing for the TPM
How can I help you explore Laravel packages today?