स्क्रिप्ट

ब्यौरा

टॉप लेवल स्क्रिप्ट.

फ़ील्ड

सुरक्षा कुंजी टाइप ब्यौरा
metadata मेटाडेटा

स्क्रिप्ट का मेटाडेटा उपलब्ध कराता है, जैसे कि नाम और ब्यौरा.

ज़रूरी है

automations [ऑटोमेशन]

यह ऑटोमेशन की सूची के बारे में बताता है.

ज़रूरी है

उदाहरण

एक स्विच की मदद से लाइट को कंट्रोल करने की आसान स्क्रिप्ट

metadata:
  name: Turn on light with switch
  description: Basic example of turning on a light with another switch.

automations:
  starters:
    type: device.state.OnOff
    device: Office Switch - Office
    state: on
    is: true
  actions:
  - type: device.command.OnOff
    devices:
    - Christmas lights - Living Room
    on: true