agentic-fabriq-sdk 0.1.22__py3-none-any.whl → 0.1.23__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/tools.py +26 -7
- {agentic_fabriq_sdk-0.1.22.dist-info → agentic_fabriq_sdk-0.1.23.dist-info}/METADATA +1 -1
- {agentic_fabriq_sdk-0.1.22.dist-info → agentic_fabriq_sdk-0.1.23.dist-info}/RECORD +5 -5
- {agentic_fabriq_sdk-0.1.22.dist-info → agentic_fabriq_sdk-0.1.23.dist-info}/WHEEL +0 -0
- {agentic_fabriq_sdk-0.1.22.dist-info → agentic_fabriq_sdk-0.1.23.dist-info}/entry_points.txt +0 -0
af_cli/commands/tools.py
CHANGED
|
@@ -197,7 +197,7 @@ def add(
|
|
|
197
197
|
tool: str = typer.Argument(..., help="Tool name (google_drive, google_slides, slack, notion, github, etc.)"),
|
|
198
198
|
connection_id: str = typer.Option(..., "--connection-id", help="Unique connection ID"),
|
|
199
199
|
display_name: str = typer.Option(None, "--display-name", help="Human-readable name"),
|
|
200
|
-
method: str = typer.Option(..., "--method", help="Connection method: 'api_credentials' or 'oauth'"),
|
|
200
|
+
method: str = typer.Option(..., "--method", help="Connection method: 'api_credentials', 'oauth3' (Google platform OAuth), or 'oauth'"),
|
|
201
201
|
|
|
202
202
|
# API credentials method fields (can be either a token OR client_id/secret)
|
|
203
203
|
token: str = typer.Option(None, "--token", help="API token (for simple token-based auth like Notion, Slack bot)"),
|
|
@@ -212,7 +212,10 @@ def add(
|
|
|
212
212
|
# Notion (api_credentials method - single token)
|
|
213
213
|
afctl tools add notion --connection-id notion-work --method api_credentials --token "secret_abc123"
|
|
214
214
|
|
|
215
|
-
# Google (
|
|
215
|
+
# Google (oauth3 method - uses platform OAuth, no credentials needed)
|
|
216
|
+
afctl tools add google_drive --connection-id google-work --method oauth3
|
|
217
|
+
|
|
218
|
+
# Google (api_credentials method - your own OAuth app)
|
|
216
219
|
afctl tools add google_drive --connection-id google-work --method api_credentials \\
|
|
217
220
|
--client-id "123.apps.googleusercontent.com" \\
|
|
218
221
|
--client-secret "GOCSPX-abc123"
|
|
@@ -247,10 +250,17 @@ def add(
|
|
|
247
250
|
raise typer.Exit(1)
|
|
248
251
|
|
|
249
252
|
# Validate method
|
|
250
|
-
if method not in ["api_credentials", "oauth"]:
|
|
251
|
-
error("Method must be 'api_credentials' or 'oauth'")
|
|
253
|
+
if method not in ["api_credentials", "oauth3", "oauth"]:
|
|
254
|
+
error("Method must be 'api_credentials', 'oauth3', or 'oauth'")
|
|
252
255
|
raise typer.Exit(1)
|
|
253
256
|
|
|
257
|
+
# Validate oauth3 method is only for Google tools
|
|
258
|
+
if method == "oauth3":
|
|
259
|
+
if not (tool.startswith("google_") or tool == "gmail"):
|
|
260
|
+
error("oauth3 method is only available for Google Workspace tools")
|
|
261
|
+
info("For other tools, use 'api_credentials' method")
|
|
262
|
+
raise typer.Exit(1)
|
|
263
|
+
|
|
254
264
|
# Validate api_credentials method requirements
|
|
255
265
|
if method == "api_credentials":
|
|
256
266
|
# Must have either token OR (client_id + client_secret)
|
|
@@ -282,8 +292,14 @@ def add(
|
|
|
282
292
|
client.post("/api/v1/user-connections", data=connection_data)
|
|
283
293
|
success(f"✅ Connection entry created: {connection_id}")
|
|
284
294
|
|
|
285
|
-
# Step 2: Store credentials based on
|
|
286
|
-
if method == "
|
|
295
|
+
# Step 2: Store credentials based on method
|
|
296
|
+
if method == "oauth3":
|
|
297
|
+
# OAuth3 uses platform credentials - no need to store user credentials
|
|
298
|
+
success("✅ Connection configured with platform OAuth")
|
|
299
|
+
info("")
|
|
300
|
+
info(f"Next: Run 'afctl tools connect {connection_id}' to authenticate with your Google account")
|
|
301
|
+
|
|
302
|
+
elif method == "api_credentials":
|
|
287
303
|
# Determine the API base tool name (Google tools all use "google")
|
|
288
304
|
api_tool_name = "google" if (tool.startswith("google_") or tool == "gmail") else tool
|
|
289
305
|
|
|
@@ -393,8 +409,11 @@ def connect(
|
|
|
393
409
|
# For Google tools, pass the specific tool_type parameter
|
|
394
410
|
tool_type_param = f"&tool_type={tool}" if tool != api_tool_name else ""
|
|
395
411
|
|
|
412
|
+
# For oauth3 method, pass the method parameter to use platform credentials
|
|
413
|
+
method_param = f"&method={method}" if method == "oauth3" else ""
|
|
414
|
+
|
|
396
415
|
result = client.post(
|
|
397
|
-
f"/api/v1/tools/{api_tool_name}/connect/initiate?connection_id={connection_id}{tool_type_param}",
|
|
416
|
+
f"/api/v1/tools/{api_tool_name}/connect/initiate?connection_id={connection_id}{tool_type_param}{method_param}",
|
|
398
417
|
data={}
|
|
399
418
|
)
|
|
400
419
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: agentic-fabriq-sdk
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.23
|
|
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
|
|
@@ -5,7 +5,7 @@ af_cli/commands/auth.py,sha256=gz7DLiTTV0nv2DnKaa7_9nLHevCWslG54rRKRA1alx0,11967
|
|
|
5
5
|
af_cli/commands/config.py,sha256=_k4ixGZfa7Yl_yUL-W1jeMQzykFcPcbw20Yr1v6_ShM,2748
|
|
6
6
|
af_cli/commands/mcp_servers.py,sha256=1hEb4tX80dYb-j_2Z3gDud_v1FcMxl83syJ2N2eLWzI,2390
|
|
7
7
|
af_cli/commands/secrets.py,sha256=z_rHfn8-KEonTC5dioBgH7sc1ppMOltFVFz-58Nqwa0,3436
|
|
8
|
-
af_cli/commands/tools.py,sha256=
|
|
8
|
+
af_cli/commands/tools.py,sha256=2ulB-UMvjNujHOpu2GowLivEFvUq41ftDj04QUUd8H0,25665
|
|
9
9
|
af_cli/core/__init__.py,sha256=cQ0H7rGfaMISQPhoNe4Xfu_EKU2TqRVt2OMI7tPea5U,51
|
|
10
10
|
af_cli/core/client.py,sha256=AYNWdCMNtDx7LOGXwoS7_rruss479T0lD6PZ1hG5dMA,5082
|
|
11
11
|
af_cli/core/config.py,sha256=fwLUF0blNII2RKdFlJ3Hat51vwwNyxpIkU_HvViz8To,8538
|
|
@@ -35,7 +35,7 @@ af_sdk/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
|
35
35
|
af_sdk/transport/__init__.py,sha256=HsOc6MmlxIS-PSYC_-6E36-dZYyT_auZeoXvGzVAqeg,104
|
|
36
36
|
af_sdk/transport/http.py,sha256=QB3eqQbwug95QHf5PG_714NKtlTjV9PzVTo8izJCylc,13203
|
|
37
37
|
af_sdk/vault.py,sha256=QVNGigIw8ND5sVXt05gvUY222b5-i9EbzLWNsDGdOU4,17926
|
|
38
|
-
agentic_fabriq_sdk-0.1.
|
|
39
|
-
agentic_fabriq_sdk-0.1.
|
|
40
|
-
agentic_fabriq_sdk-0.1.
|
|
41
|
-
agentic_fabriq_sdk-0.1.
|
|
38
|
+
agentic_fabriq_sdk-0.1.23.dist-info/METADATA,sha256=2pgcbX9ATNcVI6f6i_OziKFUTpK_ypzwyFlC0fct2-c,3678
|
|
39
|
+
agentic_fabriq_sdk-0.1.23.dist-info/WHEEL,sha256=zp0Cn7JsFoX2ATtOhtaFYIiE2rmFAD4OcMhtUki8W3U,88
|
|
40
|
+
agentic_fabriq_sdk-0.1.23.dist-info/entry_points.txt,sha256=XUO2EaJhUtUS5pwVIkhemC-nEeFbKgXXLW97gQCCGm8,41
|
|
41
|
+
agentic_fabriq_sdk-0.1.23.dist-info/RECORD,,
|
|
File without changes
|
{agentic_fabriq_sdk-0.1.22.dist-info → agentic_fabriq_sdk-0.1.23.dist-info}/entry_points.txt
RENAMED
|
File without changes
|