meshagent-cli 0.0.17__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.

Potentially problematic release.


This version of meshagent-cli might be problematic. Click here for more details.

@@ -0,0 +1 @@
1
+ __version__ = "0.0.17"
@@ -0,0 +1,89 @@
1
+ from meshagent.cli import async_typer
2
+ import typer
3
+ from meshagent.cli.helper import get_client, print_json_table, resolve_project_id
4
+ from rich import print
5
+ import json
6
+ from typing import Annotated, List, Optional
7
+
8
+ app = async_typer.AsyncTyper()
9
+
10
+ # ---------------------------------------------------------------------------
11
+ # Webhook commands
12
+ # ---------------------------------------------------------------------------
13
+
14
+ @app.async_command("create")
15
+ async def webhook_create(
16
+ *,
17
+ project_id: str = None,
18
+ name: Annotated[str, typer.Option(help="Friendly name for the webhook")],
19
+ url: Annotated[str, typer.Option(help="Target URL that will receive POSTs")],
20
+ event: Annotated[
21
+ List[str],
22
+ typer.Option(
23
+ "-e",
24
+ "--event",
25
+ help="Event to subscribe to (repeat for multiple)."
26
+ ),
27
+ ],
28
+ description: Annotated[str, typer.Option(default="", help="Optional description")] = "",
29
+ action: Annotated[
30
+ Optional[str],
31
+ typer.Option("--action", help="Optional action name delivered with each call"),
32
+ ] = None,
33
+ payload: Annotated[
34
+ Optional[str],
35
+ typer.Option(
36
+ "--payload",
37
+ help="Optional JSON string sent as the body (merged with event payload).",
38
+ ),
39
+ ] = None,
40
+ ):
41
+ """Create a new project webhook."""
42
+ client = await get_client()
43
+ try:
44
+ project_id = await resolve_project_id(project_id=project_id)
45
+
46
+ payload_obj = json.loads(payload) if payload else None
47
+ webhook = await client.create_project_webhook(
48
+ project_id=project_id,
49
+ name=name,
50
+ url=url,
51
+ events=event,
52
+ description=description,
53
+ action=action,
54
+ payload=payload_obj,
55
+ )
56
+ print_json_table([webhook])
57
+ finally:
58
+ await client.close()
59
+
60
+
61
+ @app.async_command("list")
62
+ async def webhook_list(
63
+ *,
64
+ project_id: str = None,
65
+ ):
66
+ """List all webhooks for the project."""
67
+ client = await get_client()
68
+ try:
69
+ project_id = await resolve_project_id(project_id=project_id)
70
+ hooks = await client.list_project_webhooks(project_id)
71
+ print_json_table(hooks.get("webhooks"), "id","name","description","url","events","action")
72
+ finally:
73
+ await client.close()
74
+
75
+
76
+ @app.async_command("delete")
77
+ async def webhook_delete(
78
+ *,
79
+ project_id: str = None,
80
+ webhook_id: Annotated[str, typer.Argument(help="ID of the webhook to delete")],
81
+ ):
82
+ """Delete a project webhook."""
83
+ client = await get_client()
84
+ try:
85
+ project_id = await resolve_project_id(project_id=project_id)
86
+ await client.delete_project_webhook(project_id, webhook_id)
87
+ print(f"[green]Webhook {webhook_id} deleted.[/]")
88
+ finally:
89
+ await client.close()
@@ -0,0 +1,23 @@
1
+ Metadata-Version: 2.4
2
+ Name: meshagent-cli
3
+ Version: 0.0.17
4
+ Summary: CLI for Meshagent
5
+ License-Expression: LicenseRef-Proprietary
6
+ Project-URL: Documentation, https://meshagent.com
7
+ Project-URL: Website, https://meshagent.com
8
+ Project-URL: Source, https://github.com/meshagent
9
+ Requires-Python: >=3.9.0
10
+ Description-Content-Type: text/markdown
11
+ Requires-Dist: typer~=0.15.3
12
+ Requires-Dist: pydantic-yaml~=1.4.0
13
+ Requires-Dist: meshagent-api~=0.0.17
14
+ Requires-Dist: meshagent-agents~=0.0.17
15
+ Requires-Dist: meshagent-tools~=0.0.17
16
+
17
+ ### Meshagent CLI
18
+
19
+
20
+
21
+
22
+
23
+
@@ -0,0 +1,25 @@
1
+ meshagent/cli/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
+ meshagent/cli/agent.py,sha256=k72cis_1-1BWKJxq-EmmulEsd47Uto3TPS7l0mthwws,10419
3
+ meshagent/cli/api_keys.py,sha256=TRh52-xwPPcMTE_PvdUEqXvBREGkrNfzXBJhXqu4DRU,2421
4
+ meshagent/cli/async_typer.py,sha256=GCeSefBDbpd-V4V8LrvHGUTBMth3HspVMfFa-HUZ0cg,898
5
+ meshagent/cli/auth.py,sha256=SoxExZxRDHTSPOrIGtO3w0GNO42ljK7xLhGRthxKQXA,821
6
+ meshagent/cli/auth_async.py,sha256=f2cMq1DyTpb7l-q5RbDCa_Mc86Ft7kmBJwdTukrXkcc,4001
7
+ meshagent/cli/call.py,sha256=R48ekgAK6X_yqIpSuOZG0y1eXEDNqxyLgGDJWo0RH_Q,4610
8
+ meshagent/cli/cli.py,sha256=y1zXBLeb1xFDgAh9SwwpjBaOdNQe1gJO6Kdmgm5-gO4,1181
9
+ meshagent/cli/cli_mcp.py,sha256=QQYIu4HUrtFuXh5UqA2tTZHldgoY_0IT_wwe21TnYqg,5061
10
+ meshagent/cli/cli_secrets.py,sha256=ir3Qq5XtnuQUJLObCvmUCIMBJ7PvY8Rpct7h9pJsoig,13629
11
+ meshagent/cli/developer.py,sha256=9DlJ5P6sWChYHEHReICtr_4BC3kdplX8BdSmYrC8Xf4,3002
12
+ meshagent/cli/helper.py,sha256=srCAjUk-fHkfasc4p7sL1EWlbSocH54S5VTjHHk98V8,3405
13
+ meshagent/cli/messaging.py,sha256=9tWDeAipiFCFYUL3YEbgFkSWj3Yyao0dl3bT1xf1T9k,6642
14
+ meshagent/cli/participant_token.py,sha256=dsduxSFKSVcfRQV2rVx7AsNre42kopeDY6lPmtrKWR4,1144
15
+ meshagent/cli/projects.py,sha256=n0TZOFhieTtKis1bgwMUi5ayamrGtPY7ptnb96JNCyo,894
16
+ meshagent/cli/services.py,sha256=vba2oOyhlp7ql_f-mKk7YqjPpikcFWlcwyYbp7m_c4g,6152
17
+ meshagent/cli/sessions.py,sha256=WWvuztYqRfthSq6ztwL_eQ_sz9JRc33jcN6p7YyM_Fs,782
18
+ meshagent/cli/storage.py,sha256=wb57WpZtD6ucI-kfGUz4eOCsItsdqmB4aQ9NLBDRmSo,34543
19
+ meshagent/cli/version.py,sha256=WlMBNrzKywm5RAbqEVgEgcG7Opc4cf3-wpAnO8PdoEI,23
20
+ meshagent/cli/webhook.py,sha256=-4UfqlRxZWsej5LVebsgSZ5hxHot3ddTM4MlpGZrc-A,2810
21
+ meshagent_cli-0.0.17.dist-info/METADATA,sha256=_BvxcBwXbMN9L3p6c0RrIfg12p3qomnQo5N7Ziz0FHs,543
22
+ meshagent_cli-0.0.17.dist-info/WHEEL,sha256=0CuiUZ_p9E4cD6NyLD6UG80LBXYyiSYZOKDm5lp32xk,91
23
+ meshagent_cli-0.0.17.dist-info/entry_points.txt,sha256=WRcGGN4vMtvC5Pgl3uRFqsJiQXNoHuLLa-TCSY3gAhQ,52
24
+ meshagent_cli-0.0.17.dist-info/top_level.txt,sha256=GlcXnHtRP6m7zlG3Df04M35OsHtNXy_DY09oFwWrH74,10
25
+ meshagent_cli-0.0.17.dist-info/RECORD,,
@@ -0,0 +1,5 @@
1
+ Wheel-Version: 1.0
2
+ Generator: setuptools (80.3.1)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+
@@ -0,0 +1,2 @@
1
+ [console_scripts]
2
+ meshagent = meshagent.cli.cli:app
@@ -0,0 +1 @@
1
+ meshagent