PostgreSQL backend platform

Build your product. Not your backend.

A PostgreSQL database, user authentication, and REST APIs for every project. One host, one Console, no backend to rewrite.

  • PostgreSQL per project
  • Auth with MFA
  • REST for exposed tables
Console
example-projectActive

customers

customers
nameemailplan
Mina Cho[email protected]pro
Jonah Hale[email protected]starter
Priya Shah[email protected]pro
Northwind Supply[email protected]team

iduuidnametextemailtextplantextowner_idtext

GEThttps://example-project.api.cubibase.com/rest/v1/customers

The platform

The backend essentials, already wired together.

You still design the schema. CubiBase handles the parts every app rebuilds.

  1. 01

    A PostgreSQL database per project

    Name a project. CubiBase provisions a database for it alone, with four roles that cannot bypass row security.

    example-projectProvisioning

    Databaseexample_project_db

    Rolesddl · api · sql · auth

    Schemaspublic · auth · vault · logs

    Illustration of the state change. Creating a project queues the database; it exists when provisioning finishes.
  2. 02

    Sign-up and sign-in for your users

    Call /auth/v1 on the project host. Users, sessions, and TOTP MFA live in your database. The access token is the JWT your data calls need.

    1. Your app

      email + password

    2. CubiBase Auth

      Argon2id hash

    3. Your database

      example_project_db

    Illustration. Sign-up returns the JWT your Data API calls use.
  3. 03

    Exposed tables become REST

    A new table is not public. Switch on select, insert, update, or delete, and the Data API serves it. No controller to write.

    customers · exposureillustration

    Served at /rest/v1/customers for the operations you switched on.

    Illustration. Toggles here do not change any real table.

Authentication

Your users sign in. You skip the auth server.

Email and password, rotating refresh sessions, and TOTP multi-factor, served from your project host. Passwords are Argon2id hashes in your own database.

  • Access JWTs that row policies already understand.
  • Stolen refresh token reuse revokes the whole family.
  • Bring your own IdP with RS256 and a JWKS URL instead.

Email and password return an access JWT and a refresh token.

accessToken · 1 h

Illustration with fictional tokens. It does not query CubiBase.

REST

Your tables. Your APIs. Automatically.

Expose customers and the Data API serves https://example-project.api.cubibase.com/rest/v1/customers.

Request
GET https://example-project.api.cubibase.com/rest/v1/customers?plan=eq.pro&order=name.asc&limit=20
apikey: cb_pub_EXAMPLE_ONLY
Authorization: Bearer <USER_JWT>
Response · plan=eq.pro
{
  "data": [
    {
      "id": "8c1a0b2e-7d44-4a11-9c31-0b51a6e4d901",
      "name": "Mina Cho",
      "email": "[email protected]",
      "plan": "pro",
      "owner_id": "user_mina"
    },
    {
      "id": "44ab91c3-0e55-4d72-b018-6f2c8a91bb70",
      "name": "Priya Shah",
      "email": "[email protected]",
      "plan": "pro",
      "owner_id": "user_priya"
    }
  ]
}

A call with a valid key and no bearer token fails with missing_end_user_token. See the REST API

401 without a user token
{
  "error": {
    "code": "missing_end_user_token",
    "message": "An end-user bearer token is required",
    "requestId": "req_example"
  }
}

Console

See your data. Shape your database.

Tables, rows, filters, and one read-only SQL statement. Try the filter below.

Filterable sample of customers
nameemailplanowner_id
Mina Cho[email protected]prouser_mina
Jonah Hale[email protected]starteruser_jonah
Priya Shah[email protected]prouser_priya
Northwind Supply[email protected]teamuser_northwind
SQL editor · read-only
SELECT name, plan
FROM customers
WHERE plan = 'pro'
ORDER BY name

Authorization

Four checks on every request.

Each one names a different thing. None of them repairs a user column you forgot to set.

  1. 1

    Separate database

    The host is one project. Another slug is another database.

  2. 2

    Publishable key

    The apikey header must match an active cb_pub_ key for that project.

  3. 3

    End-user JWT

    From CubiBase Auth or your own IdP. The subject becomes the user id, and the session must be live.

  4. 4

    Row policy

    The API role has NOBYPASSRLS. A user column policy keeps it to matching rows.

How CubiBase works

  1. 01

    Create your project

    Verify your email, pick a slug, and wait for provisioning. The slug is the API host.

  2. 02

    Define tables and users

    Add tables in the Console. Sign up a first user through /auth/v1/signup.

  3. 03

    Connect your app

    Call https://{slug}.api.cubibase.com/rest/v1/{table} with the publishable key and the user’s JWT.

Developer experience

The request your application sends.

Filter with column=op.value. Sort with name.asc. A list comes back as { "data": [] }.

One row
GET https://example-project.api.cubibase.com/rest/v1/customers/8c1a0b2e-7d44-4a11-9c31-0b51a6e4d901
apikey: cb_pub_EXAMPLE_ONLY
Authorization: Bearer <USER_JWT>
Single-row response
{
  "data": {
    "id": "8c1a0b2e-7d44-4a11-9c31-0b51a6e4d901",
    "name": "Mina Cho",
    "email": "[email protected]",
    "plan": "pro"
  }
}

Pricing

Start free. Upgrade when the product grows.

Free, Pro, and Business plans are published with project, storage, and user quotas. Every plan includes the database, auth, REST, and the Console.

Questions developers ask first

What is CubiBase?

CubiBase is a PostgreSQL backend platform. You create a project, CubiBase provisions a database for that project, and your application calls the project’s REST API and auth endpoints. The Console is where you manage tables, rows, API keys, and a read-only SQL statement.

How does CubiBase differ from building a REST API manually?

A handwritten API needs a database, controllers, and an authorization check for every table. In CubiBase you create the table, choose which operations to expose, and call https://{slug}.api.cubibase.com/rest/v1/{table}. You still design the schema and decide which column identifies the end user.

Does each project get its own PostgreSQL database?

Yes. Creating a project stores the project and queues provisioning. When provisioning finishes, that project has its own database. Developer accounts live in a separate metadata database, cubibase_meta. Projects do not share a project database.

How are REST APIs generated?

The Data API serves any exposed table at /rest/v1/{table}. A new table is not exposed. You turn on select, insert, update, or delete for that table. The request must send the project’s publishable key and an end-user JWT. List results come back as JSON in a data array.

Can I run SQL queries?

Yes, from the Console. The SQL editor accepts one read-only statement, such as SELECT, and runs it in a read-only transaction on the project’s SQL role. Schema changes go through the table API, not through that editor. Results are capped.

Does CubiBase include authentication for my app’s users?

Yes. Every project has CubiBase Auth on the project host: /auth/v1/signup, sign-in and refresh at /auth/v1/token, logout, and TOTP multi-factor. Users live in the auth schema of your project database, passwords are hashed with Argon2id, and sessions use short-lived access JWTs with rotating refresh tokens. You can also verify RS256 tokens from your own identity provider via a JWKS URL.

How does authentication work?

Two different people authenticate. You sign in to the Console as a developer. Your application’s users either sign up through CubiBase Auth or sign in with your own identity provider. Either way each Data API request carries a JWT: HS256 signed with the project’s secret, or RS256 checked against a JWKS URL you configure. The verified subject becomes the user id for row policies.

Does CubiBase send verification emails to my end users?

Not yet. By default, signup marks the email verified immediately (autoconfirm). If you turn autoconfirm off, new users start unverified and you mark them verified through the control API. Console emails for developer accounts, such as verification and password reset, are a separate flow that does send email.

Your next application starts here.

Spend more time building what makes your product different.

first request
GET /rest/v1/customersapikey: cb_pub_…Authorization: Bearer <JWT>200 · { "data": [ … ] }