node-red-contrib-home-assistant-websocket
Version:
Node-RED integration with Home Assistant through websocket and REST API
2 lines (1 loc) • 4.18 kB
JavaScript
;var h=Object.defineProperty;var R=Object.getOwnPropertyDescriptor;var G=Object.getOwnPropertyNames;var b=Object.prototype.hasOwnProperty;var m=(a,e)=>{for(var _ in e)h(a,_,{get:e[_],enumerable:!0})},N=(a,e,_,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of G(e))!b.call(a,r)&&r!==_&&h(a,r,{get:()=>e[r],enumerable:!(i=R(e,r))||i.enumerable});return a};var f=a=>N(h({},"__esModule",{value:!0}),a);var K={};m(K,{ComparatorType:()=>g,DeviceCapabilityType:()=>x,EntityFilterType:()=>E,EntityStateCastType:()=>D,EntityType:()=>S,HA_EVENTS:()=>P,HA_EVENT_INTEGRATION:()=>L,HA_EVENT_SERVICES_UPDATED:()=>I,HA_MIN_VERSION:()=>w,INTEGRATION_EVENT:()=>B,INTEGRATION_LOADED:()=>H,INTEGRATION_NOT_LOADED:()=>V,INTEGRATION_UNLOADED:()=>j,NO_VERSION:()=>J,NodeType:()=>A,PRINT_TO_DEBUG_TOPIC:()=>Z,SERVER_ADD:()=>U,STATE_CONNECTED:()=>k,STATE_CONNECTING:()=>W,STATE_DISCONNECTED:()=>q,STATE_ERROR:()=>z,STATE_RUNNING:()=>M,TAGS_ALL:()=>F,TimeUnit:()=>O,TypedInputTypes:()=>v,ValueIntegrationMode:()=>u});module.exports=f(K);const I="services_updated",L="nodered",P="ha_events",w="2023.12",B="integration",H="loaded",V="notloaded",j="unloaded",J="0.0.0",W=0,k=1,q=2,z=3,M=4,U="_ADD_",Z="home-assistant-print-to-debug",F="__ALL_TAGS__";var g=(s=>(s.Is="is",s.IsNot="is_not",s.IsLessThan="lt",s.IsLessThanOrEqual="lte",s.IsGreaterThan="gt",s.IsGreaterThanOrEqual="gte",s.Includes="includes",s.DoesNotInclude="does_not_include",s.Contains="cont",s.DoesNotContain="does_not_cont",s.StartsWith="starts_with",s.InGroup="in_group",s.JSONata="jsonata",s.IsNull="is_null",s.IsNotNull="is_not_null",s.IsTrue="is_true",s.IsFalse="is_false",s.Regex="regex",s))(g||{}),x=(l=>(l.Boolean="boolean",l.Float="float",l.Integer="integer",l.PositiveTimePeriod="positive_time_period_dict",l.Select="select",l.String="string",l))(x||{}),S=(o=>(o.BinarySensor="binary_sensor",o.Button="button",o.Number="number",o.Select="select",o.Sensor="sensor",o.Switch="switch",o.Text="text",o.Time="time",o))(S||{}),E=(r=>(r.Exact="exact",r.List="list",r.Regex="regex",r.Substring="substring",r))(E||{}),A=(t=>(t.Action="api-call-service",t.API="ha-api",t.CurrentState="api-current-state",t.Device="ha-device",t.Entity="ha-entity",t.EventsAll="server-events",t.EventsCalendar="ha-events-calendar",t.EventsState="server-state-changed",t.FireEvent="ha-fire-event",t.GetEntities="ha-get-entities",t.GetHistory="api-get-history",t.PollState="poll-state",t.RenderTemplate="api-render-template",t.Select="ha-select",t.Sentence="ha-sentence",t.TriggerState="trigger-state",t.Tag="ha-tag",t.Time="ha-time",t.WaitUntil="ha-wait-until",t.Webhook="ha-webhook",t.Zone="ha-zone",t.Server="server",t.DeviceConfig="ha-device-config",t.EntityConfig="ha-entity-config",t.BinarySensor="ha-binary-sensor",t.Button="ha-button",t.Number="ha-number",t.Sensor="ha-sensor",t.Switch="ha-switch",t.Text="ha-text",t.TimeEntity="ha-time-entity",t.UpdateConfig="ha-update-config",t))(A||{}),u=(i=>(i.Get="get",i.Set="set",i.Listen="listen",i))(u||{}),v=(n=>(n.Message="msg",n.Flow="flow",n.Global="global",n.Boolean="bool",n.JSON="json",n.Date="date",n.JSONata="jsonata",n.Number="num",n.String="str",n.None="none",n.Config="config",n.Data="data",n.Entity="entity",n.EntityState="entityState",n.EventData="eventData",n.Headers="headers",n.Params="params",n.TriggerId="triggerId",n.PrevEntity="prevEntity",n.Results="results",n.Regex="re",n.Value="value",n.PreviousValue="previousValue",n.CalendarItem="calendarItem",n.DeviceId="deviceId",n.Enviroment="env",n))(v||{}),O=(c=>(c.Milliseconds="milliseconds",c.Seconds="seconds",c.Minutes="minutes",c.Hours="hours",c.Days="days",c))(O||{}),D=(r=>(r.String="string",r.Number="number",r.Boolean="boolean",r.HA_Boolean="ha_boolean",r))(D||{});0&&(module.exports={ComparatorType,DeviceCapabilityType,EntityFilterType,EntityStateCastType,EntityType,HA_EVENTS,HA_EVENT_INTEGRATION,HA_EVENT_SERVICES_UPDATED,HA_MIN_VERSION,INTEGRATION_EVENT,INTEGRATION_LOADED,INTEGRATION_NOT_LOADED,INTEGRATION_UNLOADED,NO_VERSION,NodeType,PRINT_TO_DEBUG_TOPIC,SERVER_ADD,STATE_CONNECTED,STATE_CONNECTING,STATE_DISCONNECTED,STATE_ERROR,STATE_RUNNING,TAGS_ALL,TimeUnit,TypedInputTypes,ValueIntegrationMode});