Get public B2B settings
Store API
Routes for storefronts and buyer-facing apps, acting as a signed-in customer.
Sign up a company POST
Creates a company, its customer group, and the caller as its `owner`, in one step that rolls back on failure. The company is `pending` when the `company.signup_requires_approval` setting is on, otherwise `active`. Two callers are accepted: - A registration token from `POST /auth/customer/{provider}/register` (no customer yet). `customer` is required and a customer is created. Refresh the token afterwards (`POST /auth/token/refresh`) to get one that carries the new customer. - A signed-in customer with no company. `customer` must be omitted. Errors: `customer_required`, `customer_not_allowed`, `already_in_company`. Emits `company.created` and `employee.created`.