feat: Add UI for custom tools (#12585)
### Tools list <img width="2316" height="666" alt="CleanShot 2025-10-03 at 20 42 41@2x" src="https://github.com/user-attachments/assets/ccbffd16-804d-4eb8-9c64-2d1cfd407e4e" /> ### Tools form <img width="2294" height="2202" alt="CleanShot 2025-10-03 at 20 43 05@2x" src="https://github.com/user-attachments/assets/9f49aa09-75a1-4585-a09d-837ca64139b8" /> ## Response <img width="800" height="2144" alt="CleanShot 2025-10-03 at 20 45 56@2x" src="https://github.com/user-attachments/assets/b0c3c899-6050-4c51-baed-c8fbec5aae61" /> --------- Co-authored-by: Pranav <pranavrajs@gmail.com> Co-authored-by: Pranav <pranav@chatwoot.com>
This commit is contained in:
@@ -0,0 +1 @@
|
||||
json.partial! 'api/v1/models/captain/custom_tool', custom_tool: @custom_tool
|
||||
@@ -0,0 +1,10 @@
|
||||
json.payload do
|
||||
json.array! @custom_tools do |custom_tool|
|
||||
json.partial! 'api/v1/models/captain/custom_tool', custom_tool: custom_tool
|
||||
end
|
||||
end
|
||||
|
||||
json.meta do
|
||||
json.total_count @custom_tools.count
|
||||
json.page 1
|
||||
end
|
||||
@@ -0,0 +1 @@
|
||||
json.partial! 'api/v1/models/captain/custom_tool', custom_tool: @custom_tool
|
||||
@@ -0,0 +1 @@
|
||||
json.partial! 'api/v1/models/captain/custom_tool', custom_tool: @custom_tool
|
||||
@@ -0,0 +1,15 @@
|
||||
json.id custom_tool.id
|
||||
json.slug custom_tool.slug
|
||||
json.title custom_tool.title
|
||||
json.description custom_tool.description
|
||||
json.endpoint_url custom_tool.endpoint_url
|
||||
json.http_method custom_tool.http_method
|
||||
json.request_template custom_tool.request_template
|
||||
json.response_template custom_tool.response_template
|
||||
json.auth_type custom_tool.auth_type
|
||||
json.auth_config custom_tool.auth_config
|
||||
json.param_schema custom_tool.param_schema
|
||||
json.enabled custom_tool.enabled
|
||||
json.account_id custom_tool.account_id
|
||||
json.created_at custom_tool.created_at.to_i
|
||||
json.updated_at custom_tool.updated_at.to_i
|
||||
Reference in New Issue
Block a user