Today, I put together a Python module to access Spark devices through the cloud API.
I though it could also help some people out, so I published it: https://github.com/Alidron/spyrk
It’s not yet supporting all functionalities. But at least I got what I needed for the moment: easy programmable access to my cores without having to deal constantly with curl, the access token or the device ids .
Also, I don’t know why, but the GET calls to retrieve the list of devices, functions and variables are super slow right now?! It takes a few seconds for the module to initialize.
(Thanks to this topic for the initial idea: https://community.spark.io/t/unable-to-talk-to-tinker-firmware-w-python-via-rest/2072)