v14.5.0 (DEPRECATED)
pip install balena-sdkhttps://github.com/balena-io/balena-sdk-python>>> from balena import Balena
>>> balena = Balena()
>>> credentials = {'username':<your email>, 'password':<your password>}
>>> balena.auth.login(**credentials)
...balena = Balena({
"balena_host": "balena-cloud.com",
"api_version": "v6",
"device_actions_endpoint_version": "v1",
"data_directory": "/home/example/.balena",
"image_cache_time": str(1 * 1000 * 60 * 60 * 24 * 7), # 1 week
"token_refresh_interval": str(1 * 1000 * 60 * 60), # 1 hour
"timeout": str(30 * 1000), # request timeout, 30s
"request_limit": str(300), # the number of requests per request_limit_interval that the SDK should respect, defaults to unlimited.
"request_limit_interval": str(60), # the timespan that the request_limit should apply to in seconds, defaults to 60s (1 minute).
"retry_rate_limited_request": False, # awaits and retry once a request is rate limited (429)
})