remotivelabs-cli 0.0.41__py3-none-any.whl → 0.0.42__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,4 @@
1
1
  import json
2
- import sys
3
2
 
4
3
  from cli.cloud.rest_helper import RestHelper
5
4
  from cli.typer import typer_utils
@@ -9,21 +8,6 @@ app = typer_utils.create_typer()
9
8
 
10
9
  @app.command(name="list", help="List your available organisations")
11
10
  def list_orgs() -> None:
12
- r = RestHelper.handle_get("/api/home", return_response=True)
13
- if r is None:
14
- return
15
- if r.status_code == 200:
16
- j = list(
17
- map(
18
- lambda x: {
19
- "uid": x["billableUnitUser"]["billableUnit"]["uid"],
20
- "displayName": x["billableUnitUser"]["billableUnit"]["displayName"],
21
- },
22
- r.json(),
23
- )
24
- )
25
- print(json.dumps(j))
26
- else:
27
- print(f"Got status code: {r.status_code}")
28
- print(r.text)
29
- sys.exit(1)
11
+ r = RestHelper.handle_get("/api/bu", return_response=True)
12
+ orgs = [{"uid": org["organisation"]["uid"], "displayName": org["organisation"]["displayName"]} for org in r.json()]
13
+ print(json.dumps(orgs))
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: remotivelabs-cli
3
- Version: 0.0.41
3
+ Version: 0.0.42
4
4
  Summary: CLI for operating RemotiveCloud and RemotiveBroker
5
5
  Author: Johan Rask
6
6
  Author-email: johan.rask@remotivelabs.com
@@ -18,7 +18,7 @@ cli/cloud/auth_tokens.py,sha256=xTdL_wHVnOq1hW45XU9iDvQWW7ISDuf5RrDgVilg4-U,1263
18
18
  cli/cloud/brokers.py,sha256=TzUfd2PBfF3vDyTjZ4fMv8ndA4_37IUgOuZHgGHGSEE,3938
19
19
  cli/cloud/cloud_cli.py,sha256=a-LhunHPRPZkxaXQJ0evOYCVXZRYY_qzM6GJG75SjkY,1309
20
20
  cli/cloud/configs.py,sha256=y7uu9IRJjspSpxREvwRNNfx0N1ypstElaqtpt9tepgY,5117
21
- cli/cloud/organisations.py,sha256=BNi4S2em6ruoYUCSuX48zhZS-e31s5u064cBOHGlsgo,785
21
+ cli/cloud/organisations.py,sha256=FJvNjsQFTSqvHs8xWkyVaep1rlYmf1X8Im26Zbxb9iE,432
22
22
  cli/cloud/projects.py,sha256=gXvlaGER3zxBwvjdO3lOa6Fl1xHfQHVCaPdpUNi7G3k,1479
23
23
  cli/cloud/recordings.py,sha256=QrgXJC4csC73Gau-dV_YgL0EZaUzFbc9Nkz_qZHrp70,25067
24
24
  cli/cloud/recordings_playback.py,sha256=dRciL4Oiki6laxRiN8CLiJbsjdjcNpUbv8wxaP91_PA,11614
@@ -47,8 +47,8 @@ cli/tools/can/can.py,sha256=42BwsIOx9NUPkp_rB-0MDqL1tCpeqYVOgWzpixm5ykk,2310
47
47
  cli/tools/tools.py,sha256=jhLfrFDqkmWV3eBAzNwBf6WgDGrz7sOhgVCia36Twn8,232
48
48
  cli/typer/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
49
49
  cli/typer/typer_utils.py,sha256=DmGxdIo0_iK_DYJrZvpFT-tEaQZT1cJtrFR-5VmF_jo,199
50
- remotivelabs_cli-0.0.41.dist-info/LICENSE,sha256=qDPP_yfuv1fF-u7EfexN-cN3M8aFgGVndGhGLovLKz0,608
51
- remotivelabs_cli-0.0.41.dist-info/METADATA,sha256=ozc8TuXervf7Pn8INqOiAethU8U0SWRUXZLpQc6hFw4,1359
52
- remotivelabs_cli-0.0.41.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
53
- remotivelabs_cli-0.0.41.dist-info/entry_points.txt,sha256=lvDhPgagLqW_KTnLPCwKSqfYlEp-1uYVosRiPjsVj10,45
54
- remotivelabs_cli-0.0.41.dist-info/RECORD,,
50
+ remotivelabs_cli-0.0.42.dist-info/LICENSE,sha256=qDPP_yfuv1fF-u7EfexN-cN3M8aFgGVndGhGLovLKz0,608
51
+ remotivelabs_cli-0.0.42.dist-info/METADATA,sha256=gIn4oB_y8v29-ytAQXcHvfdUfGP-E04atfh8GHphRRA,1359
52
+ remotivelabs_cli-0.0.42.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
53
+ remotivelabs_cli-0.0.42.dist-info/entry_points.txt,sha256=lvDhPgagLqW_KTnLPCwKSqfYlEp-1uYVosRiPjsVj10,45
54
+ remotivelabs_cli-0.0.42.dist-info/RECORD,,