Platform builder guide

MIOSA gives you machines, previews, and deployments. A platform is what you build on top of them so that other people can use them without ever learning how they work.

This guide is for builders of products like Lovable, Devin, or agent platforms. In these products, your product makes a sandbox for each of your own users.

Such a platform needs:

Choose a shape

Every platform on MIOSA uses one model. Three shapes cover most products.

You areExampleWho uses itWhat is white-labeled
A SaaS shipping an agent productLumenLumen’s customersEverything: domains, branding, billing
An agency running client workNorthwind AgencyNorthwind’s clientsClient previews and delivery domains
A company with a teamAcme CorpAcme’s own staff and agentsNothing. It is internal

If you only need the internal case, jump to Acme Corp: an internal platform.

Northwind Agency: client work

The full architectures - Lumen, Northwind Agency client work, and Acme Corp - are walked in Patterns.

1. Create a scoped platform key

Platform keys (msk_p_*) are for server-side automation. Only tenant owners and administrators can create them. Give each key only the scopes the backend needs, and optionally restrict it to one workspace.

The plaintext is returned exactly once and MIOSA stores only a hash. Rotation, scopes, and audit are covered in API keys.

2. Create a workspace per customer

Do this once, when the customer signs up, and store the returned IDs next to your own row.

You can also skip this step. If a create call carries workspace_slug or external_workspace_id and the workspace does not exist, MIOSA resolves or creates it. The response returns the canonical workspace_id and project_id, so store those and reuse them. Details in Ownership and attribution.

3. Give each user a machine

One sandbox or computer per end user, never shared across customers.

Each machine has its own filesystem, network, and process tree. Sizing, templates, and idle defaults are in Templates and sizing.

Pick what you need

You want toPage
Provision one sandbox per end userPatterns
Run an agent inside your users’ machinesAgents in your product
Pick sizes, templates, and idle defaultsTemplates and sizing
Put your brand on previews and appsBranding and domain setup
Attribute resources and usage to your customersOwnership and attribution
Meter usage and charge backUsage and billing

Next

Reference integration

Runnable examples live in examples/. See examples/agent-builds-static-app/ for the “agent builds, previews, and deploys” pattern.

Was this page helpful?