node-hue-api
- Version 5.0.0-beta.16
- Published
- 1.08 MB
- 4 dependencies
- Apache-2.0 license
Install
npm i node-hue-api
yarn add node-hue-api
pnpm add node-hue-api
Overview
Philips Hue API Library for Node.js
Index
Variables
variable v3
const v3: { api: typeof api; discovery: { upnpSearch: ( timeout: number ) => Promise< import('./api/discovery/discoveryTypes').DiscoveryBridgeDescription[] >; nupnpSearch: () => Promise< import('./api/discovery/discoveryTypes').BridgeDiscoveryResponse[] >; description: ( ipAddress: string ) => Promise< | import('./api/discovery/discoveryTypes').DiscoveryBridgeDescription | undefined >; }; lightStates: { LightState: typeof model.LightState; GroupLightState: typeof model.GroupState; SceneLightState: typeof model.SceneLightState; }; model: { lightStates: { LightState: typeof model.LightState; GroupLightState: typeof model.GroupState; SceneLightState: typeof model.SceneLightState; }; timePatterns: { weekdays: any; isRecurring: any; createAbsoluteTime: ( value: | string | Date | import('@peter-murray/hue-bridge-model/dist/esm/time').AbsoluteTime ) => any; createRandomizedTime: ( value: | string | Date | import('@peter-murray/hue-bridge-model/dist/esm/time').RandomizedTime ) => any; createRecurringTime: ( weekdays: number, value: | string | Date | import('@peter-murray/hue-bridge-model/dist/esm/time').RecurringTime ) => any; createRecurringRandomizedTime: ( value: | string | Date | import('@peter-murray/hue-bridge-model/dist/esm/time').RecurringRandomizedTime ) => any; createTimeInterval: ( value: | string | import('@peter-murray/hue-bridge-model/dist/esm/time').TimeInterval ) => any; createTimer: ( value: | string | import('@peter-murray/hue-bridge-model/dist/esm/time').Timer ) => any; createRecurringTimer: ( value: | string | Date | import('@peter-murray/hue-bridge-model/dist/esm/time').RecurringTimer ) => any; createRandomizedTimer: ( value: | string | import('@peter-murray/hue-bridge-model/dist/esm/time').RandomizedTimer ) => any; createRecurringRandomizedTimer: ( value: | string | import('@peter-murray/hue-bridge-model/dist/esm/time').RecurringRandomizedTimer ) => any; createFromString: any; isTimePattern: (str: string) => boolean; }; createEntertainment: () => model.Entertainment; createLightGroup: () => model.LightGroup; createRoom: () => model.Room; createZone: () => model.Zone; createCLIPGenericFlagSensor: () => model.CLIPGenericFlag; createCLIPGenericStatusSensor: () => model.CLIPGenericStatus; createCLIPHumiditySensor: () => model.CLIPHumidity; createCLIPLightlevelSensor: () => model.CLIPLightlevel; createCLIPOpenCloseSensor: () => model.CLIPOpenClose; createCLIPPresenceSensor: () => model.CLIPPresence; createCLIPTemperatureSensor: () => model.CLIPTemperature; createCLIPSwitchSensor: () => model.CLIPSwitch; createLightScene: () => model.LightScene; createGroupScene: () => model.GroupScene; createSchedule: () => model.Schedule; actions: { light: (light: string | number | model.Light) => model.LightStateAction; group: (group: string | number | model.Group) => model.GroupStateAction; sensor: ( sensor: string | number | model.Sensor ) => model.SensorStateAction; scene: (scene: string | model.Scene) => model.SceneAction; }; createRule: () => model.Rule; ruleConditions: { sensor: (sensor: model.Sensor) => model.SensorCondition; group: (id: string | number | model.Group) => model.GroupCondition; }; createResourceLink: () => model.ResourceLink; };};
Classes
class ApiError
class ApiError extends Error {}
constructor
constructor(message: string | HueError, error?: HueError);
method getHueError
getHueError: () => HueError | undefined;
method getHueErrorAddress
getHueErrorAddress: () => string | undefined;
method getHueErrorDescription
getHueErrorDescription: () => string | undefined;
method getHueErrorMessage
getHueErrorMessage: () => string | undefined;
method getHueErrorType
getHueErrorType: () => number;
Namespaces
namespace api
module 'dist/esm/api/index.d.ts' {}
Creates a remote bootstrap to connect with a Hue bridge remotely
Parameter clientId
The OAuth client id for your application.
Parameter clientSecret
The OAuth client secret for your application.
function createInsecureLocal
createInsecureLocal: ( host: string, port?: number, rateLimits?: HueApiRateLimits) => LocalInsecureBootstrap;
Creates a local network bootstrap over an insecure HTTP connection.
Parameter host
The IP Address or FQDN of the he bridge you are connecting to.
Parameter port
The port number to connect to, optional.
function createLocal
createLocal: ( host: string, port?: number, rateLimits?: HueApiRateLimits) => LocalBootstrap;
Creates a local network bootstrap to connect with Hue bridge on a local network.
Parameter host
The IP Address or FQDN of the he bridge you are connecting to.
Parameter port
The port number to connect to, optional.
function createRemote
createRemote: ( clientId: string, clientSecret: string, rateLimits?: HueApiRateLimits) => RemoteBootstrap;
Creates a remote bootstrap to connect with a Hue bridge remotely
Parameter clientId
The OAuth client id for your application.
Parameter clientSecret
The OAuth client secret for your application.
namespace discovery
module 'dist/esm/api/discovery/index.d.ts' {}
function description
description: ( ipAddress: string) => Promise<DiscoveryBridgeDescription | undefined>;
function mdnsSearch
mdnsSearch: (timeout?: number) => Promise<DiscoveryBridgeDescription[]>;
function nupnpSearch
nupnpSearch: () => Promise<BridgeDiscoveryResponse[]>;
Package Files (5)
Dependencies (4)
Dev Dependencies (8)
Peer Dependencies (0)
No peer dependencies.
Badge
To add a badge like this oneto your package's README, use the codes available below.
You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/node-hue-api
.
- Markdown[![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/node-hue-api)
- HTML<a href="https://www.jsdocs.io/package/node-hue-api"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>
- Updated .
Package analyzed in 6073 ms. - Missing or incorrect documentation? Open an issue for this package.