Pubflow Schema Explorer

Understand the core structure behind Pubflow + Flowless

A friendly map of core tables, optional modules, and migration-ready SQL snippets so teams can move fast across engines.

How trust flows
Flowless handles identity, Flowfull handles your business logic.
Client App
Web, mobile, or desktop sends a session id.
session_id
Flowfull Backend
Validates sessions through bridge validation and applies your app rules.
bridge validation + trust token
Flowless Auth Core
Issues trust context, sessions, tokens, and secure identity state.

Core Tables and Extensions

Portable schema style: SQL-first, production-safe, and database-flexible.

Tap or hover any column to learn what it stores and its format.

Coreusers
Users
Identity, profile, verification, and account-level metadata.
  • id
  • email
  • name
  • last_name
  • user_name
  • user_type
  • picture
  • phone
  • mobile
  • password_hash
  • is_verified
  • two_factor
  • lang
  • metadata
  • tmz
  • bio
  • dob
  • gender
  • display_name
  • recovery_email
  • reference_id
  • first_time
  • deleted_at
  • deletion_reason
  • created_at
  • updated_at
Coresessions
Sessions
Session lifecycle, security context, and 2FA verification status.
  • id
  • session_prefix
  • user_id
  • status
  • expires_at
  • ip_address
  • user_agent
  • user_device
  • last_used_at
  • two_factor_verified
  • two_factor_verified_at
  • two_factor_methods
  • created_at
Coreuser_accounts
User Accounts
OAuth and social providers linked to each user.
  • user_id
  • provider
  • provider_user_id
  • provider_email
  • provider_name
  • provider_picture
  • access_token
  • refresh_token
  • token_expires_at
  • metadata
  • linked_at
  • last_updated
  • is_primary
  • raw_data
Coretokens
Tokens
Password reset, verification, and one-time action flows.
  • token
  • token_type
  • type
  • identifier_value
  • user_id
  • attempts_remaining
  • status
  • expires_at
  • consumed_at
  • context
  • metadata
Infrarate_limits
Rate Limits
Infrastructure safety bucket for anti-abuse controls.
  • key
  • points
  • expires
Moduletwo_factor
Two-Factor
Method-level state for OTP, email, SMS, and passkey extensions.
  • user_id
  • method
  • code
  • token_prefix
  • status
  • metadata
  • last_used_at
Moduleposts
Blog Posts
Modular content system with status, visibility, and publishing controls.
  • user_id
  • lang
  • title
  • slug
  • status
  • visibility
  • published_at
Interactive migration helper
Choose a table and database engine to get a starter SQL snippet aligned with the Pubflow style.

Default core-table bootstrap

CREATE_REQUIRED_TABLES is true by default. You can change it if needed. When enabled, Flowless creates all core tables internally with a secure bootstrap flow.

# default
CREATE_REQUIRED_TABLES=true

# optional override
CREATE_REQUIRED_TABLES=false

Pick table

Pick database

PostgreSQL dialect

-- PostgreSQL migration helper
-- Source style: pubflow flowless core (portable SQL-first)

CREATE TABLE IF NOT EXISTS users (
  id TEXT PRIMARY KEY,
  name TEXT,
  last_name TEXT,
  email TEXT NOT NULL UNIQUE,
  user_type TEXT NOT NULL DEFAULT 'customer',
  picture TEXT,
  user_name TEXT UNIQUE,
  password_hash TEXT,
  is_verified BOOLEAN NOT NULL DEFAULT FALSE,
  phone TEXT UNIQUE,
  two_factor BOOLEAN NOT NULL DEFAULT FALSE,
  lang TEXT,
  metadata JSONB,

  -- Enhanced profile
  mobile TEXT,
  tmz TEXT,
  bio TEXT,
  dob TEXT,
  recovery_email TEXT,
  display_name TEXT,
  first_time BOOLEAN NOT NULL DEFAULT TRUE,
  deleted_at TEXT,
  deletion_reason TEXT,
  gender TEXT,
  reference_id TEXT,

  created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
  updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);

CREATE INDEX IF NOT EXISTS idx_users_email ON users(email);
CREATE INDEX IF NOT EXISTS idx_users_user_name ON users(user_name);
CREATE INDEX IF NOT EXISTS idx_users_user_type ON users(user_type);

-- Optional upsert example
INSERT INTO users (id, email, name, user_type, lang) VALUES ('user_1', 'dev@pubflow.com', 'Dev', 'customer', 'en')
ON CONFLICT (id) DO UPDATE SET updated_at = CURRENT_TIMESTAMP;
These snippets are migration starters. Keep your IDs, indexes, and constraints aligned with your production requirements.
Modular by design
Pubflow starts lean and grows with modules.

Two-Factor Module

Two-factor module adds dedicated method tracking and secure verification states.

This is just the beginning. We actively receive feature and module requests.

Try your flow now
Experiment in the playground or request a new module for your use case.
Go to playgroundSend feature request

Flowless Documentation

Explore session schemas, token flows, bridge validation, and every table in depth — all documented, open, and production-ready.

flowless.dev

One platform. Trusted by design.