Skip to content

Add-Product Search (Create-Order)

The slim product search that powers the admin Create Order screen's "Add Product" modal. It returns a compact row per product so an operator can quickly find and pick a product to add to a draft order.

This is not the product listing

For the full admin product listing — every column plus all the Channel / Name / SKU / Attribute Family / Price / ID / Status / Type filters — use List Products (GET /api/admin/catalog/products). This page documents only the Create-Order search tool.

Results come back in the { data, meta } envelope used by every admin collection.

Endpoint

EndpointMethod
/api/admin/productsGET

How it differs from /api/shop/products

ShopAdmin
Default status filterOnly status = 1 and visible_individually = 1No filter — all statuses returned
Booking productsHidden by shop visibility rulesListed (blocked only when added to admin draft cart)
Row payloadFull storefront fields (variants, prices, special prices, etc.)Slim picker shape (9 fields)
Pagination responseHeader-based (X-Total-Count, X-Page, ...)Body envelope ({ data, meta })
AuthenticationStorefront key + optional customer SanctumAdmin Sanctum token

Query Parameters

ParameterTypeDescription
pageintegerPage number (default 1)
per_pageintegerItems per page (default 30, cap 50)
querystringFree-text — matches SKU OR product name (partial)
skustringExact SKU
typestringsimple, configurable, bundle, downloadable, grouped, virtual, booking
statusinteger0 (disabled) or 1 (enabled) — omit to get both
categoryIdintegerFilter by category ID
channelstringChannel code for value resolution
localestringLocale code for value resolution
sortstringid, sku, created_at, updated_at
orderstringasc or desc (default desc)

Row Shape

FieldTypeNotes
idintegerProduct ID
skustringSKU
typestringProduct type
namestring|nullResolved via locale/channel if provided
statusinteger|null1 enabled / 0 disabled
pricenumber|nullMinimal price for the resolved customer group
formattedPricestring|nullLocale-formatted price
baseImageUrlstring|nullMedium-cache image URL, falls back to original
isSaleablebooleanType-instance saleability check

Booking Products

Booking products are returned by this endpoint so admin can find and review them. They are blocked at admin draft-cart add-to-cart time (POST /api/admin/carts/{id}/items) with HTTP 400 and the message "Booking products cannot be added to an admin draft order." This matches the Bagisto monolith — the admin Create-Order UI does not ship a booking partial either.

Released under the MIT License.