agentic-fabriq-sdk 0.1.10__py3-none-any.whl → 0.1.13__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 agentic-fabriq-sdk might be problematic. Click here for more details.
- af_cli/commands/config.py +4 -0
- af_cli/core/config.py +28 -4
- {agentic_fabriq_sdk-0.1.10.dist-info → agentic_fabriq_sdk-0.1.13.dist-info}/METADATA +1 -1
- {agentic_fabriq_sdk-0.1.10.dist-info → agentic_fabriq_sdk-0.1.13.dist-info}/RECORD +6 -6
- {agentic_fabriq_sdk-0.1.10.dist-info → agentic_fabriq_sdk-0.1.13.dist-info}/WHEEL +0 -0
- {agentic_fabriq_sdk-0.1.10.dist-info → agentic_fabriq_sdk-0.1.13.dist-info}/entry_points.txt +0 -0
af_cli/commands/config.py
CHANGED
|
@@ -15,14 +15,18 @@ def show(
|
|
|
15
15
|
format: str = typer.Option("table", "--format", "-f", help="Output format"),
|
|
16
16
|
):
|
|
17
17
|
"""Show current configuration."""
|
|
18
|
+
import os
|
|
18
19
|
config = get_config()
|
|
19
20
|
|
|
20
21
|
config_data = {
|
|
21
22
|
"gateway_url": config.gateway_url,
|
|
23
|
+
"keycloak_url": config.keycloak_url,
|
|
22
24
|
"tenant_id": config.tenant_id or "Not set",
|
|
23
25
|
"authenticated": "Yes" if config.is_authenticated() else "No",
|
|
24
26
|
"config_file": config.config_file,
|
|
25
27
|
"output_format": config.output_format,
|
|
28
|
+
"env_gateway_url": os.getenv("AF_GATEWAY_URL", "Not set"),
|
|
29
|
+
"env_keycloak_url": os.getenv("AF_KEYCLOAK_URL", "Not set"),
|
|
26
30
|
}
|
|
27
31
|
|
|
28
32
|
print_output(
|
af_cli/core/config.py
CHANGED
|
@@ -13,11 +13,17 @@ from pydantic import BaseModel, Field
|
|
|
13
13
|
class CLIConfig(BaseModel):
|
|
14
14
|
"""CLI configuration model."""
|
|
15
15
|
|
|
16
|
-
# Gateway settings
|
|
17
|
-
gateway_url: str = Field(
|
|
16
|
+
# Gateway settings (support environment variable override)
|
|
17
|
+
gateway_url: str = Field(
|
|
18
|
+
default_factory=lambda: os.getenv("AF_GATEWAY_URL", "https://dashboard.agenticfabriq.com"),
|
|
19
|
+
description="Gateway URL"
|
|
20
|
+
)
|
|
18
21
|
|
|
19
|
-
# Keycloak settings
|
|
20
|
-
keycloak_url: str = Field(
|
|
22
|
+
# Keycloak settings (support environment variable override)
|
|
23
|
+
keycloak_url: str = Field(
|
|
24
|
+
default_factory=lambda: os.getenv("AF_KEYCLOAK_URL", "https://auth.agenticfabriq.com"),
|
|
25
|
+
description="Keycloak URL"
|
|
26
|
+
)
|
|
21
27
|
keycloak_realm: str = Field(default="agentic-fabric", description="Keycloak realm")
|
|
22
28
|
keycloak_client_id: str = Field(default="agentic-fabriq-cli", description="Keycloak client ID for CLI")
|
|
23
29
|
|
|
@@ -52,10 +58,26 @@ class CLIConfig(BaseModel):
|
|
|
52
58
|
with open(self.config_file, 'r') as f:
|
|
53
59
|
data = json.load(f)
|
|
54
60
|
|
|
61
|
+
# Migrate old localhost URLs to production URLs
|
|
62
|
+
needs_migration = False
|
|
63
|
+
if data.get('gateway_url') in ['http://localhost:8000', 'localhost:8000']:
|
|
64
|
+
data['gateway_url'] = 'https://dashboard.agenticfabriq.com'
|
|
65
|
+
needs_migration = True
|
|
66
|
+
print("✨ Migrated gateway_url from localhost to dashboard.agenticfabriq.com")
|
|
67
|
+
|
|
68
|
+
if data.get('keycloak_url') in ['http://localhost:8080', 'localhost:8080']:
|
|
69
|
+
data['keycloak_url'] = 'https://auth.agenticfabriq.com'
|
|
70
|
+
needs_migration = True
|
|
71
|
+
print("✨ Migrated keycloak_url from localhost to auth.agenticfabriq.com")
|
|
72
|
+
|
|
55
73
|
# Update fields from loaded data
|
|
56
74
|
for key, value in data.items():
|
|
57
75
|
if hasattr(self, key):
|
|
58
76
|
setattr(self, key, value)
|
|
77
|
+
|
|
78
|
+
# Save migrated config
|
|
79
|
+
if needs_migration:
|
|
80
|
+
self.save()
|
|
59
81
|
|
|
60
82
|
except Exception as e:
|
|
61
83
|
print(f"Warning: Failed to load config from {self.config_file}: {e}")
|
|
@@ -191,6 +213,8 @@ def get_config() -> CLIConfig:
|
|
|
191
213
|
global _config
|
|
192
214
|
if _config is None:
|
|
193
215
|
_config = CLIConfig()
|
|
216
|
+
# Load existing config (with automatic migration)
|
|
217
|
+
_config.load()
|
|
194
218
|
return _config
|
|
195
219
|
|
|
196
220
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: agentic-fabriq-sdk
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.13
|
|
4
4
|
Summary: Agentic Fabriq SDK: high-level client, CLI tool, DX helpers, and auth for AI agents
|
|
5
5
|
License: Apache-2.0
|
|
6
6
|
Keywords: fabriq,agentic-fabriq,sdk,ai,agents,agentic,fabric,cli
|
|
@@ -2,13 +2,13 @@ af_cli/__init__.py,sha256=F2T4x4H3VIdmTjHRyV5DkaRvbZcdHYzAWD2hxtTplE4,188
|
|
|
2
2
|
af_cli/commands/__init__.py,sha256=Qngm2Yks6oTKazlxCZA_tIAHXwHoU6Oc7Pw5BGkA7W4,49
|
|
3
3
|
af_cli/commands/agents.py,sha256=EBAZgY5YbcR6npN0m7n1YB3WUTnW050Dd6FfORn0TtQ,8433
|
|
4
4
|
af_cli/commands/auth.py,sha256=EuVIuTzpQ6eC6Tq9rdBF83HpfN-Jb4O0Ep_CLwhorUo,12071
|
|
5
|
-
af_cli/commands/config.py,sha256=
|
|
5
|
+
af_cli/commands/config.py,sha256=ExGQOJTCfG78g1h0-RpKV_I1vRxVDOJvGPIpCiaod-w,2754
|
|
6
6
|
af_cli/commands/mcp_servers.py,sha256=kr2MskqtwdA1434_9oEyEydlZ5Ycq8a1Vt5wSC0AqRE,2420
|
|
7
7
|
af_cli/commands/secrets.py,sha256=_XvtST9G7US_0MqHywSqRdp2FXUr76OTiD-SH4WXoJU,3472
|
|
8
8
|
af_cli/commands/tools.py,sha256=9wPXpemZh9YDCVKdIgvGFzlxMwSy0BuNg50Fs1DU6y0,21188
|
|
9
9
|
af_cli/core/__init__.py,sha256=cQ0H7rGfaMISQPhoNe4Xfu_EKU2TqRVt2OMI7tPea5U,51
|
|
10
10
|
af_cli/core/client.py,sha256=BELf6889BOzOWP6kCk4hSY4DolIATB0YNpui38l7EaI,3939
|
|
11
|
-
af_cli/core/config.py,sha256=
|
|
11
|
+
af_cli/core/config.py,sha256=fwLUF0blNII2RKdFlJ3Hat51vwwNyxpIkU_HvViz8To,8538
|
|
12
12
|
af_cli/core/oauth.py,sha256=sCzo97TZyx8sLmo0GYv53P3zoABK6htRCivHhRpPRdI,18162
|
|
13
13
|
af_cli/core/output.py,sha256=tL5z7M-tLu2M1Yl8O4M7OPP7iQivC1b_YUUB468Od5Y,4811
|
|
14
14
|
af_cli/core/token_storage.py,sha256=WhOQLx5_9pn2lAlFX01Y5DmWO7B9BJYfEkASCsBQwaI,7738
|
|
@@ -34,7 +34,7 @@ af_sdk/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
|
34
34
|
af_sdk/transport/__init__.py,sha256=HsOc6MmlxIS-PSYC_-6E36-dZYyT_auZeoXvGzVAqeg,104
|
|
35
35
|
af_sdk/transport/http.py,sha256=QB3eqQbwug95QHf5PG_714NKtlTjV9PzVTo8izJCylc,13203
|
|
36
36
|
af_sdk/vault.py,sha256=QVNGigIw8ND5sVXt05gvUY222b5-i9EbzLWNsDGdOU4,17926
|
|
37
|
-
agentic_fabriq_sdk-0.1.
|
|
38
|
-
agentic_fabriq_sdk-0.1.
|
|
39
|
-
agentic_fabriq_sdk-0.1.
|
|
40
|
-
agentic_fabriq_sdk-0.1.
|
|
37
|
+
agentic_fabriq_sdk-0.1.13.dist-info/METADATA,sha256=-__ot1wm5Te-G7hPvPAbesJZs0piI4RrwLN_tGh1sJU,3286
|
|
38
|
+
agentic_fabriq_sdk-0.1.13.dist-info/WHEEL,sha256=zp0Cn7JsFoX2ATtOhtaFYIiE2rmFAD4OcMhtUki8W3U,88
|
|
39
|
+
agentic_fabriq_sdk-0.1.13.dist-info/entry_points.txt,sha256=XUO2EaJhUtUS5pwVIkhemC-nEeFbKgXXLW97gQCCGm8,41
|
|
40
|
+
agentic_fabriq_sdk-0.1.13.dist-info/RECORD,,
|
|
File without changes
|
{agentic_fabriq_sdk-0.1.10.dist-info → agentic_fabriq_sdk-0.1.13.dist-info}/entry_points.txt
RENAMED
|
File without changes
|