@camera.ui/sdk / manager / CoreManager
Interface: CoreManager
Defined in: manager/index.ts:41
Core manager interface for system-level operations.
Provides access to cross-cutting services like the FFmpeg binary path, server addresses, HMAC signing for cloud requests, inter-plugin lookup, and a stream of core system events.
Accessed via api.coreManager in plugins.
Example
const ffmpeg = await api.coreManager.getFFmpegPath();
const addresses = await api.coreManager.getServerAddresses();
api.coreManager.onEvent.subscribe(({ type, data }) => {
if (type === 'cloudAccountChanged') {
console.log('Cloud account state:', data);
}
});Properties
onEvent
readonlyonEvent:Observable<CoreManagerEvent>
Defined in: manager/index.ts:96
Observable for core manager events (e.g. cloud account changes).
Example
api.coreManager.onEvent.subscribe(({ type, data }) => {
if (type === 'cloudAccountChanged') {
console.log('Cloud account changed:', data.connected);
}
});Methods
connectToPlugin()
connectToPlugin(
pluginName):Promise<BasePlugin<Record<string,any>> &Partial<MotionDetectionInterface&ObjectDetectionInterface&AudioDetectionInterface&FaceDetectionInterface&LicensePlateDetectionInterface&ClassifierDetectionInterface&ClipDetectionInterface&DiscoveryProvider&NotifierInterface> |undefined>
Defined in: manager/index.ts:49
Connect to another plugin by name.
Parameters
pluginName
string
Name of the plugin to connect to
Returns
Promise<BasePlugin<Record<string, any>> & Partial<MotionDetectionInterface & ObjectDetectionInterface & AudioDetectionInterface & FaceDetectionInterface & LicensePlateDetectionInterface & ClassifierDetectionInterface & ClipDetectionInterface & DiscoveryProvider & NotifierInterface> | undefined>
Plugin proxy or undefined if not found
getCloudServerId()
getCloudServerId():
Promise<string>
Defined in: manager/index.ts:73
Get the cloud server identity this server is registered as.
Returns the cloud server_id from the active cloud pairing, or an empty string when the server is not connected to the cloud.
Returns
Promise<string>
Cloud server id, or an empty string if not paired
getFFmpegPath()
getFFmpegPath():
Promise<string>
Defined in: manager/index.ts:56
Get the FFmpeg executable path.
Returns
Promise<string>
Path to FFmpeg binary
getPluginsByInterface()
getPluginsByInterface(
interfaceName):Promise<PluginInfo[]>
Defined in: manager/index.ts:82
Get all active plugins that implement a specific interface.
Parameters
interfaceName
Name of the plugin interface (e.g., 'ClipDetection')
Returns
Promise<PluginInfo[]>
Array of plugin info objects
getServerAddresses()
getServerAddresses():
Promise<string[]>
Defined in: manager/index.ts:63
Get server addresses (IP addresses the server is listening on).
Returns
Promise<string[]>
Array of server addresses