requests wrapper covers almost every use case. Copy the class below into your project.
Install
Client
aria_compute.py
Usage
For the China site pass
base_url="https://ariacompute.cn/api". Accounts, wallets, and keys are region-scoped: a key issued on .com does not work on .cn.Retries and timeouts
The backend returns standard HTTP status codes. Wrap calls inrequests.adapters.HTTPAdapter with urllib3.util.Retry to retry transient 5xx and 429 responses, and always set a timeout: