createClientFromRequest(Creates a Base44 client from an HTTP request. This function is designed for use in Base44-hosted backend functions. For frontends and external backends, userequest):Base44Client
createClient() instead.
When used in a Base44-hosted backend function, createClientFromRequest() automatically extracts authentication tokens from the request headers that Base44 injects when forwarding requests. The returned client includes service role access using base44.asServiceRole, which provides admin-level permissions.
To learn more about the Base44 client, see createClient().
Parameters
The incoming HTTP request object containing Base44 authentication headers.
Returns
Base44Client
The Base44 client instance.
Provides access to all SDK modules for interacting with the app.
A configured Base44 client instance with authentication from the incoming request.
Properties
Properties
Agents module for managing AI agent conversations.
Analytics module for tracking custom events in your app.
App logs module for tracking app usage.
Auth module for user authentication and management.
Entities module for CRUD operations on your data models.
Functions module for invoking custom backend functions.
Integrations module for calling pre-built integration endpoints.
Cleanup function to disconnect WebSocket connections. Call when you’re done with the client.
Provides access to supported modules with elevated permissions.Service role authentication provides elevated permissions for backend operations. Unlike user authentication, which is scoped to a specific user’s permissions, service role authentication has access to the data and operations available to the app’s admin.
Properties
Properties
Agents module with elevated permissions.
App logs module with elevated permissions.
Connectors module for OAuth token retrieval.
Entities module with elevated permissions.
Functions module with elevated permissions.
Integrations module with elevated permissions.
Cleanup function to disconnect WebSocket connections.

