-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add template management #3
Comments
Hello! Are you referring to Room Templates on ASP Console? |
Thanks for your answer. That is something that should be on the roadmap. Setting up a property with 100+ rooms requires to select every single room and apply the template by hand. To automate this process and set up a property fully automated we really need this functionality on the API. |
While there's no support to use room templates with API directly, you can use API to do the same things that you can do with room templates. For example, rather an an API to apply room template to setup skills and and settings for rooms, use https://developer.amazon.com/en-US/docs/alexa/alexa-smart-properties/endpoint-settings-api.html and https://developer.amazon.com/en-US/docs/alexa/alexa-smart-properties/skill-management-api.html directly. We have also recently made bulk API calls easier with the introduction of ASP CLI. With the CLI you can use the update-property from cache which will hit every endpoint or unit with the setting. For units it will use the bulk operation if available. Example: Please take a look and let me know what you think. Thanks! |
You are right, I can configure a room with the above calls. But only to a limited degree. Templates let you predefine all device settings (language, wakeword, distance unit,...) without any device in present in the room. Having done that, all associated devices in the future will have these (pre-configured) settings. Otherwise i need to do the settings for every single device after association. Thats a big source for error. If i move devices from room to room or replace a stolen device i need to be really careful. Templates are a really good solution here. The ASP CLI cant help here as well, it lacks the same problem: the device needs to be present in the room. |
That's a good feedback. Thanks. I'm thinking one way we may be able to improve on this without needing to change the API is to have a new macro action in the CLI that can associate device to unit and also apply settings at the same time. That way the client wouldn't have to remember to do both. |
Thanks for your feedback! The macro action will have one issue as well: Settings can only applied while the device is online. So in some corner cases the device might not be online and pushing the settings will fail. Then you need to build a workflow to recover once the device is online again (which might be a while). Template usage never has that issue. To be honest: I am not a big fan of the CLI approach. We have build everything on NodeJS and call the endpoints our self. This gives us super flexibility to build custom workflows no one thought of. And thats why we are asking for more API access. |
Understood. I just want to set expectation that an API change would be a bigger ask and support for room template is unlikely going to be available in 2024. |
I would like to manage the templates via API as well.
For instance add the
v1/templates?ownerId={{unitId}}
endpoints to query existing templates.The text was updated successfully, but these errors were encountered: