I have a dot and i use it, but not my girlfriend:)
But i think Home-assistant is made for a fully automatic home control.
So I see all the suggestions here of a semi-automatation order as Pointless:)
And again: This is just one example. Open your horizon and you will recognize some other areas of application.
I think we should focus here on the actual topic. Whether I switch on the light with a switch , Echo or handstand, does not matter:)
My view of automation is based entirely on what is practical vs what is superfluous, always favoring practicality. That said …
… I totally agree with you! I love seeing others’ ideas here in the forum because it opens up the possibility of modifying or reusing the concept in another way. For example, your use of a sensor in the box to automagically order more washing power gave me the idea of having a humidity sensor in my plants’ potting. I am notoriously bad at remember to water my plants and this could give way to alert or notify me to do so!
To be back on topic, it seems like utilizing the Amazon API here is the best route to go as it is essentially what the Dash button does anyway. “Amazon’s Dash Replenishment Service (DRS) enables connected devices to order physical goods from Amazon when supplies are running low—like a Brita Water Pitcher that orders more filters. By using Amazon Dash Replenishment, device makers are able to leverage Amazon’s authentication and payment systems, customer service, and fulfillment network—giving their customers access to Amazon’s low prices, great selection, and reliable delivery.”I would start here.
The HASS portion of this is actually very simple (it could actually be entirely removed from HASS, if desired) as it will end up being essentially…
Presentation of data in HASS dashboard
Sensor in washing power packaging
MQTT publishing of sensor values
HASS reporting data from sensor state/attribute
Automation rule to order more powder
Monitor state/attribute for “less than a specific value” or “within value range”
This is basically what I was saying; the integration into HA will be trivial; the real trick is figuring out not only what is sent via POST on ALL requests, but in fact what is UNIQUELY sent for each product. I’m hoping for @Blueforcer’s sake that they use UPC codes and not some kind of internal partner code as this would be hard to get without the physical Dash button output being captured.
Since there are a few published methods for capturing the output, perhaps you can get a kind user to capture output for you.
[quote=“rpitera, post:23, topic:9343”]
the real trick is figuring out not only what is sent via POST on ALL requests, but in fact what is UNIQUELY sent for each product.[/quote]
Yes, my point is exactly that. They are mass produced http: POST widgets. They are identical from a hardware standpoint.
But the device sending orders for diapers is sending a different POST than the one sending orders for washing powder. THAT IS THE KEY. Finding THAT code. The basic post request is well documented. The code to determine one product from another is not.
The DRS Self-Service Portal will help you create and manage your DRS-connected devices. The device wizard simplifies the provisioning process for DRS and will guide you through creating your device model(s) and configuring your product ASIN lists so that you can begin testing and integrating with Amazon Dash Replenishment Service. Click here to get started.
The portal you are linking to is for VENDORS. Not customers setting up there own dash buttons.
Customers set up their dash buttons using the Amazon app. A single button can purchase one of a LIST of products, so a Tide button can buy ONE of 13 different products. Once the customer sets up the product in the app, every time that button is pressed, that particular product is ordered.
So you have to know whether a particular ASIN is being sent or are they using UPC? How is the POST request constructed from the CLIENT side.
I’m just here to find out when the official Home Assistant Handstand API will be ready for launch.
@Blueforcer - I know the functionality you are trying to replicate is that which is done by dash buttons, but I would suggest that by focusing on these buttons, maybe we are making it more difficult than it needs to be…
Amazon already has an entire back-end server set up to receive HTTP requests, process them, and generate orders programmatically - its website.
Wouldn’t a web crawling script be more appropriate here? Something that uses a scraper to log into amazon and make a purchase on your behalf?
It would be great if this funktion comes in Home Assistant or an developer could realize this. For one example we can implement automatic shoping funktions if a Automation was triggerd for one example we have many Sensors with batteries an it would be great, if we have an funktion that if an treshhold of Batteries is reached in the Stock of Batteries the Home Assistant orders new batteries over Amazon. My Idea is, that you can select battery based devices (groupwise for diffent typs Batteries) and if one of this devices changed from eg. 20% to 100% it indicates an Battery change, then it must count down an defined count of battery from the stock of Batteries. For an better understanding for me it’s nearly the same like the Tab counter witch is realyzed in Home Connect from BSH for Dishwashers. One different thing it must be possible to select diffent typs in group of devices with diffent battery typs (like AA or AAA or CR123 etc.)