Accounts, roles and permissions
Short answerpomela apps have real accounts: sign-up, invitations and password reset, emailed by the app. Each person has a role, such as owner, staff or customer, and each role has access rules for every kind of record. The server enforces those rules on every read and every write, so hiding a button is never the only protection.
Accounts
- Sign-up and sign-in with email and password.
- Invitations: you add staff or customers, and the app emails them.
- Password reset by email.
- Visitors without an account, where you allow it: for example booking without signing up, with a private link to see or cancel.
Roles
A role is a kind of person who uses the app. A clinic app might have owner, receptionist, therapist and patient. You name the roles in the request, or pomela proposes them from the kind of app, and each role gets its own screens and its own access.
Access rules on the server
For every kind of record, each role has rules: may it see the record, create one, change it, delete it, and which records: all of them, or only its own. These rules live on the server. When a request reaches the app, the server checks the rule before it reads or writes anything. A customer who changes a link or calls the app directly still gets only their own records.
Rules that guard people's data wait for you
If an access rule could expose people's details, it waits for your approval before it is published. Files follow the record they belong to: only people who may read the record can open its files.
Tested on every build
Every build signs in as each kind of person and tries to reach what that person should not. An attempt that gets through stops the Ready verdict.
Frequently asked questions
Can each customer see only their own data?
Yes. Ask for it in the request; the server enforces it on every read and write, and every build tests it.
Can staff do some things but not others?
Yes. Say what each role may see and change; for example, staff mark bookings as done but do not see revenue.