ConstEvent category (e.g. 'data-capture', 'share').
Event action (e.g. 'submit', 'open').
The URI or name that identifies the subject of the event.
Optionaldata: unknownOptional payload attached to the event.
Internal tracking method; defaults to 'trackevent'.
Get a single lead retrieval event by ID.
The numeric ID of the event.
The matching Event.
MobileLockerError on network failure or if the event is not found.
Get all attendees for a lead retrieval event.
The numeric ID of the event.
Array of Attendee objects.
MobileLockerError on network failure or server error.
Get all business cards scanned by the current user.
Array of BusinessCard objects.
MobileLockerError on network failure or server error.
List all lead retrieval events available to the current user.
Array of Event objects.
MobileLockerError on network failure or server error.
Get all contacts for the current user.
Array of UserContact objects.
MobileLockerError on network failure or server error.
Get a paginated chunk of contacts starting after a given ID.
Useful for incrementally syncing large contact lists without loading everything into memory at once.
Return only contacts with an ID greater than this value.
Maximum number of contacts to return.
Array of UserContact objects.
MobileLockerError on network failure or server error.
Add a single customer to the current session without replacing existing ones.
The CRM object ID of the customer to add.
MobileLockerCRMError on network failure or server error.
Remove all customers from the current session.
MobileLockerCRMError on network failure or server error.
Get all CRM accounts synced for the current user.
Raw account records from the connected CRM.
MobileLockerCRMError on network failure, auth expiry, or server error.
Get all CRM addresses synced for the current user.
Raw address records from the connected CRM.
MobileLockerCRMError on network failure, auth expiry, or server error.
Get all CRM contacts synced for the current user.
Raw contact records from the connected CRM.
MobileLockerCRMError on network failure, auth expiry, or server error.
Get the customers currently associated with the active presentation session.
Array of Customer objects.
MobileLockerCRMError on network failure or server error.
Get the customers most recently viewed by the current user.
Array of Customer objects, newest first.
MobileLockerCRMError on network failure or server error.
Get all CRM users synced for the current team.
Raw user records from the connected CRM.
MobileLockerCRMError on network failure, auth expiry, or server error.
Check whether a CRM object is currently associated with the active session.
The CRM object ID to check (e.g. a Salesforce Account ID).
true if the customer is current, false otherwise.
MobileLockerCRMError on network failure or server error.
Open the native customer picker UI and let the user select one or more customers.
An object with status ('selected' or 'cancelled') and an optional customers array.
MobileLockerError if called outside the iOS app.
MobileLockerCRMError on network failure or server error.
Execute a SOQL query against the connected CRM.
A valid SOQL SELECT statement.
Optionalparameters: Record<string, unknown>Optional named bind parameters referenced in the SOQL string.
A CRMQueryResult containing rows, totalSize, and done.
MobileLockerCRMError with code SOQLInvalid on a syntax error, or on network/auth failure.
Trigger a CRM data refresh for the current user.
Optionaloptions: { mode?: CRMRefreshMode }Optionalmode?: CRMRefreshMode'incremental' (default) syncs only new/changed records; 'full' re-syncs everything.
An object with status: 'started' if the refresh was queued, 'not_connected' if the CRM is unreachable.
MobileLockerCRMError on auth expiry or server error.
Remove a single customer from the current session.
The CRM object ID of the customer to remove.
MobileLockerCRMError on network failure or server error.
Replace the current customers for the active session.
Array of CRM object IDs to set as current.
MobileLockerCRMError on network failure or server error.
Submit a data capture form event.
Records the form submission in the Mobile Locker analytics pipeline under
the 'data-capture' category. Use this to track lead forms, survey responses,
or any structured input the user submits during a presentation.
Identifier for the form (e.g. 'lead-form', 'product-interest').
Key/value pairs representing the form fields and their values.
Describe the schema of a table in a SQLite database.
In local development, falls back to sql.js and reads the schema directly
from the database file via PRAGMA table_info.
Path to the .sqlite file (relative to the presentation root).
Name of the table to inspect.
A DatabaseTableDescription with name, sql, and columns.
MobileLockerDatabaseError with code InvalidPath if the table does not exist.
List the SQLite database files available to the current presentation.
Array of database file path strings.
MobileLockerDatabaseError on network failure or server error.
Execute a SQL SELECT query against a SQLite database embedded in the presentation.
In local development, falls back to sql.js and fetches the database file directly.
Only SELECT statements are permitted — write operations throw WriteNotPermitted.
Path to the .sqlite file (relative to the presentation root).
A SQL SELECT statement, optionally with ? or :name placeholders.
Positional array or named object of bind parameters.
A DatabaseQueryResult with rows, rows_affected, and last_insert_row_id.
MobileLockerDatabaseError with codes InvalidPath, WriteNotPermitted,
NotReady, QueryFailed, or NotConnected.
Get hardware and app metadata for the current device.
A DeviceInfo object, or null outside the iOS app.
Check whether the Mobile Locker app version meets a minimum requirement.
Minimum required version string in major.minor.patch format (e.g. '5.2.0').
true if the current app version is equal to or greater than version.
Make an HTTP request with full control over method and options.
MobileLockerHTTPError on network failure or timeout.
MobileLockerHttpResponseError on non-2xx responses.
Make a DELETE request to an external URL.
The full URL to request.
Optionaloptions: HTTPOptionsOptional headers, timeout, and response type.
An HTTPResponse.
MobileLockerHTTPError on network failure or timeout.
MobileLockerHttpResponseError on non-2xx responses.
Make a GET request to an external URL.
In the iOS app, requests are proxied through the native layer to bypass CORS.
In the browser, standard fetch is used and CORS rules apply.
The full URL to request.
Optionaloptions: HTTPOptionsOptional headers, timeout, and response type.
An HTTPResponse with status, statusText, headers, and data.
MobileLockerHTTPError on network failure or timeout.
MobileLockerHttpResponseError on non-2xx responses.
Make a PATCH request to an external URL.
The full URL to request.
Optionalbody: unknownRequest body, serialized as JSON.
Optionaloptions: HTTPOptionsOptional headers, timeout, and response type.
An HTTPResponse.
MobileLockerHTTPError on network failure or timeout.
MobileLockerHttpResponseError on non-2xx responses.
Make a POST request to an external URL.
The full URL to request.
Optionalbody: unknownRequest body, serialized as JSON.
Optionaloptions: HTTPOptionsOptional headers, timeout, and response type.
An HTTPResponse.
MobileLockerHTTPError on network failure or timeout.
MobileLockerHttpResponseError on non-2xx responses.
Make a PUT request to an external URL.
The full URL to request.
Optionalbody: unknownRequest body, serialized as JSON.
Optionaloptions: HTTPOptionsOptional headers, timeout, and response type.
An HTTPResponse.
MobileLockerHTTPError on network failure or timeout.
MobileLockerHttpResponseError on non-2xx responses.
Delete all SDK log entries for the current presentation and user.
MobileLockerError on network failure or server error.
Write a debug-level log entry into the SDK log store.
Human-readable description of the event.
Optionalmetadata: Record<string, unknown>Optional key/value data to attach to the entry.
Delete a single SDK log entry by ID.
The numeric ID of the entry to delete.
MobileLockerError on network failure or server error.
Write an error-level log entry into the SDK log store.
Human-readable description of the event.
Optionalmetadata: Record<string, unknown>Optional key/value data to attach to the entry.
Retrieve structured SDK log entries with optional filtering.
In the iOS app, fetches from the server-side GRDB table scoped to the current team, user, presentation, and device session. Outside the app, reads from IndexedDB via localforage (same entry shape, up to 1,000 entries).
Optionalfilter: SDKLogFilterOptional filter by level, domain, function, date range, retries, and limit.
Array of SDKLogEntry objects, newest first.
MobileLockerError on network failure or server error.
Write an info-level log entry into the SDK log store.
Human-readable description of the event.
Optionalmetadata: Record<string, unknown>Optional key/value data to attach to the entry.
Check whether debug mode is currently enabled.
true if debug mode is on.
Mark the current session as a live (non-practice) presentation.
Optional URI or identifier to associate with the event.
Mark the current session as a practice presentation.
Optional URI or identifier to associate with the event.
Full-text search across SDK log entries.
Searches the message field and stringified metadata. Accepts the same
filter options as getSdkLogs to narrow the scope before searching.
The search string.
Optionalfilter: SDKLogFilterOptional pre-filter applied before the text search.
Array of matching SDKLogEntry objects.
MobileLockerError on network failure or server error.
Enable or disable debug mode.
Pass true to enable, false to disable.
Write a warn-level log entry into the SDK log store.
Human-readable description of the event.
Optionalmetadata: Record<string, unknown>Optional key/value data to attach to the entry.
Get the current network connectivity status.
In the iOS app, returns accurate connection type from the native layer.
In the browser, falls back to navigator.onLine — note that this may
return true on captive portals even without real internet access.
A NetworkStatus object with connected and type.
Close the current presentation and return to the app home screen.
Queue a presentation for download to the device.
The numeric ID of the presentation to download.
An object with status: 'queued', 'already_installed', 'not_available', or 'not_permitted'.
MobileLockerError on network failure or server error.
Get the presentation that is currently open.
The current Presentation.
MobileLockerError on network failure or server error.
Get all presentations available to the current user.
Array of Presentation objects.
MobileLockerError on network failure or server error.
Get a presentation by its numeric ID.
The presentation ID.
The matching Presentation.
MobileLockerError on network failure, or if not found.
Get a presentation by its name.
The presentation name (case-sensitive).
The matching Presentation.
MobileLockerError on network failure, or if not found.
Get the analytics events recorded for the current presentation session.
Array of raw event objects.
MobileLockerError on network failure or server error.
Open a presentation by its external CRM ID.
The external identifier for the presentation (e.g. a Salesforce ID).
MobileLockerError if called outside the iOS app.
Open a presentation by its numeric ID.
The numeric ID of the presentation to open.
MobileLockerError if called outside the iOS app.
Open a presentation by its name.
The presentation name (case-sensitive).
MobileLockerError if called outside the iOS app.
Open the native presentation picker so the user can choose a presentation to open.
MobileLockerError if called outside the iOS app.
Refresh the list of available presentations from the server.
Updated array of Presentation objects.
MobileLockerError on network failure or server error.
Reload the current presentation's web content.
Triggers a full page reload inside the presentation webview.
Open the native badge scanner and capture an event attendee.
The lead retrieval event ID to associate the scan with.
A ScanResult — check status before accessing attendee.
MobileLockerError if called outside the iOS app.
Open the native business card scanner and capture a contact.
OptionaleventID: numberOptional lead retrieval event ID to associate the scan with.
A ScanResult — check status before accessing businessCard.
MobileLockerError if called outside the iOS app.
Search across multiple entity types simultaneously.
Returns results grouped by type. Use options.types to restrict the search
to specific entities and options.limit to control result set size per type.
The search string.
Optional filter for entity types and result limit.
A SearchResults object with a result set for each entity type.
MobileLockerError on network failure or server error.
Get all analytics events recorded during the current device session.
In the iOS app, fetches events from the server scoped to the current session. Outside the app (local development), returns events buffered in IndexedDB via localforage.
Array of raw event objects.
Send an email through the Mobile Locker platform.
Recipient email string, or an object with email and optional name.
Email subject line.
Optional email body text.
Optional path to a file to attach.
Optional email template identifier.
Optional additional form data to include with the email record.
Share the current presentation with one or more recipients.
Sends the presentation link via the Mobile Locker platform. No-op outside the Mobile Locker environment (e.g. local development).
One or more recipients, each requiring at least an email.
Controls when recipients receive email notifications.
Use the mobilelocker.notificationLevels constants. Defaults to NOTIFY_EVERY (2).
Whether to send follow-up reminder emails. Defaults to true.
MobileLockerError if recipients is empty or any recipient is missing an email.
Delete the storage entry with the given name.
The key name of the entry to delete.
MobileLockerError on network failure or server error.
Get a single storage entry by name for the current presentation and user.
The key name of the entry to retrieve.
The matching StorageEntry, or null if not found.
MobileLockerError on network failure or server error.
Get all storage entries for the current presentation and user.
Array of StorageEntry objects.
MobileLockerError on network failure or server error.
Get all storage entries for the current user across all presentations.
Array of StorageEntry objects.
MobileLockerError on network failure or server error.
Get all storage entries for a specific presentation by ID.
The numeric ID of the presentation.
Array of StorageEntry objects.
MobileLockerError on network failure or server error.
Query storage entries with optional filtering.
Outside the Mobile Locker app, filters are applied locally against IndexedDB.
Optionalfilter: StorageFilterOptional filter by name, presentation, date range, and limit.
Array of matching StorageEntry objects.
MobileLockerError on network failure or server error.
Save a value to storage under the given name.
Creates a new entry if one does not exist, or updates the existing entry. Outside the Mobile Locker app, persists to IndexedDB via localforage.
The key name for the entry.
Any JSON-serializable value to store.
The saved StorageEntry.
MobileLockerError on network failure or server error.
Full-text search across storage entry names and data.
The search string. Matched against name and the stringified data.
Optionalfilter: StorageFilterOptional pre-filter applied before the text search.
Array of matching StorageEntry objects.
MobileLockerError on network failure or server error.
Open a PDF file in the platform viewer.
In the iOS app, opens the native PDF viewer with annotation support. In the browser, opens the file in a new tab.
Path to the PDF file, relative to the presentation root.
Display title for the viewer.
OptionalcustomOptions: Record<string, unknown>Optional extra properties passed through to the analytics event.
Open a video file in the platform player.
In the iOS app, uses the native AVPlayer with full option support.
In the browser, renders a full-viewport <video> overlay. Click outside
the video to dismiss it.
Path to the video file, relative to the presentation root.
Playback options (autoplay, loop, controls, speed, etc.).
A VideoResult with status and final playback position in seconds.
Get the currently authenticated user.
The authenticated User.
MobileLockerError on network failure or server error.
Track a custom analytics event.