Skip to main content

Minimal integration,
end-to-end control.

Sign in with WeChat, phone, email, username, or custom identity — then use the same identity for database, functions, and storage permissions.

Identity · JWT · Role & Policy
cloudbase / identityauth ready
Sign-in methods
recommended

WeChat sign-in

Mini Program / Official Account

provider

Phone

SMS code

provider

Email

Code / password

provider

Username & password

Web

provider

Anonymous

Try first, upgrade later

provider

Custom login

Connect existing accounts

Everything identity needs,
connected from day one

WPEUACWEPAUCWEPACUWP

Sign-in built for China-market apps

Combine WeChat, phone, email, username, anonymous, and custom identity by scenario.

verified identityusr_8f31authenticated · wechat
resource policyowner_id = auth.uid()access granted

From sign-in to resource permissions

Identity is not bolted on — sessions, JWT, database, and security rules share one user context.

Identity datausers · sessions · providers

Identity data stays in your environment

Manage users, sessions, and linked identities, and connect accounts to your business data.

Good identity is not just another login page.
It lets your code stop guessing who sent each request.
CloudBase product design principleIdentity · Session · Authorization

From consumer sign-in to service authorization,
every layer knows the current user

WeChat identity

  • Official account & Open Platform OAuth
  • OpenID / UnionID link users
  • Trusted WeChat context on the server
  • Works with data security rules
Learn more

Custom login

  • Connect existing business accounts
  • Map to CloudBase user identity
  • Link with WeChat identity
  • Reuse platform resource access
Learn more

Roles & policies

  • JWT groups enter authorization context
  • Layer anonymous and authenticated users
  • Database RLS down to each row
  • OPA policies guard service entry points
Learn more

Pick a sign-in entry,
use the same identity API

JavaScript
const auth = app.auth()

const loginState = await auth.signIn({
  username,
  password
})

console.log(loginState.user)

Identity continues into the database,
protect every row with RLS

PostgreSQL reads the current user from JWT claims; policies define ownership and operations alongside tables.

profiles-policy.sqlRLS enabled
alter table public.profiles
  enable row level security;

create policy profiles_owner_read
  on public.profiles
  for select to authenticated
  using (owner_id = (select auth.uid()));
authenticatedauth.uid()

Build from a complete identity model

View all examples
WeChat
WeChat

WeChat user system

Official account & Open Platform login, linking, and profiles.

Web
Web

Email & password

Registration, verification, sign-in, session refresh, and passwords.

Growth
Growth

Anonymous to registered

Create private data first, then link to a full account.

Enterprise
Enterprise

Existing account integration

Connect business users to CloudBase via custom login.

Connect identity first,
then let the platform handle authorization

Enable the sign-in methods you need and define clear boundaries for roles, data, and resources.