agentic-fabriq-sdk 0.1.20__tar.gz → 0.1.22__tar.gz

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.

Files changed (40) hide show
  1. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/PKG-INFO +5 -5
  2. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/README.md +4 -4
  3. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/auth/applications.py +1 -1
  4. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/fabriq_client.py +0 -79
  5. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/pyproject.toml +1 -1
  6. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/__init__.py +0 -0
  7. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/commands/__init__.py +0 -0
  8. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/commands/applications.py +0 -0
  9. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/commands/auth.py +0 -0
  10. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/commands/config.py +0 -0
  11. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/commands/mcp_servers.py +0 -0
  12. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/commands/secrets.py +0 -0
  13. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/commands/tools.py +0 -0
  14. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/core/__init__.py +0 -0
  15. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/core/client.py +0 -0
  16. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/core/config.py +0 -0
  17. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/core/oauth.py +0 -0
  18. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/core/output.py +0 -0
  19. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/core/token_storage.py +0 -0
  20. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_cli/main.py +0 -0
  21. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/__init__.py +0 -0
  22. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/auth/__init__.py +0 -0
  23. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/auth/dpop.py +0 -0
  24. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/auth/oauth.py +0 -0
  25. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/auth/token_cache.py +0 -0
  26. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/connectors/__init__.py +0 -0
  27. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/connectors/base.py +0 -0
  28. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/connectors/registry.py +0 -0
  29. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/dx/__init__.py +0 -0
  30. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/dx/decorators.py +0 -0
  31. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/dx/runtime.py +0 -0
  32. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/events.py +0 -0
  33. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/exceptions.py +0 -0
  34. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/models/__init__.py +0 -0
  35. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/models/audit.py +0 -0
  36. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/models/types.py +0 -0
  37. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/py.typed +0 -0
  38. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/transport/__init__.py +0 -0
  39. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/transport/http.py +0 -0
  40. {agentic_fabriq_sdk-0.1.20 → agentic_fabriq_sdk-0.1.22}/af_sdk/vault.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: agentic-fabriq-sdk
3
- Version: 0.1.20
3
+ Version: 0.1.22
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
@@ -88,12 +88,12 @@ async def main():
88
88
  tools = await af.list_tools()
89
89
  agents = await af.list_agents()
90
90
 
91
- # Invoke tools by name (easier!)
92
- result = await af.invoke_tool("slack", method="get_channels")
91
+ # Invoke tools using connection ID
92
+ result = await af.invoke_connection("my-slack", method="get_channels")
93
93
 
94
94
  # Or post a message
95
- await af.invoke_tool(
96
- "slack",
95
+ await af.invoke_connection(
96
+ "my-slack",
97
97
  method="post_message",
98
98
  parameters={"channel": "test", "text": "Hello from SDK!"}
99
99
  )
@@ -52,12 +52,12 @@ async def main():
52
52
  tools = await af.list_tools()
53
53
  agents = await af.list_agents()
54
54
 
55
- # Invoke tools by name (easier!)
56
- result = await af.invoke_tool("slack", method="get_channels")
55
+ # Invoke tools using connection ID
56
+ result = await af.invoke_connection("my-slack", method="get_channels")
57
57
 
58
58
  # Or post a message
59
- await af.invoke_tool(
60
- "slack",
59
+ await af.invoke_connection(
60
+ "my-slack",
61
61
  method="post_message",
62
62
  parameters={"channel": "test", "text": "Hello from SDK!"}
63
63
  )
@@ -51,7 +51,7 @@ async def get_application_client(
51
51
 
52
52
  Example:
53
53
  >>> client = await get_application_client("my-slack-bot")
54
- >>> result = await client.invoke_tool("slack-uuid", "post_message", {...})
54
+ >>> result = await client.invoke_connection("my-slack", method="post_message", parameters={...})
55
55
  """
56
56
  # 1. Load application config
57
57
  try:
@@ -78,85 +78,6 @@ class FabriqClient:
78
78
  r = await self._http.get("/tools", params=params, headers=self._extra_headers)
79
79
  return r.json()
80
80
 
81
- async def invoke_tool(
82
- self,
83
- tool_identifier: str,
84
- *,
85
- method: str,
86
- parameters: Optional[Dict[str, Any]] = None,
87
- context: Optional[Dict[str, Any]] = None,
88
- connection_id: Optional[str] = None,
89
- ) -> Dict[str, Any]:
90
- """Invoke a tool by name or UUID.
91
-
92
- Args:
93
- tool_identifier: Tool name (e.g., 'slack') or UUID
94
- method: Method name to invoke
95
- parameters: Method parameters
96
- context: Additional context
97
- connection_id: Specific connection ID to use (for multi-connection tools)
98
-
99
- Returns:
100
- Tool invocation result
101
-
102
- Examples:
103
- result = await client.invoke_tool("slack", method="get_channels")
104
- result = await client.invoke_tool("slack", method="post_message",
105
- parameters={"channel": "test", "text": "Hello!"})
106
- result = await client.invoke_tool("slack", method="get_channels",
107
- connection_id="slacker")
108
- """
109
- # Try to resolve tool name to UUID if not already a UUID
110
- tool_id = tool_identifier
111
- try:
112
- from uuid import UUID
113
- UUID(tool_identifier)
114
- # It's already a UUID, use it directly
115
- except ValueError:
116
- # Not a UUID, try to look up by name
117
- try:
118
- tools_response = await self.list_tools()
119
- except Exception as e:
120
- raise ValueError(f"Failed to list tools for name resolution: {e}. Please use UUID directly.")
121
-
122
- # Handle different response formats
123
- if isinstance(tools_response, dict) and "tools" in tools_response:
124
- tools = tools_response["tools"]
125
- elif isinstance(tools_response, dict) and "items" in tools_response:
126
- tools = tools_response["items"]
127
- elif hasattr(tools_response, '__iter__') and not isinstance(tools_response, (str, dict)):
128
- tools = list(tools_response)
129
- else:
130
- tools = []
131
-
132
- # Find tool by name (case-insensitive)
133
- matching_tools = [t for t in tools if isinstance(t, dict) and t.get("name", "").lower() == tool_identifier.lower()]
134
-
135
- if not matching_tools:
136
- available = [t.get('name') for t in tools if isinstance(t, dict) and t.get('name')]
137
- raise ValueError(f"Tool '{tool_identifier}' not found. Available tools: {available}")
138
-
139
- if len(matching_tools) > 1:
140
- raise ValueError(f"Multiple tools found with name '{tool_identifier}'. Please use UUID instead.")
141
-
142
- tool_id = matching_tools[0].get("id")
143
- if not tool_id:
144
- raise ValueError(f"Tool '{tool_identifier}' found but has no ID")
145
-
146
- body = {"method": method}
147
- if parameters is not None:
148
- body["parameters"] = parameters
149
-
150
- # Add connection_id to context if provided
151
- if context is not None or connection_id is not None:
152
- ctx = (context or {}).copy()
153
- if connection_id is not None:
154
- ctx["connection_id"] = connection_id
155
- body["context"] = ctx
156
-
157
- r = await self._http.post(f"/tools/{tool_id}/invoke", json=body, headers=self._extra_headers)
158
- return r.json()
159
-
160
81
  async def invoke_connection(
161
82
  self,
162
83
  connection_id: str,
@@ -5,7 +5,7 @@ build-backend = "poetry.core.masonry.api"
5
5
 
6
6
  [tool.poetry]
7
7
  name = "agentic-fabriq-sdk"
8
- version = "0.1.20"
8
+ version = "0.1.22"
9
9
  description = "Agentic Fabriq SDK: high-level client, CLI tool, DX helpers, and auth for AI agents"
10
10
  readme = "README.md"
11
11
  license = "Apache-2.0"