Miele@home, miele@mobile component

Hello, this is great, and I want to test it out, will it cause trouble to have both this and the “Old integration” installed at the same time?

Recommended order of actions:

  1. Remove old Miele integration
  2. Add astrandb/miele as custom repository in HACS
  3. Install new Miele integration from HACS
  4. Restart HA
  5. Add Miele integration

Does the /devices/{deviceid}/programs endpoint actually work for you on Swagger? Both my dishwasher (6000 series, recent-ish) and my washer-dryer (latest model) only return an empty list (i.e. []). Do you mind telling us what device your dishwasher is?

In principle, if it works in Swagger, it should work with the HA service, but I haven’t tried starting programs myself via the service (I don’t have a use case since I’d have to physically set my device to “remote control” first, which defeats the purpose), but maybe @astrandb can offer some more insight what could be the problem here?

From the logs above I can see that @kepler is using the “old” integration for Miele. I have no further input to what is going on inside that integration.

You are absolutely right, my apologies. Something went wrong with switching to your integration, but now I got your integration working. Looking good so far!
The dishwasher is running at the moment, so cannot test sending a program.

@mundschenk-at
I need to turn on mobile start, but that remains on almost forever. It also stays activated after washing cycles, so my plan is to be able to select a program and set a timer (and receive warning if mobile start is not on) via home Assistant.

How does it takes Miele to send the mail from the developers website. I register at https://www.miele.com/f/com/en/register_api.aspx and after giving an name “Miele” and my prived e-mail address stil waiting for a answer mail… and yes I check my spamfolder.

This is the place to create your access token

https://www.miele.com/developer/swagger-ui/swagger.html

Oke but still you have to register and then you go to the same URL (https://www.miele.com/f/com/en/register_api.aspx) because I think you need a developer account. And i only have an miele@home account for the app and the website.

It works. had to wait for 6 hours.

Is it posible to start the machine with smartstart? So you can start the thumble dryer when the solar panels deliver enough power.

What’s your dishwasher model? And do you get a real result for the /programs endpoint with Swagger? Because those logs from the old integration suggest that it also gets an empty list.

It should be possible to make such an automation in Home Assistant. For inspiration you can look at another approach at IngmarStein/mielesolar: Trigger Miele SmartStart with SolarEdge inverters (github.com)

I have the Miele G7465 and sending a program works via the swagger. The dishwasher will also start this program directly.

I was in contact with the guys from the Miele API, because I thought I had to start the dishwasher with processAction. But apparently you can start it with sending a program id.

I didn’t get it to work yet in home Assistant, but need to play around a little bit with the service call. I will keep you updated

Thanks! Would it be possible for you to post the result of the /devices/<yourdevice>/programs endpoint from the swagger UI?

Has anyone been able to integrate a power toggle switch in to HA? After installing the latest integration from Ake I don’t see the power switch entity amongst the other device entities. I also added the Alexa skill to my Alexa app in the hope to expose the power switch, but while I can power on my washing machine and tumble dryer from the Alexa app, still I didn’t find a way to implement that in HA.

Thank you for for pointing at this issue. There is currently no representation of powerOn/powerOff in the integration. The reason is that my own appliances don’t support these functions and the feature therefore fell below the priority threshold.There should not be any major problem to add it. I add it as an issue on Issues · astrandb/miele (github.com) where you can monitor the progress.

1 Like

Almost read through the entire post but still can’t find a solution. I followed the steps and get stucked at the link account page. It keeps saying my crediential is wrong no matter how I changed the password of my Miele@home account. And yes I received and filled in the client ID & secret from the developer page.

Please kindly help. Thanks!

You can try the Authorize button here Miele 3rd party API - API documentation to verify your client_id, client_secret, and account details.

It’s working ealier on this page. But doesn’t work anymore after I applied for a new set of keys.

Below is the response:

[
  {
    "programId": 3,
    "program": "ECO",
    "parameters": {}
  },
  {
    "programId": 6,
    "program": "Auto",
    "parameters": {}
  },
  {
    "programId": 10,
    "program": "Gentle",
    "parameters": {}
  },
  {
    "programId": 13,
    "program": "QuickPowerWash",
    "parameters": {}
  },
  {
    "programId": 1,
    "program": "Intensive",
    "parameters": {}
  },
  {
    "programId": 44,
    "program": "Glasses warm",
    "parameters": {}
  },
  {
    "programId": 11,
    "program": "ExtraQuiet",
    "parameters": {}
  },
  {
    "programId": 9,
    "program": "SolarSave",
    "parameters": {}
  },
  {
    "programId": 12,
    "program": "Hygiene",
    "parameters": {}
  },
  {
    "programId": 2,
    "program": "Maintenance programme",
    "parameters": {}
  }
]

But when I try to run the service I get an error:

Deze fout is ontstaan door een aangepaste integratie.

Logger: homeassistant.helpers.script.websocket_api_script
Source: custom_components/miele/services.py:99
Integration: Miele (documentation, issues)
First occurred: 7 maart 2022 14:06:51 (12 occurrences)
Last logged: 20:12:34

websocket_api script: Error executing script. Unexpected error for call_service at pos 1: 'module' object is not callable
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 367, in _async_step
    await getattr(self, handler)()
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 570, in _async_call_service_step
    await service_task
  File "/usr/src/homeassistant/homeassistant/core.py", line 1636, in async_call
    task.result()
  File "/usr/src/homeassistant/homeassistant/core.py", line 1673, in _execute_service
    await cast(Callable[[ServiceCall], Awaitable[None]], handler.job.target)(
  File "/config/custom_components/miele/services.py", line 99, in send_generic_action
    data = copy(call.data)
TypeError: 'module' object is not callable

Perhaps I use the wrong formatting or something? I tried a lot of different formats, but nothing worked via Home Assistant: