Skip to main content
The server service exposes administrative operations for the BlueBubbles Server running on your macOS machine. You can read server metadata and logs, acknowledge alerts, trigger restarts at varying levels of severity, pull media and entity statistics, and manage server updates — all through the SDK. Access the service through client.server.

Metadata and logs

getServerMetadata()

Returns metadata about the BlueBubbles Server and the underlying operating system — including the server version, macOS version, and other environment details. Signature
Example

getServerLogs()

Fetches recent log output from the BlueBubbles Server. Signature
Example

Alerts

getServerAlerts()

Returns all alerts generated by the BlueBubbles Server. Alerts include connectivity warnings, configuration issues, and other notable server events. Signature
Example

markAlertsAsRead()

Marks one or more alerts as read on the server. You must pass the IDs of the alerts you want to mark — a catch-all endpoint is intentionally not provided to avoid race conditions. Signature
Request body parameters
number[]
required
An array of alert IDs to mark as read. Retrieve alert IDs using getServerAlerts() first.
Example

Restart

restartServer()

Performs a full restart of the BlueBubbles Server application. The server closes itself completely and reopens. Signature
Example
restartServer() closes and reopens the BlueBubbles Server app entirely. Your SDK connection will drop during the restart. The Mac itself is not restarted. Build in reconnection logic if you call this programmatically.

restartServices()

Performs a soft restart of the individual services running inside BlueBubbles Server — including the HTTP service, the FCM service, and the Private API service. The server application itself stays running. Signature
Example
Prefer restartServices() over restartServer() when you only need to re-initialize a specific service (e.g., after rotating FCM credentials).

Statistics

getMediaTotals()

Returns aggregate totals for different media types (images, videos, etc.) across all chats. Signature
Example

getMediaTotalsPerChat()

Returns media totals broken down by individual chat. Useful for identifying which conversations contain the most media. Signature
Example

getImessageEntityTotals()

Returns row counts for the core iMessage database entities: handles, messages, and chats. Signature
Example

Updates

checkForServerUpdate()

Checks whether a new version of the BlueBubbles Server app is available. Returns update metadata if an update exists. Signature
Example

installServerUpdate()

Installs an available update. By default the call returns immediately without waiting for the installation to complete. Pass wait=true as a URL parameter (via requestBody) to block until the update finishes. Signature
Example
Always call checkForServerUpdate() before installServerUpdate() to confirm an update is actually available. Installing when no update exists will return an error.