flock-core 0.4.534__py3-none-any.whl → 0.4.536__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 flock-core might be problematic. Click here for more details.

@@ -146,7 +146,8 @@ def zendesk_search_articles(query: str) -> list[dict]:
146
146
  response.raise_for_status()
147
147
  return response.json().get("results", [])
148
148
 
149
- def zendesk_add_comment_to_ticket(ticket_id: str, comment_body: str, public: bool = True) -> dict:
149
+ @mcp.tool()
150
+ def zendesk_add_comment_to_ticket(ticket_id: str, comment_body: str, public: bool = False) -> dict:
150
151
  """Add a comment to a Zendesk ticket.
151
152
 
152
153
  Updates the ticket with a new comment via Zendesk Ticketing API:
@@ -171,6 +172,73 @@ def zendesk_add_comment_to_ticket(ticket_id: str, comment_body: str, public: boo
171
172
  response.raise_for_status()
172
173
  return response.json()["ticket"]
173
174
 
175
+ @mcp.tool()
176
+ def zendesk_set_ticket_custom_field(
177
+ ticket_id: str, custom_field_id: int, category_value: str
178
+ ) -> dict:
179
+ """Set the custom field value of a Zendesk ticket.
180
+
181
+ Uses Zendesk's Update Ticket API to set a custom field value:
182
+ PUT /api/v2/tickets/{ticket_id}.json
183
+ """
184
+ ZENDESK_SUBDOMAIN = os.getenv("ZENDESK_SUBDOMAIN_TICKET")
185
+ BASE_URL = f"https://{ZENDESK_SUBDOMAIN}.zendesk.com"
186
+ url = f"{BASE_URL}/api/v2/tickets/{ticket_id}.json"
187
+
188
+ payload = {
189
+ "ticket": {
190
+ "custom_fields": [
191
+ {
192
+ "id": custom_field_id,
193
+ "value": category_value,
194
+ }
195
+ ]
196
+ }
197
+ }
198
+
199
+ import httpx
200
+
201
+ with httpx.Client(headers=_get_headers(), timeout=30.0) as client:
202
+ response = client.put(url, json=payload)
203
+ response.raise_for_status()
204
+ return response.json()["ticket"]
205
+
206
+
207
+
208
+ @mcp.tool()
209
+ def zendesk_set_ticket_tags(ticket_id: str, tags: list[str]) -> list[str]:
210
+ """Set the complete tag list for a ticket (overwrites existing tags)."""
211
+ ZENDESK_SUBDOMAIN = os.getenv("ZENDESK_SUBDOMAIN_TICKET")
212
+ BASE_URL = f"https://{ZENDESK_SUBDOMAIN}.zendesk.com"
213
+ url = f"{BASE_URL}/api/v2/tickets/{ticket_id}/tags.json"
214
+
215
+ payload = {"tags": tags}
216
+
217
+ import httpx
218
+
219
+ with httpx.Client(headers=_get_headers(), timeout=30.0) as client:
220
+ resp = client.put(url, json=payload)
221
+ resp.raise_for_status()
222
+ return resp.json().get("tags", [])
223
+
224
+
225
+ @mcp.tool()
226
+ def zendesk_add_ticket_tags(ticket_id: str, tags: list[str]) -> list[str]:
227
+ """Add tags to a ticket (preserves existing tags)."""
228
+ ZENDESK_SUBDOMAIN = os.getenv("ZENDESK_SUBDOMAIN_TICKET")
229
+ BASE_URL = f"https://{ZENDESK_SUBDOMAIN}.zendesk.com"
230
+ url = f"{BASE_URL}/api/v2/tickets/{ticket_id}/tags.json"
231
+
232
+ payload = {"tags": tags}
233
+
234
+ import httpx
235
+
236
+ with httpx.Client(headers=_get_headers(), timeout=30.0) as client:
237
+ resp = client.post(url, json=payload)
238
+ resp.raise_for_status()
239
+ return resp.json().get("tags", [])
240
+
241
+
174
242
 
175
243
  if __name__ == "__main__":
176
244
  transport = os.getenv("ZENDESK_MCP_TRANSPORT", "stdio")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: flock-core
3
- Version: 0.4.534
3
+ Version: 0.4.536
4
4
  Summary: Declarative LLM Orchestration at Scale
5
5
  Author-email: Andre Ratzenberger <andre.ratzenberger@whiteduck.de>
6
6
  License-File: LICENSE
@@ -488,7 +488,7 @@ flock/tools/markdown_tools.py,sha256=94fjGAJ5DEutoioD0ke-YRbxF6IWJQKuPVBLkNqdBo4
488
488
  flock/tools/system_tools.py,sha256=IUB8MiSxtQH5ZfTGOck3vl4TKva8m1lfU4-W5D5b-4w,202
489
489
  flock/tools/text_tools.py,sha256=mMQ8tkyYDxIorqqzl9ccGyWYjrSynYiYFIeP9qypfdg,22491
490
490
  flock/tools/web_tools.py,sha256=h44L5rknxGw1mVnFTYO-z0xwUr5ctOvMiJBIfeq56UE,2555
491
- flock/tools/zendesk_tools.py,sha256=aWXAjfwcl2AL5gRoNO4KPbXQbaKr35jDWC46zt2TsQk,6156
491
+ flock/tools/zendesk_tools.py,sha256=-BqroX1J8LYm10H91820C8iKQTdmWtEp0DQzyE4Ihyc,8235
492
492
  flock/webapp/__init__.py,sha256=YtRbbyciN3Z2oMB9fdXZuvM3e49R8m2mY5qHLDoapRA,37
493
493
  flock/webapp/run.py,sha256=btKVwIqrFg3FhLRuj2RN_fazwaFat3Ue5yiFiIg60rQ,9054
494
494
  flock/webapp/app/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -563,8 +563,8 @@ flock/workflow/agent_execution_activity.py,sha256=hLqWEWsxwTgjsE9wvBejf3pN2TdIfU
563
563
  flock/workflow/flock_workflow.py,sha256=iSUF_soFvWar0ffpkzE4irkDZRx0p4HnwmEBi_Ne2sY,9666
564
564
  flock/workflow/temporal_config.py,sha256=3_8O7SDEjMsSMXsWJBfnb6XTp0TFaz39uyzSlMTSF_I,3988
565
565
  flock/workflow/temporal_setup.py,sha256=YIHnSBntzOchHfMSh8hoLeNXrz3B1UbR14YrR6soM7A,1606
566
- flock_core-0.4.534.dist-info/METADATA,sha256=IqO9_ei3jgBQtqkGa8aQJBwJBQ3TrSVpUY00IyFJSkQ,22800
567
- flock_core-0.4.534.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
568
- flock_core-0.4.534.dist-info/entry_points.txt,sha256=rWaS5KSpkTmWySURGFZk6PhbJ87TmvcFQDi2uzjlagQ,37
569
- flock_core-0.4.534.dist-info/licenses/LICENSE,sha256=iYEqWy0wjULzM9GAERaybP4LBiPeu7Z1NEliLUdJKSc,1072
570
- flock_core-0.4.534.dist-info/RECORD,,
566
+ flock_core-0.4.536.dist-info/METADATA,sha256=hfLx-IocpeYRSfxS1L7haSj34u_KizDwCS7tAXq_egA,22800
567
+ flock_core-0.4.536.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
568
+ flock_core-0.4.536.dist-info/entry_points.txt,sha256=rWaS5KSpkTmWySURGFZk6PhbJ87TmvcFQDi2uzjlagQ,37
569
+ flock_core-0.4.536.dist-info/licenses/LICENSE,sha256=iYEqWy0wjULzM9GAERaybP4LBiPeu7Z1NEliLUdJKSc,1072
570
+ flock_core-0.4.536.dist-info/RECORD,,