Starshipit
Get Orders Chart (Date Range)
Returns a daily order-count time series for a StarShipIt integration instance over the given date range.
Get Integration Instance
Returns the configuration for a single StarShipIt integration instance, including connection credentials and behavioural settings.
Update Integration Instance
Updates a StarShipIt integration instance. All body fields are optional — send only what should change.
Delete Integration Instance
Deletes a StarShipIt integration instance.
Create Integration Instance
Creates a new StarShipIt integration instance.
Test Connection
Verifies the stored StarShipIt credentials by making a live call to the StarShipIt API (it fetches a single unshipped order). No request body.
Get Dashboard Metrics
Returns aggregated operational metrics for the instance:
Get Warehouse Routing
Returns the data used to configure which warehouses route fulfillments through this StarShipIt instance:
Get Order
Returns the full details for a single Starshipit order including resolved destination, sender, flags, writeback status, tracking URL, and the linked SKU.io sales order fulfillment (if any).
Get Order Webhook Events
Returns the most recent webhook events (up to 25) related to this Starshipit order.
Download Label (PDF base64)
Proxies StarShipIt's GET /api/orders/labels endpoint and returns the base64-encoded PDF label for the order.
Download Packing Slip (PDF base64)
Proxies StarShipIt's GET /api/orders/packingslip endpoint and returns the base64-encoded PDF packing slip for the order.
List Orders
List Starshipit orders for the integration instance (paginated). Each order includes a `tracking_numbers` array of per-package tracking (tracking_number, tracking_url, name, carrier_service_name, delivery_status) — multi-package orders carry more than one entry, while the scalar `tracking_number` holds only the single value Starshipit returns at the order root. Authenticate with a Personal Access Token (PAT) Bearer token.
Sync Orders (Queue Job)
Queue a background (tracked) job to sync orders from StarShipIt into SKU.io. Progress is reported through the tracked job log endpoints and can also be polled via **Get Order Sync Progress**.
Get Order Sync Progress
Poll the progress of a queued order sync job by its tracked job log ID (returned from **Sync Orders**). On completion, `results` carries the sync summary — `orders_fetched` (orders retrieved from StarShipIt) and `orders_saved` (orders upserted into SKU.io).
Get Order Sync Info
Header data for the orders refresh modal: the most recently dated order (`latest_order_number` + `latest_order_date`, keyed on `order_date`), the total order count, and the **effective** order start date the 'Fetch from Start Date' mode will use.
Search Orders
Search StarShipIt **live** for orders matching a phrase, for the refresh modal's 'Search Specific Order' tab. StarShipIt's `/orders/search` matches across order number, reference, recipient, and the internal order id, so a single phrase covers every identifier a user might paste in. Each result is flagged with whether it already exists in this instance's local cache so the UI can offer Download (new) vs Update (existing).
Refresh Single Order (Download)
Download (or update) a **single** order live from StarShipIt by its StarShipIt order id and persist it to the local cache. Backs the search tab's per-result Download / Update buttons.
Refresh Order Tracking
Refreshes live tracking events for a single order by calling Starshipit's GET /track endpoint with the order's `order_number`. The carrier-reported events are persisted to `starshipit_orders.json_object.events` so the order detail page can render an up-to-date tracking timeline.
Get Order Activity Log
Paginated Spatie activity-log entries for a single Starshipit order (by local row id) — the order detail page's Activity Log tab. Each entry: id, description, event (created/updated/deleted), subject_type, subject_id, properties (changed attributes), causer_name, created_at. Ordered newest first.
Get Order Detail
Returns the locally cached raw StarShipIt payload for a single order.
Sync Order Detail
Fetches the latest data for a single order live from the StarShipIt API and persists it to the local cache (updating `json_object`, setting `has_detailed_data` and `details_last_updated`). Returns the refreshed order, including the raw payload.
Link Order To Fulfillment
Manually links a cached StarShipIt order to a sales order fulfillment. Use this to repair orders the automatic matching could not link (they show as 'unlinked' on the dashboard metrics).
Unlink Order From Fulfillment
Removes the manual link between a cached StarShipIt order and its sales order fulfillment. No request body.
Submit Fulfillment
Manually submits a sales order fulfillment to StarShipIt through the canonical fulfillment dispatch flow.
Submit Open Orders (Power User)
**Warning: this GET request has side effects — it queues a bulk submission of orders to StarShipIt.** It is a legacy power-user endpoint kept for backward compatibility; treat it as an action, not a read.
Get Order For Fulfillment (Power User)
Returns the locally cached StarShipIt order linked to the given sales order fulfillment. Read-only — no calls to StarShipIt are made. This is a legacy power-user endpoint kept for backward compatibility; it is not instance-scoped and resolves the single active StarShipIt integration instance itself.
Update Order From Fulfillment (Power User)
Pushes the current state of a sales order fulfillment to StarShipIt. If the fulfillment already has a linked StarShipIt order, that order is updated live via the StarShipIt API (preserving existing line identifiers); otherwise a new StarShipIt order is created. The result is persisted to the local order cache and returned.
List Packages
Paginated list of packages across all orders for this Starshipit integration instance. Each package is promoted out of its parent order's `json_object.packages[]` array into its own row so packages are searchable by their per-package `tracking_number` (multi-package orders carry distinct tracking numbers that the order-level tracking_number drops).
Get Package
Returns a single Starshipit package by its internal id, including its dimensions, carrier service, per-package tracking number/URL, delivery status, and a cross-link (`order`) back to the parent Starshipit order detail page. The raw package payload is always included as `json_object`.
List Shipping Method Mappings
Lists every distinct carrier + service pair observed on previously synced Starshipit orders for this integration instance, joined with any existing SKU shipping-method mapping. Stored-but-no-longer-observed mappings are also included.
Export Mappings (CSV)
Downloads the current carrier/service-to-SKU-shipping-method mappings as a CSV file (Content-Type `text/csv`, Content-Disposition `attachment`). Filename: `starshipit-shipping-methods-{instanceId}-{YYYY-MM-DD}.csv`.
Import Mappings (CSV)
Bulk-applies carrier/service-to-SKU-shipping-method mappings from an uploaded CSV (multipart/form-data, field `file`).
Map Carrier/Service
Creates or updates the mapping for a single carrier/service `code` to a SKU shipping method.
Bulk Map Carrier/Services
Maps many carrier/service codes to a single SKU shipping method in one call (used by the bulk-select 'Apply to selected' action on the mappings page). Codes are de-duplicated and blank entries skipped.
Unmap Carrier/Service
Removes the mapping for a single carrier/service `code`. The `code` path segment may contain a pipe and other special characters (the route is registered with `where('code', '.*')`).
List Webhook Events
Returns a paginated list of inbound webhook events received from StarShipIt for this instance, newest first.
Get Webhook Event
Returns a single inbound webhook event, including the full raw payload StarShipIt delivered, the signature verification result, and the processing outcome (`processed` / `processed_at` on success, `error_message` on failure).
Retry Webhook Event
Queues a background job to reprocess a webhook event — typically one that failed and recorded an `error_message`. No request body.