entities module lets you work with your app’s data. Each entity type in your app has methods for creating, reading, updating, and deleting records.
You access entity methods through your entity name: base44.entities.YourEntityName.methodName(). For example, if you have a Task entity, you use base44.entities.Task.list() to get a list of tasks.
Permissions
Data access is controlled by the client’s authentication mode and your app’s permission rules. You can configure the permissions for each entity in your app’s security settings. Learn more about changing data permissions.- Anonymous users: Can only access entities marked as public.
- Authenticated users: Can access entities and records they have permission to view or modify based on your app’s configured access rules.
- Service role: Bypasses entity access rules and field-level security entirely. Has full read and write access to every entity and record in the app.
Create records
Usecreate() to add new records to an entity:
Read records
Retrieve data usingget() for a single record, list() for all records, or filter() for records matching specific criteria.
Use get() with a record ID to retrieve a specific record:
list() to retrieve all records. The method supports sorting, pagination, and field selection:
filter() to find records that match specific criteria:
Update records
Useupdate() to modify an existing record:
Delete records
Usedelete() to remove a single record:
deleteMany() to remove multiple records matching specific criteria:
Bulk operations
UsebulkCreate() to create multiple records in a single request:
importEntities() to import records from a CSV file. This is useful for migrating data or bulk uploads from user interfaces:
importEntities() requires a browser environment and cannot be used in
backend code.Realtime subscriptions
Usesubscribe() to receive realtime updates when records are created, updated, or deleted:
Service role data access
By default, data access is scoped to the current user’s permissions. With service role authentication, you can read and write any data in your app. Entity access rules and field-level security are bypassed entirely, regardless of how the entity is configured. Usebase44.asServiceRole.entities to access data without access-rule restrictions:
User entity
Every Base44 app includes a built-inUser entity that stores user account information. This entity has special security rules:
- Regular users can only read and update their own user record
- With service role authentication, you can read, update, and delete any user
- You cannot create users through the entities module - use the
authmodule instead
See more
entities module
Complete API reference
Base44 client
Learn about the client and service role