Home Automation blog

Skip to Content

NodeRed HomeKit Service reference

Article image for NodeRed HomeKit Service reference

Posted by Chris

Date posted:

NodeRed's HomeKit package has a distinct lack of documentation and/or examples which I found to be a bit of a roadblock. This post aims to remedy the situation. What follows is a list of Services and Characteristics that can (and how to) be implemented.

Each code example is typically going to use a Function node as an input node to each HomeKit node. You could also use an Inject node to send a JSON object to each HomeKit node. See examples.

Services


AirPurifier

Required characteristics:

Optional characteristics:

See examples


AirQualitySensor

Required characteristics:

Optional characteristics:

See examples


BatteryService

Note: This service is unsupported by the native Apple Home app. 3rd party apps and Siri only.

Required characteristics:

Optional characteristics:

See examples


CameraRTPStreamManagement

Required characteristics:

Optional characteristics:

See examples


CarbonDioxideSensor

Required characteristics:

Optional characteristics:

See examples


CarbonMonoxideSensor

Required characteristics:

Optional characteristics:

See examples


ContactSensor

Required characteristics:

Optional characteristics:

See examples


Door

Required characteristics:

Optional characteristics:

See examples


Doorbell

Required characteristics:

Optional characteristics:

See examples


Fan

Note: Might depreciated in future versions. See Fanv2

Required characteristics:

Optional characteristics:

See examples


Fanv2

Required characteristics:

Optional characteristics:

See examples


Faucet

Note: This service is unsupported by the native Apple Home app. 3rd party apps and Siri only.

Required characteristics:

Optional characteristics:

See examples


FilterMaintenance

Note: This service is unsupported by the native Apple Home app. 3rd party apps and Siri only.

Required characteristics:

Optional characteristics:

See examples


GarageDoorOpener

Required characteristics:

Optional characteristics:

See examples


HeaterCooler

Required characteristics:

Optional characteristics:

See examples


HumidifierDehumidifier

Required characteristics:

Optional characteristics:

See examples


HumiditySensor

Required characteristics:

Optional characteristics:

See examples


IrrigationSystem

Required characteristics:

Optional characteristics:

See examples


LeakSensor

Required characteristics:

Optional characteristics:

See examples


LightSensor

Required characteristics:

Optional characteristics:

See examples


Lightbulb

Required characteristics:

Optional characteristics:

See examples


LockMechanism

Required characteristics:

Optional characteristics:

See examples


Microphone

Note: This service is unsupported by the native Apple Home app. 3rd party apps and Siri only.

Required characteristics:

Optional characteristics:

See examples


MotionSensor

Required characteristics:

Optional characteristics:

See examples


OccupancySensor

Required characteristics:

Optional characteristics:

See examples


Outlet

Required characteristics:

Optional characteristics:

  • None

See examples


PlaybackDeviceService

Required characteristics:

Optional characteristics:

See examples


SecuritySystem

Required characteristics:

Optional characteristics:

See examples


Slat

Note: This service is unsupported by the native Apple Home app. 3rd party apps and Siri only.

Required characteristics:

Optional characteristics:

See examples


SmokeSensor

Required characteristics:

Optional characteristics:

See examples


Speaker

Note: This service is unsupported by the native Apple Home app. 3rd party apps and Siri only.

Required characteristics:

Optional characteristics:

See examples


StatelessProgrammableSwitch

Required characteristics:

Optional characteristics:

  • None

See examples


Switch

Required characteristics:

Optional characteristics:

  • None

See examples


TemperatureSensor

Required characteristics:

Optional characteristics:

See examples


Thermostat

Required characteristics:

Optional characteristics:

See examples


Valve

Note: This service is unsupported by the native Apple Home app. 3rd party apps and Siri only.

Required characteristics:

Optional characteristics:

See examples


Window

Required characteristics:

Optional characteristics:

See examples


WindowCovering

Required characteristics:

Optional characteristics:

See examples


Examples

Inject node as input to homekit node:

{
	"TargetDoorState": 1
}

Function node as input to homekit node:

var characteristic = {};

characteristic.TargetDoorState = 1;
characteristic.CurrentDoorState = 1;
characteristic.ObstructionDetected = false;

msg.payload = characteristic;
return msg;

Function node as output from homekit node:

if ('TargetDoorState' in msg.payload)
{
    // Door state changed
}

View similar posts categorised as: Node RED HomeKit