I followed the example below and connected the MKR WiFi 1010 with the MKR ENV Shield on top of it to the Arduino cloud. After the update of the firmware of the MKR WiFi 1010 it worked just fine.
The problem with this example is, that it only works, if the MKR WiFi 1010 is connected to the computer by USB cable.
Does anybody have an easy example, how to connect the MKR WiFi 1010 to the Arduino cloud, so that it does not need to be permanently connected to the computer and can run for example on a battery?