Solved! I had to take the two lines on the right in the picture together and that was my code!
Together with this code in the configuration.yaml I was able to integrate the socket:
switch:
- platform: xiaomi_miio
name: Original Xiaomi Mi Smart WiFi Socket
host: [ip of my socket]
token: 10dc640977af575fd1c091ed44b77999
model: chuangmi.plug.m1
Do you know of another website that can change this long code into the 32 digit one, http://aes.online-domain-tools.com/ isn’t working, there is an error on the page?
I’m learning to set up a few Xiaomi devices especially this wifi socket. I’ve already added the Xiaomi Gateway by looking up the API token using the Mi Home app way.