Pikbase Docs
Open console (opens the console)
Esc

Type to search.

Workspaces

SaaS edition

The base ERP system plus the complete delegated SaaS backend for tenants, subscriptions, billing, and metering.

SaaS contains the same base ERP system as the Corporate edition, plus the complete Pikbase SaaS backend for an operator that sells and runs its own multi-tenant product.

Everything in base ERP

The workspace includes Core and the base ERP domains: shared business foundations, organization charts, organizational units, employees, roles and positions, products, sales, orders, approval flows, payments, and cash flow. As with Corporate, stock, expenses, human resources, production, operations, and CRM remain separately subscribed capabilities.

SaaS backend

SaaS adds the production SaaS system for the operator's own product:

  • customer registration and verification;
  • tenant creation and lifecycle management;
  • subscription plans, subscriptions, and provisioning;
  • provider-backed billing integration and account credit;
  • usage measurement and limits for the operator's customer tenants;
  • delegated administration of those tenants.

The delegated SaaS lifecycle creates and manages the operator's customer tenants. It does not grant access to Pikbase's internal control plane, source-workspace registry, or global Account commerce operations.

Isolate customer records with splitByTenant

Set splitByTenant: true on each entity definition that stores private SaaS customer data. Do not create a manual tenant_id field to implement isolation. Core automatically assigns every newly created record to the creating authenticated user's SaaS tenant. Only users in that same tenant can act on the record, and only when their configured permissions allow the operation.

This is tenant isolation, not creator-only ownership: another permitted user in the same tenant can use the record. Same-tenant membership alone does not grant permission, and a user from another tenant cannot access it by knowing its ID.

Keep shareDataForSaas: false for private customer data. Submit normal Entity Service payloads; do not choose record tenancy in the frontend or repeat manual tenant filters as an isolation mechanism. module_id is release ownership, not record tenancy, and the API's workspace tenantCode is not a customer-tenant selector.

Follow SaaS tenant isolation for the definition settings, permission checks, and two-tenant verification. When changing an existing definition, review its existing records and migration requirements; setting the flag alone is not proof of correct historical record assignment.

When to choose it

Choose SaaS when the product itself is multi-tenant and its backend must onboard customers, provision isolated tenants, sell subscriptions, bill through the configured provider, and enforce usage limits. Choose Corporate for one organization's operational system, or Core when the product does not need the supplied ERP model.

Build the frontend

Follow Build a React app from npm with --profile saas to connect customer and operator frontend surfaces to your ready SaaS workspace. The guide covers setup and customization; tenant lifecycle, subscriptions, and billing remain owned by the installed backend contracts.

See frontend choices for supported starters and shared React packages, alongside the SaaS authentication, registration, and billing surfaces. These are starting points over the SaaS backend, not separate copies of its tenant, subscription, permission, or billing logic.

Contract sourcedocs/guides/workspace-edition-erp-saas.md