स्मार्ट होम नल की गाइड
action.devices.types.FAUCET
- नलों में तरल पदार्थ, अलग-अलग मात्रा, और प्रीसेट से दिए जा सकते हैं. नल में अलग-अलग मोड हो सकते हैं और हर मोड की उससे जुड़ी सेटिंग होती हैं. ये नल के हिसाब से होते हैं और इन्हें सामान्य तौर पर समझाया जाता है.
इस टाइप से पता चलता है कि डिवाइस को फ़ॉसेट आइकॉन और कुछ मिलते-जुलते समानार्थी शब्द और उपनाम मिले हैं.
डिवाइस की काबिलियत
लागू करने से जुड़ी जानकारी के लिए, उससे जुड़े एट्रिब्यूट देखें. जैसे, एट्रिब्यूट और स्थितियां, जिन्हें आपकी सेवा को इस्तेमाल करने की अनुमति देनी चाहिए. साथ ही, EXECUTE और QUERY रिस्पॉन्स बनाने का तरीका भी बताएं.
सुझाए गए लक्षण
अगर ये विशेषताएं आपके डिवाइस पर लागू होती हैं, तो उनका सुझाव दिया जाता है. हालांकि, आपके पास प्रॉडक्ट की सभी उपलब्ध सुविधाओं को मिलाने और उनसे मिलान करने का विकल्प है. हालांकि, इसके लिए ज़रूरी है कि वे आपकी मौजूदा प्रॉडक्ट सुविधाओं से पूरी तरह मेल खाते हों.
-
action.devices.traits.Dispense
-
action.devices.traits.StartStop
-
action.devices.traits.TemperatureControl
क्वालिटी के लिए ज़रूरी शर्तें
- इंतज़ार का समय: 800 मि॰से॰ से कम या उसके बराबर होना चाहिए.
- विश्वसनीयता: 97% से ज़्यादा या उसके बराबर होना चाहिए.
डिवाइस का उदाहरण: आसान नल
इस सेक्शन में, ऊपर दिए गए डिवाइस टाइप और विशेषताओं के आधार पर, एक सामान्य "फ़ॉसेट" के इंटेंट पेलोड के उदाहरण दिए गए हैं. लागू किए गए हिस्सों में विशेषताएं जोड़ें या हटाएं. इसके बाद, उन बदलावों को दिखाने के लिए अपने जवाबों में ज़रूरत के मुताबिक बदलाव करें.
SYNC जवाब का नमूना
{ "requestId": "6894439706274654512", "inputs": [ { "intent": "action.devices.SYNC" } ] }
{ "requestId": "6894439706274654512", "payload": { "agentUserId": "user123", "devices": [ { "id": "123", "type": "action.devices.types.FAUCET", "traits": [ "action.devices.traits.Dispense", "action.devices.traits.TemperatureControl", "action.devices.traits.OnOff" ], "name": { "name": "Simple faucet" }, "willReportState": true, "attributes": { "supportedDispenseItems": [ { "item_name": "water_key", "item_name_synonyms": [ { "lang": "en", "synonyms": [ "Water" ] }, { "lang": "es", "synonyms": [ "Agua" ] }, { "lang": "fr", "synonyms": [ "Eau" ] } ], "supported_units": [ "TEASPOONS", "TABLESPOONS", "FLUID_OUNCES", "CUPS", "PINTS", "QUARTS", "GALLONS", "MILLILITERS", "LITERS", "DECILITERS" ], "default_portion": { "amount": 2, "unit": "CUPS" } } ], "supportedDispensePresets": [ { "preset_name": "cat_water_bowl_key", "preset_name_synonyms": [ { "lang": "en", "synonyms": [ "Cat water bowl", "Cat water dish", "Cat water cup" ] }, { "lang": "es", "synonyms": [ "Plato de agua para gato", "Bebedero para gato" ] }, { "lang": "fr", "synonyms": [ "Bol d'eau de chat", "Bac \u00e0 eau pour chat", "Tasse d'eau de chat" ] } ] } ], "temperatureRange": { "minThresholdCelsius": 25, "maxThresholdCelsius": 100 }, "temperatureUnitForUX": "F" }, "deviceInfo": { "manufacturer": "smart-home-inc", "model": "hs1234", "hwVersion": "3.2", "swVersion": "11.4" } } ] } }
नमूना QUERY प्रतिसाद
{ "requestId": "6894439706274654514", "inputs": [ { "intent": "action.devices.QUERY", "payload": { "devices": [ { "id": "123" } ] } } ] }
{ "requestId": "6894439706274654514", "payload": { "devices": { "123": { "status": "SUCCESS", "online": true, "on": false, "temperatureSetpointCelsius": 30, "dispenseItems": [ { "itemName": "water_key", "amountLastDispensed": { "amount": 2.5, "unit": "CUPS" }, "isCurrentlyDispensing": false } ] } } } }
EXECUTE कमांड का नमूना
डिस्पेंस
कमांड पैरामीटर के बारे में ज़्यादा जानने के लिए,
action.devices.traits.Dispense
रेफ़रंस देखें.
{ "requestId": "6894439706274654516", "inputs": [ { "intent": "action.devices.EXECUTE", "payload": { "commands": [ { "devices": [ { "id": "123" } ], "execution": [ { "command": "action.devices.commands.Dispense", "params": { "amount": 1, "unit": "CUPS", "item": "water_key" } } ] } ] } } ] }
{ "requestId": "6894439706274654516", "payload": { "commands": [ { "ids": [ "123" ], "status": "SUCCESS", "states": { "online": true, "dispenseItems": [ { "itemName": "water_key", "amountLastDispensed": { "amount": 1, "unit": "CUPS" }, "isCurrentlyDispensing": true } ] } } ] } }
तापमान सेट करना
कमांड पैरामीटर के बारे में ज़्यादा जानने के लिए,
action.devices.traits.TemperatureControl
रेफ़रंस देखें.
{ "requestId": "6894439706274654518", "inputs": [ { "intent": "action.devices.EXECUTE", "payload": { "commands": [ { "devices": [ { "id": "123" } ], "execution": [ { "command": "action.devices.commands.SetTemperature", "params": { "temperature": 65 } } ] } ] } } ] }
{ "requestId": "6894439706274654518", "payload": { "commands": [ { "ids": [ "123" ], "status": "SUCCESS", "states": { "online": true, "temperatureSetpointCelsius": 65 } } ] } }
बंद है
कमांड पैरामीटर के बारे में ज़्यादा जानने के लिए,
action.devices.traits.OnOff
रेफ़रंस देखें.
{ "requestId": "6894439706274654520", "inputs": [ { "intent": "action.devices.EXECUTE", "payload": { "commands": [ { "devices": [ { "id": "123" } ], "execution": [ { "command": "action.devices.commands.OnOff", "params": { "on": true } } ] } ] } } ] }
{ "requestId": "6894439706274654520", "payload": { "commands": [ { "ids": [ "123" ], "status": "SUCCESS", "states": { "online": true, "on": true } } ] } }