kmizzi/shipstation-freight @ df7cecf · 2026-11-21 · UI verified in a component harness (real pages, mocked API)created_at_start/created_at_end, references[] on list items, paging via pages/links.next, page_size echo, the custom sku_load reference type kept and returned) and the tracking payload. All NOT VERIFIED.sku_load reference per attempt, and a lost-booking check that never says "not booked" without proof. Covered by fixture tests only.pages/settings/freight/index.vue, FreightConnectionDrawer.vue and pages/integrations/index.vue were mounted with the API mocked from FreightConnectionController::providers() and FreightConnectionResource. Server-side behaviour (key test before save, select validation against stored options, permissions) is covered by backend tests, not by this browser run.
"Connect another ShipStation account" edited the existing connection instead of creating a new one, so a second account could not be added from the UI. The catalog's Connect went through the same route and had the same problem. Fix: the new helper existingConnectionForConnect only redirects to an existing connection when the provider does not allow multiple connections. It has a vitest spec.


The connection card's warning alerts were clipped (Vuetify's .v-alert has flex: 1 1 0% inside the card's flex column). Fix: flex-0-0 on the three card alerts. Measured before: 56px shown of 80px content at 1920, 46 of 53 at 1280. After: 96/96 and 76/76.


The card printed the raw provider account id ("Freight provider account: fpa_8f2c1e"). It now shows the option label: "Main (Worldwide Express)" (scenes 4 and 6).
| Case | Input | Expected | Observed | Status |
|---|---|---|---|---|
| Blank key | (empty) | "Test and connect" disabled | disabled = true | PASS |
| Whitespace key | 5 spaces | still disabled (trimmed) | disabled = true | PASS |
| Key masking | typed key | password input; never echoed on edit | type=password; edit shows "Saved …k3Qx" only | PASS |
| Long name | 200 × "X" | capped at 60 | value length 60 | PASS |
| Special characters | <script>alert(1)</script> "Ünïcode" ☃ | rendered as text | shown literally; 0 <script> nodes in the card | PASS |
| Rapid clicks | double-click + 3rd click on "Test and connect" | one connection | exactly 1 card added | PASS |
| No provider accounts yet | new connection | select disabled with guidance; card explains the block | "Connect, then test to load the choices"; NO_PROVIDER message on card | PASS |
| Behavior | Action | Asserted result | Status |
|---|---|---|---|
| Catalog to settings link | Connect ShipStation Freight | route /settings/freight?connect=shipstation, drawer open | PASS |
| URL-driven drawer | Edit on a card | route ?connection=32, drawer titled with the connection name | PASS |
| Select setting | open, pick, clear icon | 2 options listed; value saved; clearable | PASS |
| Cancel / close | Cancel in drawer | drawer closes, query cleared | PASS |
| Connect another | provider-card button | blank drawer; saving adds a second account | PASS (fixed in df7cecf) |




Console errors over the whole flow: 0 (after a harness favicon was added). There are no network calls to judge, because the API is mocked in-process.
Not exercised from the browser, because the harness mocks the API. Backend behaviour is proven by the suites below and by the live API probes.
Loading skeletons (start of scene 2), empty select (scene 2), blocked with no provider (scene 3), pick-an-account (scene 4), populated and ready (scenes 4, 6). Not exercised: the page's load-error state.
Only an admin user was used. The page gates edits on integrations.update and disconnects on integrations.delete, the same as the Warp cards. This was not exercised for a non-admin in this run.
N/A. The static harness has no server latency to measure.
| Account | Call | Result |
|---|---|---|
| SKU.io paid ShipStation (dev@sku.io, own V2 key) | GET /v2/carriers | 200 |
| same | GET /v2/freight/provider_accounts | 200 {"freight_provider_accounts": []} (no provider connected) |
| same | GET /v2/freight/shipments | 200 {"shipments": [], "total": 0, "page": 1, "page_size": 25, "pages": 0} |
| Trial merchant key | POST /v2/freight/quotes | 400 passed request validation and stopped at "freight_provider_account_id must be a valid provider account id". The live API requires dimension_unit/weight_unit even though the docs do not. |
| ShipStation API sandbox (TEST_ key), LTL test carriers | quote: TEST | 200 $2,198.48 (canned) |
| same | quote: WARN | 200 $382.47 |
| same | quote: FAIL | 400 "Carrier Error: Missing Ship From Address." |
| Suite | Result |
|---|---|
| Full CI bench, run 44948712546 (e8d06d6 with master merged) | PASSED |
| After df7cecf: ShipStation driver, flow and connection tests | 48 / 48 passed |
| After df7cecf: frontend freight vitest | 24 / 24 passed; pnpm typecheck:changed clean |
| Freight + ShipStation + booking suites, after review round 4 | 695 / 695 passed |
| Earlier full filtered backend run | 982 / 983 passed (1 skipped) |
| Frontend freight specs before df7cecf (vitest) | 21 / 21 passed |
Review loop. Codex is unavailable (quota until 11-25), so independent reviewer agents ran instead. R1: 8 findings applied · R2: 4 applied · R3: 3 applied · R4: 3 applied · R5: 1 found and fixed in df7cecf (a 4xx on the round-trip proof lookup leaked raw provider text). The loop has converged.
What changed. A ShipStation case on FreightProviderEnum with a select-type setting (freight provider account) and multiple connections allowed. A Saloon connector and a ShipStationFreightDriver for provider accounts, quotes, booking, shipment list and lookup, tracking, documents and cancel, with error mapping. setting_options and quote_blocked_reason on the connection resource. The catalog row through a tenant migration. Drawer support for select settings. Fixtures and feature tests.
Modules/Freight/Config/config.php | 24 + Modules/Freight/Contracts/FreightProviderDriver.php | 9 +- Modules/Freight/Data/FreightAccountStatusData.php | 4 + Modules/Freight/Data/FreightBookingAttemptData.php | 36 ++ Modules/Freight/Data/FreightBookingRequestData.php | 7 + Modules/Freight/Data/FreightCapabilitiesData.php | 2 + Modules/Freight/Database/Factories/FreightIntegrationInstanceFactory.php | 30 +- Modules/Freight/Drivers/ShipStationFreightDriver.php | 958 ++++++++++++++++++++++++++++++++++++ Modules/Freight/Drivers/WarpFreightDriver.php | 4 +- Modules/Freight/Enums/FreightProviderEnum.php | 62 ++- Modules/Freight/Http/Controllers/FreightConnectionController.php | 1 + .../Integrations/ShipStation/Requests/ShipStationCancelShipmentRequest.php | 21 + .../Integrations/ShipStation/Requests/ShipStationCreateShipmentRequest.php | 33 ++ .../Integrations/ShipStation/Requests/ShipStationGetShipmentRequest.php | 21 + .../ShipStation/Requests/ShipStationListProviderAccountsRequest.php | 19 + .../Integrations/ShipStation/Requests/ShipStationListShipmentsRequest.php | 31 ++ .../Http/Integrations/ShipStation/Requests/ShipStationQuoteRequest.php | 33 ++ .../ShipStation/Requests/ShipStationShipmentDocumentsRequest.php | 21 + .../Integrations/ShipStation/Requests/ShipStationTrackShipmentRequest.php | 21 + Modules/Freight/Http/Integrations/ShipStation/ShipStationConnector.php | 55 +++ Modules/Freight/Http/Requests/SaveFreightConnectionRequest.php | 41 +- Modules/Freight/Http/Resources/FreightConnectionResource.php | 2 + Modules/Freight/Managers/FreightBookingManager.php | 28 +- Modules/Freight/Managers/FreightConnectionManager.php | 45 +- Modules/Freight/Repositories/FreightConnectionRepository.php | 15 +- Modules/Freight/Repositories/FreightShipmentRepository.php | 15 + Modules/Freight/Tests/Feature/FreightBookingTest.php | 5 +- Modules/Freight/Tests/Feature/FreightIntegrationCatalogTest.php | 4 +- Modules/Freight/Tests/Feature/ShipStationFreightDriverTest.php | 693 ++++++++++++++++++++++++++ Modules/Freight/Tests/Feature/ShipStationFreightFlowTest.php | 370 ++++++++++++++ Modules/Freight/Tests/Fixtures/shipstation/book.json | 23 + Modules/Freight/Tests/Fixtures/shipstation/cancel_refused.json | 11 + Modules/Freight/Tests/Fixtures/shipstation/documents.json | 6 + Modules/Freight/Tests/Fixtures/shipstation/invalid_provider_account.json | 12 + Modules/Freight/Tests/Fixtures/shipstation/provider_accounts.json | 14 + Modules/Freight/Tests/Fixtures/shipstation/provider_accounts_empty.json | 3 + Modules/Freight/Tests/Fixtures/shipstation/quotes.json | 36 ++ Modules/Freight/Tests/Fixtures/shipstation/quotes_empty.json | 3 + Modules/Freight/Tests/Fixtures/shipstation/shipments.json | 46 ++ Modules/Freight/Tests/Fixtures/shipstation/tracking_delivered.json | 14 + Modules/Freight/Tests/Fixtures/shipstation/tracking_in_transit.json | 13 + Modules/Freight/Tests/Fixtures/shipstation/unauthorized.json | 11 + Modules/Freight/Tests/Fixtures/shipstation/validation_error.json | 12 + Modules/Freight/Tests/FreightTestCase.php | 30 +- app/Models/Integration.php | 5 + app/Support/FeatureCatalog.php | 2 +- .../tenant/2026_11_21_210000_seed_shipstation_freight_integration.php | 36 ++ database/seeders/ImmutableData/IntegrationsSeeder.php | 12 +- docs/plans/shipstation-freight-driver.md | 279 +++++++++++ docs/postman/postman-orders.json | 16 +- frontend-vue-3/src/pages/integrations/constants.ts | 3 + frontend-vue-3/src/pages/settings/freight/__tests__/freightSettings.spec.ts | 73 ++- .../src/pages/settings/freight/components/FreightConnectionDrawer.vue | 27 +- frontend-vue-3/src/pages/settings/freight/freightSettings.ts | 35 ++ frontend-vue-3/src/pages/settings/freight/index.vue | 35 +- frontend-vue-3/src/test/integrations/freightCatalog.spec.ts | 5 + frontend-vue-3/src/types/freight.ts | 13 + resources/mcp/api-index.json | 2 +- tests/Feature/IntegrationSyncSurfaceTest.php | 2 +- 59 files changed, 3329 insertions(+), 60 deletions(-)
/present · component harness (real Vue pages, mocked API) + playwright-cli + backend/frontend suites · 2026-11-21