{% extends "base.html" %} {# Import the macro for the single server form #} {% from "_server_form_macro.html" import render_server_form %} {% block title %}Add Servers - MCP Manager{% endblock %} {% block page_title %}Add Server Definitions{% endblock %} {% block page_subtitle %}Add a single server via form or multiple servers from JSON{% endblock %} {% block head_extra %} {% endblock %} {% block content %}
info_outlineFirst select "Server type" to see the corresponding fields (Command/Arguments or URL).
{# Render the form using the macro #} {{ render_server_form( action_url=single_add_action_url, submit_button_text='Add This Server', server=single_server_form_data, error=None, is_add_form=True, request=request, cancel_url=url_for('ui_root') ) }}Format 1: Object with "mcpServers" key
{
"mcpServers": {
"my-tool": { "command": "npx", "args": ["pkg", "--arg"] },
"sse-tool": { "type": "sse", "url": "http://..." }
}
}
Format 2: Direct mapping "name": {config}
{
"tool-alpha": { "command": "uvx", "args": ["server-a"] },
"stream-beta": { "type": "streamable_http", "url": "http://..." }
}
Format 3: List of objects with "name" field
[
{ "name": "gamma", "command": "/bin/gamma", "args": ["--conf"] },
{ "name": "delta", "type": "sse", "url": "https://..." }
]
Format 4: Single object with "name" field (Useful for single server import/export)
{
"name": "epsilon",
"command": "docker",
"args": ["run", "my-image"],
"env_vars": {"VAR": "value"},
"server_type": "stdio",
"is_enabled": false
}
Notes:
Analysis results will appear here after you click "Analyze JSON".
{# The content from _bulk_add_preview.html will be loaded here #}