Skip to content

[Bug]:Tool Edit Screen Issues – Field Mismatch & MCP Tool Validation Error #715

@rakdutta

Description

@rakdutta

There are two issues identified in the Tool Edit functionality:

1. Field Mismatch in Edit Screen

  • Add Tool Screen: gateway_name and original_name fields are present.
  • Edit Tool Screen: Points to name field instead of gateway_name/original_name.
  • Impact: Users see different field mapping in Add vs. Edit, causing confusion and potential incorrect updates.

2. Blank integration_type & request_type in Edit MCP Tool

  • For MCP tools, the integration_type and request_type fields appear blank in the edit screen, despite the database having correct values.
  • When attempting to update such a tool, a validation error occurs:
request_type
  Input should be 'GET', 'POST', 'PUT', 'DELETE' or 'PATCH' [type=literal_error, input_value='SSE', input_type=str]
    For further information visit https://errors.pydantic.dev/2.11/v/literal_error
2025-08-11 14:35:09,113 - uvicorn.access - INFO - 127.0.0.1:36742 - "POST /admin/tools/e11f9b4340af40ba860773dc81ac9211/edit HTTP/1.1" 422

Steps to Reproduce:

  1. Field mismatch issue:

    • Go to Add Tool screen → observe fields gateway_name & original_name.
    • Go to Edit Tool screen → observe it points to name instead.
  2. MCP tool validation issue:

    • Edit any existing MCP tool from the admin UI.
    • Observe integration_type and request_type are blank.
    • Attempt to save → validation error appears.

Expected Behavior:

  • Field consistency: gateway_name & original_name should be visible in both Add & Edit screens.
  • MCP tool edit: Existing integration_type and request_type values should be pre-filled from the database to avoid validation errors.

Suggested Fix:

  • Ensure field mapping in Edit Tool matches Add Tool (gateway_name & original_name).
  • Pre-populate integration_type and request_type in edit form for MCP tools from DB values.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingtriageIssues / Features awaiting triage

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions