2025-09-21 19:23:50 +03:00

20 lines
447 B
Python

import asyncio
import argparse
from enclave_shelly import ShellyBase
async def main():
parser = argparse.ArgumentParser(description="Queries the status of a Shelly device.")
parser.add_argument("url", type=str, help="The IP or hostname of the Shelly device.")
args = parser.parse_args()
shelly = ShellyBase(args.url)
status = await shelly.reboot(200)
print(status)
if __name__ == "__main__":
asyncio.run(main())