Skip to content

Matterbridge dynamic platform plugin example

License

Notifications You must be signed in to change notification settings

Luligu/matterbridge-example-dynamic-platform

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

470 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Matterbridge Logo   Matterbridge dynamic platform example plugin

npm version npm downloads Docker Version Docker Pulls Node.js CI CodeQL codecov styled with prettier linted with eslint TypeScript ESM matterbridge.io

powered by powered by powered by powered by


Matterbridge dynamic platform example plugin is a template to develop your own plugin using the dynamic platform.

It exposes 66 virtual devices:

  • a door contact sensor
  • a motion sensor
  • an illuminance sensor
  • a temperature sensor
  • a humidity sensor
  • a pressure sensor
  • a flow sensor
  • a climate sensor with temperature, humidity and pressure
  • a mode select device
  • a switch with onOff cluster
  • a light with onOff
  • a light with onOff and levelControl (dimmer)
  • a light with onOff, levelControl and colorControl (with XY, HS and CT) clusters
  • a light with onOff, levelControl and colorControl (with HS and CT) clusters
  • a light with onOff, levelControl and colorControl (with XY and CT) clusters
  • a light with onOff, levelControl and colorControl (with CT only) clusters
  • an outlet (plug) with onOff cluster
  • an outlet (plug) with onOff cluster, energy measurements and power measurements
  • an outlet (plug) with onOff cluster, apparent energy measurements and power measurements
  • a smart outlet with an energy meter and four individually controllable sockets (with tagList 1, 2, 3 and 4)
  • a bridged outlet with four individually controllable plugs that expose their names
  • a cover with windowCovering cluster and lift feature
  • a cover with windowCovering cluster and both lift and tilt features
  • a lock with doorLock cluster
  • a thermostat auto mode (i.e. with Auto Heat and Cool features) with thermostat cluster and 3 sub endpoints with flowMeasurement cluster, temperatureMeasurement cluster and relativeHumidityMeasurement cluster (to show how to create a composed device with sub endpoints)
  • a thermostat with auto mode (i.e. with Auto Heat and Cool features), occupancy and outdoorTemperature
  • a thermostat auto mode with presets (Home, Away, Sleep, Wake, Vacation and GoingToSleep modes) including 3 sub endpoints with flow, temperature and humidity sensors
  • a thermostat heat only with two external temperature sensors (tagged like Indoor and Outdoor)
  • a thermostat cool only
  • a fan with Off High presets
  • a fan with Off Low Med High presets
  • a fan with Off Low Med High Auto presets and step
  • a fan with all the features MultiSpeed, Auto, Step, Rock, Wind and AirflowDirection and mode Off Low Med High Auto.
  • a rain sensor device
  • a water freeze detector device
  • a water leak detector device
  • a smokeCoAlarm (with smoke and co features) sensor (supported by Apple Home)
  • a smokeCoAlarm (with smoke only feature) sensor (supported by Apple Home)
  • a smokeCoAlarm (with co only feature) sensor (supported by Apple Home)
  • an airConditioner device
  • an airPurifier device with temperature and humidity sensor (supported by Apple Home)
  • a pump device
  • a waterValve device
  • an airQuality device with all concentration measurements clusters (supported by Apple Home with the concentration measurements from version 18.5)
  • a momentary switch composed by three switches with Single Double Long (tagged with One Two Three and Top Middle Bottom) and three switches with Single only.
  • a latching switch
  • a Robot Vacuum Cleaner device (supported by SmartThings, Alexa, Home Assistant and partially by Apple Home). Read also Luligu/matterbridge#264.
  • an onOff Mounted Switch device (supported by SmartThings, Alexa, Home Assistant)
  • a onOff Mounted Switch legacy device (supported by all controllers)
  • a dimmer Mounted Switch device (supported by SmartThings, Alexa, Home Assistant)
  • a dimmer Mounted Switch legacy device (supported by all controllers)
  • a laundry Washer device (supported by SmartThings, Alexa and Home Assistant)
  • a laundry Dryer device (supported by SmartThings, Alexa and Home Assistant)
  • a dishwasher device (supported by SmartThings, Alexa and Home Assistant)
  • a refrigerator device (supported by SmartThings, Alexa and Home Assistant)
  • an oven device (supported by SmartThings, Alexa and Home Assistant)
  • a microwave Oven device (supported by SmartThings, Alexa and Home Assistant)
  • an extractor Hood device (supported by SmartThings, Alexa and Home Assistant)
  • a cooktop device (supported by SmartThings, Alexa and Home Assistant)
  • a water heater device (supported by SmartThings and Home Assistant)
  • a car charger device (supported by Home Assistant)
  • a solar power device
  • a battery storage device
  • a heat pump device
  • a basic video player (supported by SmartThings)
  • a speaker device (supported by SmartThings)

All these devices continuously change their state and position. The plugin also shows how to use all the command handlers (so you can control all the devices), how to subscribe to attributes, and how to trigger events.

If you want to write your own plugin, the easiest way to get started is to clone the Matterbridge Plugin Template. It has Dev Container support for an instant development environment, with all tools and extensions (like Node.js, npm, TypeScript, ESLint, Prettier, Jest, and Vitest) already loaded and configured.

If you like this project and find it useful, please consider giving it a star on GitHub and sponsoring it.

Buy me a coffee

Prerequisites

Matterbridge

See the guidelines on Matterbridge for more information.

Style guide

See also the Style Guide for JSDoc, naming, and logging conventions used in this repository.

About

Matterbridge dynamic platform plugin example

Resources

License

Contributing

Stars

Watchers

Forks

Sponsor this project

Packages

 
 
 

Contributors