Commit Graph

16 Commits

Author SHA1 Message Date
Harald Welte 919ac1b689 add initial README.md 2023-06-05 13:16:41 +02:00
Harald Welte 69fca4c877 add COPYING + GPL notice to all files that were missing it 2023-06-05 10:40:15 +02:00
Harald Welte c9ae2b0825 apitool: Move ApiClient class to osmocom.lpmgd.client module
This way other code can easily import the API client
2023-06-05 10:37:03 +02:00
Harald Welte 72d6ae6603 apitool: Properly encapsulate HTTP errors in an Exception
... don't just print to stdout from within the API client
2023-06-05 10:36:52 +02:00
Harald Welte da194235fc apitool: Print non-success status codes to console on API error 2023-06-05 10:18:48 +02:00
Harald Welte fb1b88f5af add GET of individual token or list of all tokens of resource 2023-06-05 10:17:27 +02:00
Harald Welte 11ffb5ca95 add REST + apitool support for listing all resources 2023-06-05 10:05:54 +02:00
Harald Welte 425f84f552 rest_server: fix token release
resource.usage_token_put() works on the Token instance, and not
the uuid string.  So we first need to look-up the Token instance
for the client-provided UUID string, and then we can call
usage_token_put()
2023-06-04 20:40:22 +02:00
Harald Welte 6544151ff9 model: Change resource.usage_tokens from list to dict
this way we can have efficient look-ups by token UUID
2023-06-04 20:39:56 +02:00
Harald Welte 1b0ae2814b apitool: fix token-release 2023-06-04 20:39:34 +02:00
Harald Welte 8893527121 UsageToken: fix to_dict() method; return only json-serializable objects
after this commit, the get-usage-token operation via the REST interface
actually works and returns a valid JSON response body
2023-06-04 20:16:27 +02:00
Harald Welte d1ec16e679 model: Fix _validate_status and update_status methods 2023-06-04 20:08:29 +02:00
Harald Welte b3c507af2f add osmo-lpmgd-apitool for command-line usage of the REST API 2023-06-04 20:05:37 +02:00
Harald Welte 3d2692656a directory re-organization: lib as osmocom.lpmgd module 2023-06-04 13:19:48 +02:00
Harald Welte b91c00d034 WIP: import sispm + intellinet switcher from osmo-gsm-tester 2023-05-07 12:29:56 +10:00
Harald Welte af0449d9e0 initial checkin of a test lab power management daemon 2023-05-05 21:43:25 +10:00