Open Source Platform for DTC, B2B Commerce, Marketplaces & Omnichannel. REST APIs, TypeScript SDKs, and production-ready Next.js storefront. Self-host it. Own your data. No vendor lock-in. Zero platform fees.
Seller Product Submission and Review
Status: Implemented (2026-08-26, PR #14497) — proposed/rejected added through add_status, the Products::Propose/Approve/Reject workflows live beside the existing trio, Spree::ProductSubmission records each decision on a row the seller cannot reach, the permission catalog gained product_types and publishing, the seller branch moves status only through member actions (PATCH /seller/products/:id/submit|draft|archive, status dropped from permitted params), and the operator branch gained PATCH /admin/products/:id/approve|reject plus the review buttons. Remaining: lifting the rest of the product form cards into @spree/dashboard-ui — only status-card.tsx moved, so the seller panel still renders its own product page rather than the shared cards
Target: Spree 6.0
Depends on: 6.0-multi-vendor-marketplace.md, 6.0-seller-onboarding-requirements.md, 6.0-admin-rbac.md, 6.0-product-types.md
Author: Damian Legawiec
Last updated: 2026-08-27
Summary
A seller can list a product but must not publish one. Today they can: the
seller products endpoint permits status as a plain attribute, so a seller
sends status: 'active' and their product is live in the marketplace catalog
with nobody having looked at it. This plan closes that by giving products a
review lifecycle — the seller submits, the operator decides — and by splitting
the two capabilities that currently ride the products permission key and
should not: managing product types, and publishing to sales channels.
It also gives the seller panel the same product form the operator's dashboard
has, rather than the four-field placeholder it ships today. The form cards move
into @spree/dashboard-ui so both dashboards render one definition and cannot
drift.
Key Decisions (do not deviate without discussion)
Two new statuses,
proposedandrejected, added throughadd_status— additive by design, so core workflows guarding on core statuses keep passing. We keep our own vocabulary:activeis what the marketplace reference callspublished, and renaming it would churn every existing consumer for no gain.archivedis untouched.The lifecycle is workflows, never a state machine.
Products::Propose,Products::ApproveandProducts::Rejectjoin the existingActivate/Archive/Drafttrio, each with a leadingvalidatehook. There is no transition graph — that would be a state machine by another name (see6.0-service-workflows.md).statusstops being a writable attribute on the seller branch. A seller moves a product with an explicit member action, never by sending a status in an update payload. The operator's branch keeps the plain attribute for the operator's own catalog — but not for a product in review (revised 2026-08-26): a direct status write orbulk_status_updateon aproposedorrejectedproduct refuses, because leaving review is a decision, and a decision that skipsApprove/Rejectrecords no reviewer and closes no submission row. A bulk approve, if ever needed, is a loop over the workflow, neverupdate_all.A seller may return an
activeproduct todraftorarchived, but may never reachactivethemselves. Taking your own listing down is not a review decision; putting it up is. This mirrors the legacy gem, which grantedactivateonly for products alreadyactive.product_typesbecomes its own catalog resource, read-only for the seller audience. A seller fills in a type's custom fields; they do not define types. Per6.0-admin-rbac.md, a new sensitive capability gets its own catalog entry rather than riding an existing key.Revised 2026-09-01: read-only for a seller to pick from, not merely to look at — a seller assigns a type to their own product, and a delivery profile with it. The type is the template that hands them option types and a delivery profile, and the profile is what makes their goods quotable; on 2026-08-26 both had left the branch with the Categorization card, and every seller product was landing on the store's default profile. See
6.0-multi-vendor-marketplace.md, Decision 13 and the 2026-09-01 resolved decisions.ProductPublicationmoves off theproductskey onto a publishing resource with no seller audience. Which channels carry a product is marketplace merchandising, not a seller's to set.A seller files a product into the marketplace's groupings; they do not extend them. Revised 2026-08-26 (recorded 2026-09-01): they do not file it either — categories, collections and tags all left the seller branch with the Categorization card, since filing a listing is the operator's, done at review. The two fields that came back on 2026-09-01 are the product type and the delivery profile, which are not filing. The original reasoning stays below for the record.
category_idsandcollection_idsare writable — filing a product is part of maintaining it, which is why the operator's own endpoint permits them underwrite_productsrather thanwrite_collections. The categories and collections themselves are read-only pickers.Tags are not writable at all. They are tenanted to the store (
acts_as_taggable_tenant :store_id), so a seller typing a new one adds a term to the marketplace's shared vocabulary rather than labelling their own product. Verified against both marketplace platforms we looked at: one exposes categories, collections, tags, types and attributes to sellers as read-only, with a single endpoint for placing a seller's own products into an existing category; the other's category tree and attribute schema are operator-only imports that sellers map onto. The legacyspree_multi_vendorgem took the same line (cannot :manage_tags, taxonomyindex/showonly).Custom field values are seller-writable; definitions are not.
Spree::CustomFieldstays onproducts;Spree::MetafieldDefinitionis operator-only, and the seller panel renders the definitions it is given without the "add a definition" affordance.The product form cards live in
@spree/dashboard-ui, headless and generic over the record type — data by props, no SDK import, no provider import.MediaCard's oneadminClient.media.listcall becomes an injected prop. This is what makes "the same as in dashboard" true by construction rather than by discipline.No JSON preview on the seller panel. It is an opt-in prop on the page shell; the seller form omits it.
The review decision is a row, not a note on the product (revised 2026-08-26). Each submission and each decision on it is a
Spree::ProductSubmission: who submitted, who decided, when, and the seller-visible note. The row records the trail — it never replaces the product's status, which stays the operational truth, exactly as a seller's own status lives on the seller whileSellerRequirementSubmissionrows carry the history. The original design put the rejection reason inproduct.metadata, which failed on three counts, in descending order: the seller products endpoint permitsmetadata: {}, so an ordinary save by the seller replaced the hash and silently erased the operator's reason (proven over HTTP — the status stayedrejectedwith no recoverable reason); a second rejection overwrote the first, so nobody could see a seller sent back three times for the same thing; and there was nowhere to record who decided —ApproveandRejectboth already acceptreviewer:and the admin controller already passes the current user, which both then discarded. The rejected rationale ("a table for one string") survives none of these: the row is not one string, it is the audit trail.The name is
ProductSubmission, andSpree::ProductReviewstays reserved for customer ratings. Core's ownSpree.permissionsdocumentation usesSpreeReviews::Reviewunder areviewscatalog resource as the canonical extension example, so taking the obvious name for an operator decision would displace it permanently. The row is named for the seller's act — the decision rides on it — exactly asSpree::SellerRequirementSubmissionis, and the statuses read naturally against it: a submission is pending or withdrawn; a "withdrawn review" never was. Prefixprodsub, parallel toselsub.
Design Details
Status lifecycle
draft ──propose──▶ proposed ──approve──▶ active
▲ │
│ └──reject───▶ rejected
│ │
└──────────── seller revises ─────────┘
active ──▶ draft | archived (seller may do this)
active ──▶ proposed (never — approval is not re-requested)
draft— the seller is still working. Not visible in the storefront.proposed— submitted, awaiting the operator. Not visible in the storefront.active— approved and on sale. Unchanged meaning.rejected— the operator turned it down. Not visible in the storefront. The seller edits and submits again, which returns it toproposed.archived— withdrawn. Unchanged meaning.
Only active is storefront-visible, which is already how ProductScopes
works — the new statuses inherit that for free precisely because they are not
active.
Auto-approval. A store preference (auto_approve_seller_products)
chains Propose straight into Approve, matching how
auto_approve_sellers works in 6.0-seller-onboarding-requirements.md. A
marketplace that does not want to review every listing sets it once.
Rejection reason. Reject takes a reason: and records it on the
submission row, so the seller sees why. (It lived briefly in
product.metadata, which the seller could overwrite — Key Decision 11
records why that changed.)
The submission record
class Spree::ProductSubmission < Spree.base_class
belongs_to :product
belongs_to :submitted_by, class_name: Spree.admin_user_class.to_s, optional: true
belongs_to :reviewed_by, class_name: Spree.admin_user_class.to_s, optional: true
has_status :pending, :approved, :rejected, :withdrawn, default: :pending
end
Columns: product_id, status, submitted_by_id, reviewed_by_id,
reviewed_at, review_note (text — the operator's, seller-visible; named
as on SellerRequirementSubmission, leaving note free for a future
seller-side message), metadata, timestamps. No store_id: the store is
derived through the product, exactly as SellerRequirementSubmission
derives it through the seller. Index
(product_id, created_at) — the latest row for a product is the one that
counts, the ones before it are how the marketplace got there.
Append-only, and every exit from review closes the open row. Propose
opens a pending row stamping submitted_by; Approve and Reject close
it with reviewed_by/reviewed_at; and a seller withdrawing a submission —
Draft or Archive on a proposed product — closes it withdrawn, so a
pending row always means "awaiting a decision", never "abandoned". A product
submitted, rejected, revised and resubmitted leaves the full sequence.
Approvals are recorded as deliberately as rejections: "when did this go on
sale, and who allowed it" is the question with the longest tail.
Auto-approval says so. The auto_approve_seller_products chain approves
with no human in the loop, and its row records
metadata: { auto_approved: true } — an approved row with a blank reviewer
must mean "this store does not review listings", never "someone approved
from the console and we lost their name".
One note field, seller-visible. An operator-only note is a real want (an
approver recording why they allowed something borderline) but has no caller
yet, and a second column is additive later — as is note for the seller's
own message, per the SellerRequirementSubmission layout. The reason
stays free text in 6.0 — a controlled reason vocabulary is the mature
shape, and it hangs off this row whenever a real need arrives.
Core
Spree::Product:add_status :proposed, after: :draftandadd_status :rejected, after: :proposed.STATUSESstays as-is; the class attribute is whathas_statusvalidates against.- New scopes fall out of
has_statusautomatically (.proposed,.rejected). Spree::Products::Propose,::Approve,::Reject— workflows on theActivatetemplate, each publishing an event (product.proposed,product.approved,product.rejected).- Registered as
Spree.product_propose_workflowand friends inSpree::Dependencies. Spree::ProductSubmission+ the row-writing steps inPropose,Approve,Reject,DraftandArchive(the last two only when leavingproposed).
API
Seller branch:
PATCH /seller/products/:id/submit→Products::ProposePATCH /seller/products/:id/draft→Products::Draft(take down)PATCH /seller/products/:id/archive→Products::Archivestatusremoved frompermitted_params.GET /seller/product_types— read-only, for the type picker.GET /seller/custom_field_definitions— read-only, so the form can render the fields a seller fills in.
Admin branch:
PATCH /admin/products/:id/approve→Products::ApprovePATCH /admin/products/:id/reject→Products::Reject(takesreason)- A
proposedfilter on the products index so an operator can find the queue. - The admin product serializer embeds the latest submission
(
submission: status, review note, reviewer, timestamps); a full-trail endpoint waits for a real need. The seller serializer exposes the latestreview_noteonly — never the reviewer's identity.
Permissions
register_scope(:product_types, group: :catalog,
audiences: %i[store seller], read_only_for: %i[seller],
resources: -> { [Spree::ProductType] })
register_scope(:publishing, group: :catalog,
resources: -> { [Spree::ProductPublication] })
Spree::ProductType and Spree::ProductPublication leave the products
subject list. Approving and rejecting are write_products on the admin
branch — an operator who may edit the catalog may decide what enters it.
Upgrade note. The seeded admin role is unaffected: it holds no explicit
keys and takes full access, so it picks up new catalog resources
automatically. A custom role that was granted write_products does not
inherit write_product_types or write_publishing — splitting a capability
means the narrower grants have to be re-issued, which is the operator's call
and not something an upgrade should decide for them. Per
6.0-admin-rbac.md, roles are pure data: no code path rewrites a store's
saved permission arrays.
Dashboard packages
@spree/dashboard-ui gains a products/ directory holding the form cards,
each headless: no adminClient, no useStore, no locale import. The two apps
supply data, mutations and translated labels by prop.
The seller panel composes: General, Media, Prices, Variants, Inventory, SEO, Categorization (product type and delivery profile only — no categories, collections or tags; revised 2026-09-01), Custom Fields, Metadata, Status (restricted), Translations. It omits Publishing (channels), Tax, and the JSON preview.
StatusCard takes the allowed transitions as a prop rather than deriving
them, so the seller panel offers Submit / Take down / Archive while the
operator's offers the full set.
Migration Path
- Core statuses + the three workflows + dependency registration.
- Permission catalog split (
product_types,publishing), with the subjects moved offproducts. - Seller API: member actions,
statusdropped from permitted params, read-only product types and custom field definitions. - Admin API: approve/reject + the review queue filter.
- Lift the form cards into
@spree/dashboard-ui; repoint the operator's dashboard at them (no visual change — the same components). - Build the seller product form on the shared cards.
- Data: nothing to migrate. Existing products keep their status; no row is
proposedorrejecteduntil somebody submits one. - The submission record (implemented 2026-08-26, on the same unreleased
branch):
Spree::ProductSubmission+ migration,Spree::ProductSubmissions::Closeas the single settling path, row writes in the five workflows, review-status refusal inProducts::Update(so every caller inherits it) and skip-with-a-count inbulk_status_update,Product#rejection_reason/#latest_submission, admin + seller submission serializers embedded on the product assubmission. No data task and no bridge — the metadata design never shipped, so it is rewritten in place and therejection_reasonkey never reaches a release.
Constraints on Current Work
- Never permit
statusas a writable attribute on the seller branch. A new seller endpoint touching products must move status through a workflow. - Do not add
Spree::ProductTypeorSpree::ProductPublicationback to theproductspermission subjects. They are their own resources now. - A new product-form card goes into
@spree/dashboard-ui, not into@spree/dashboard— otherwise the two forms drift again, which is the thing this plan exists to prevent. It must take its data by prop and import no SDK. - Storefront visibility keys off
activeonly. A new status must not be added to the published scope without a deliberate decision. - No
Product#submitted?-style helper methods beyond whathas_statusgenerates, and no columns recording review state on the product — the product's status is its state, and the review's history is the row. - Never store an operator decision where the subject of the decision can
write.
metadataon a seller-owned record is seller-writable by construction; decisions go on the submission row. Approve/Rejectmust persist thereviewer:they are given, and a new path that moves a product out of review must run the workflows or refuse — never writestatusaround them.
Open Questions
- Should a
proposedproduct be editable by the seller, or frozen until the operator decides? Leaning editable, with an edit returning it todraftso the operator never reviews a moving target. Not blocking: the first cut leaves it editable and in place. - Whether the operator needs a bulk approve for a seller's first batch.
Part-answered (2026-08-26):
bulk_status_updatemust NOT cover it — it writes around the review and records no reviewer, so it refuses products in review. A bulk approve, if wanted, is a loop overApprove. - Whether
Spree::Sellers::Rejectmoves onto the same shape. It stores its reason inseller.metadata['rejection_reason']identically; the erasure is proven for products and inferred (unverified) for sellers. A seller's review already has a natural home nearby (SellerRequirementSubmissioncarriesreview_noteper requirement), so the fix there may be a column on the seller's review flow rather than a new model — decide when it is taken up.
References
docs/plans/6.0-multi-vendor-marketplace.md— the marketplace coredocs/plans/6.0-seller-onboarding-requirements.md— the submit-for-review pattern this mirrors (Sellers::SubmitForReview/Approve)docs/plans/6.0-admin-rbac.md— why a new capability gets its own resourcedocs/plans/6.0-service-workflows.md— why transitions are workflows- The legacy
spree_multi_vendorgem'sPermissionSets::VendorUser, which establishedcannot :activateandcannot :manage, ProductPublication.