diff --git a/assets/js/admin.js b/assets/js/admin.js index e62f2bd..f99b92b 100644 --- a/assets/js/admin.js +++ b/assets/js/admin.js @@ -1348,6 +1348,10 @@ var servers = {}; if ( variant === 'npx' ) { servers[ key ] = Object.assign( { type: 'stdio' }, npx ); return { mcpServers: servers }; } if ( variant === 'http' ) { servers[ key ] = http; return { mcpServers: servers }; } + if ( variant === 'antigravity-http' ) { + servers[ key ] = { serverUrl: c.endpoint, headers: { Authorization: 'Basic ' + c.b64 } }; + return { mcpServers: servers }; + } if ( variant === 'remote' ) { servers[ key ] = { command: 'npx', args: [ '-y', 'mcp-remote', c.endpoint, '--header', 'Authorization: Basic ' + c.b64 ] }; return { mcpServers: servers }; @@ -1592,6 +1596,7 @@ else if ( variant === 'openclaw-npx' ) { html += emcpCopyBlock( 'Manual config — Node proxy / npx (openclaw.json)', emcpOpenclawConfig( 'npx' ) ); } else if ( variant === 'hermes-http' ) { html += emcpCopyBlock( 'Manual config — direct HTTP (config.yaml)', emcpHermesConfig( 'http' ) ); } else if ( variant === 'hermes-npx' ) { html += emcpCopyBlock( 'Manual config — Node proxy / npx (config.yaml)', emcpHermesConfig( 'npx' ) ); } + else if ( variant === 'antigravity-http' ) { html += emcpCopyBlock( 'Manual config — direct HTTP (mcp_config.json)', JSON.stringify( emcpJsonConfig( 'antigravity-http' ), null, 4 ) ); } else { var label = variant === 'npx' ? 'Manual config — Node proxy (npx)' : variant === 'http' ? 'Manual config — direct HTTP' diff --git a/includes/admin/class-admin.php b/includes/admin/class-admin.php index b37272e..0773e53 100644 --- a/includes/admin/class-admin.php +++ b/includes/admin/class-admin.php @@ -4116,8 +4116,10 @@ class EMCP_Tools_Admin { 'type' => 'config', 'lang' => 'json', 'paths' => array( - array( 'path' => '~/.gemini/antigravity/mcp_config.json', 'label' => __( 'macOS / Linux', 'emcp-tools' ) ), - array( 'path' => '%USERPROFILE%\\.gemini\\antigravity\\mcp_config.json', 'label' => __( 'Windows', 'emcp-tools' ) ), + array( 'path' => '~/.gemini/config/mcp_config.json', 'label' => __( 'macOS / Linux (CLI)', 'emcp-tools' ) ), + array( 'path' => '~/.gemini/antigravity/mcp_config.json', 'label' => __( 'macOS / Linux (IDE)', 'emcp-tools' ) ), + array( 'path' => '%USERPROFILE%\\.gemini\\config\\mcp_config.json', 'label' => __( 'Windows (CLI)', 'emcp-tools' ) ), + array( 'path' => '%USERPROFILE%\\.gemini\\antigravity\\mcp_config.json', 'label' => __( 'Windows (IDE)', 'emcp-tools' ) ), ), 'template' => "{\n \"mcpServers\": {\n \"%NAME%\": {\n \"command\": \"npx\",\n \"args\": [\n \"-y\",\n \"mcp-remote\",\n \"%ENDPOINT%\"\n ]\n }\n }\n}", ); @@ -4213,7 +4215,7 @@ class EMCP_Tools_Admin { 'label' => __( 'Antigravity', 'emcp-tools' ), 'icon' => 'editor-code', 'image' => 'antigravity.png', - 'methods' => array( 'bundle' => false, 'cli' => null, 'ai_prompt' => false, 'json' => array( 'http' ) ), + 'methods' => array( 'bundle' => false, 'cli' => null, 'ai_prompt' => false, 'json' => array( 'antigravity-http' ) ), 'oauth' => $oauth_antigravity, ), array( diff --git a/mcp-config-examples.json b/mcp-config-examples.json index 8789aa3..358d86b 100644 --- a/mcp-config-examples.json +++ b/mcp-config-examples.json @@ -110,6 +110,18 @@ } }, + "antigravity_direct_http": { + "_description": "Antigravity (IDE / CLI) — direct HTTP connection (add to ~/.gemini/config/mcp_config.json or ~/.gemini/antigravity/mcp_config.json)", + "mcpServers": { + "emcp-tools": { + "serverUrl": "https://your-site.com/wp-json/mcp/emcp-tools-server", + "headers": { + "Authorization": "Basic BASE64_OF_USERNAME:APP_PASSWORD" + } + } + } + }, + "mcp_inspector_wpcli": { "_description": "MCP Inspector — test and debug tools via WP-CLI", "_command": "npx @modelcontextprotocol/inspector wp mcp-adapter serve --server=emcp-tools-server --user=admin --path=/path/to/wordpress"