UNPKG

unifi-client

Version:

NodeJs client for Unifi products (https://www.ui.com/)

63 lines (62 loc) 2.18 kB
/// <reference types="debug" /> import { ISite } from './ISite'; import { Hotspots } from '../Hotspot'; import { Clients } from '../Clients'; import { Firewall } from '../Firewall'; import { _ObjectSubController } from '../commons/_ObjectSubController'; import { Controller } from '../Controller'; import { INetworkStatus } from './INetworkStatus'; import { UnifiWebsockets } from '../WebSockets'; import { Stats } from '../Stats'; import { IUnifiResponseEnveloppe } from '../interfaces'; import { ClientsGroups } from '../Clients/ClientsGroups'; import { Devices } from '../Devices'; import type { BaseDevice } from '../Devices'; import { ISiteSettingsManagement, tSiteSettings } from './ISiteSettings'; import { Networks } from '../Networks'; export declare class Site extends _ObjectSubController implements ISite { static debug: import("debug").Debugger; /** * internal id */ _id: string; /** * an uuid of the site */ anonymous_id: string; /** * the technical name of the site (seems autogenerated) */ name: string; /** * the name you setup for this site */ desc: string; attr_hidden_id: string; attr_no_delete: boolean; role: string; role_hotspot: boolean; firewall: Firewall; hotspots: Hotspots; clients: Clients; clientsGroups: ClientsGroups; ws: UnifiWebsockets; stats: Stats; devices: Devices; networks: Networks; constructor(controller: Controller, props: ISite); adoptDevice(device: string | BaseDevice): Promise<unknown>; /** * * @param enable - true switches LEDs of all the access points ON, false switches them OFF */ enableLEDs(enable?: boolean): Promise<ISiteSettingsManagement>; getSettings(): Promise<Array<tSiteSettings>>; settingsManager<T>(settings: Record<string, unknown>): Promise<IUnifiResponseEnveloppe<T>>; devManager<T>(payload: Record<string, unknown> & { cmd: string; }): Promise<IUnifiResponseEnveloppe<T>>; initWebSockets(): Promise<void>; on(eventName: string, cb: (...args: Array<unknown>) => unknown): this; getNetworkStatus(): Promise<INetworkStatus>; }