Skip to content
| Marketplace
Sign in
Visual Studio Code>AI>SAP OData MCP ServerNew to Visual Studio Code? Get it now.
SAP OData MCP Server

SAP OData MCP Server

harieprasad

|
3 installs
| (0) | Free
SAP OData MCP server installer and GitHub Copilot agents/skills for SAP development - automatically deploys to workspace
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

SAP OData MCP

A VS Code extension that automatically deploys SAP OData MCP server configuration, GitHub Copilot agents, and skills for enhanced SAP OData development with AI assistance.

Features

✨ Automatic Workspace Setup

  • Auto-deploy on folder open: Automatically deploys MCP configuration and files when you open any workspace folder
  • Zero configuration: No manual commands needed - works out of the box
  • Per-workspace MCP config: Each workspace gets its own local .vscode/mcp.json configuration
  • Version-aware: Only updates files when a newer version is available
  • Automatic path updates: MCP executable path is updated automatically when the extension is updated or moved

📁 What Gets Automatically Deployed

To Each Workspace:

  • .vscode/mcp.json - Local MCP server configuration with SAP connection parameters
  • AGENTS.md - Index of available Copilot agents and workspace rules
  • .github/agents/ - 3 specialized SAP OData agent definition files
  • .github/skills/ - 2 skill folders with SAP OData V2/V4 query and write workflows

🚀 Available Agents & Skills

  • 3 specialized SAP OData agents: Architect (orchestrator), Explorer (read/discovery), Write Agent (POST/PATCH/DELETE)
  • 2 SAP OData skills: Query workflow (V2/V4 filter/expand/select), Write workflow (payload construction, deep insert)
  • 9 MCP tools: Query, count, create, update, delete, service discovery, metadata fetch, SAP Help search, SAP Help fetch

Requirements

  • Windows OS: This extension only works on Windows (MCP server is a Windows executable)
  • VS Code 1.99.0 or higher
  • GitHub Copilot: Required for agent and skill functionality
  • SAP System Access: Network access to your SAP OData V2 (Gateway) or V4 (RAP) system

Quick Start

  1. Install the extension:

    code --install-extension sap-odata-mcp-1.2.0.vsix
    
  2. Open any workspace folder then run the initialization command:

    Ctrl+Shift+P → SAP OData MCP: Initialize Workspace
    
  3. Enter your SAP credentials in the 5-step wizard — URL, username, password, client, SSL setting.

  4. Your .vscode/mcp.json is created automatically:

    {
      "servers": {
        "sap-odata": {
          "type": "stdio",
          "command": "C:\\Users\\...\\sap-odata-mcp.exe",
          "env": {
            "SAP_ODATA_HOST": "https://your-sap-system:44300",
            "SAP_ODATA_USER": "your_username",
            "SAP_ODATA_PASSWORD": "your_password",
            "SAP_ODATA_CLIENT": "100",
            "SAP_ODATA_VERIFY_SSL": "true"
          }
        }
      }
    }
    
  5. Reload VS Code to activate the MCP server.

  6. Start using Copilot with SAP OData-specific agents and skills:

    @SAP OData Architect find all open purchase orders for vendor 1000
    @SAP OData Architect create a new sales order with line items
    @SAP OData Architect show me all services related to material master
    

Manual Initialization

If you need to force a re-initialization or update files manually:

  1. Press Ctrl+Shift+P
  2. Type: SAP OData MCP: Initialize Workspace
  3. Follow the credential wizard

This is useful when:

  • Auto-deployment didn't work
  • You want to update your SAP credentials
  • You manually deleted files and want to restore them

Configuration

The initialization wizard automatically creates .vscode/mcp.json in your workspace. Do not edit the command field — it is managed automatically on every VS Code startup.

SAP Connection Parameters

Required Parameters:

  • SAP_ODATA_HOST: Your SAP system base URL (format: https://hostname:port)
  • SAP_ODATA_USER: Your SAP username (dialog user with OData authorization)
  • SAP_ODATA_PASSWORD: Your SAP password
  • SAP_ODATA_CLIENT: SAP client number (e.g., "100")
  • SAP_ODATA_VERIFY_SSL: "true" to verify SSL, "false" for self-signed certs (dev only)

Optional Parameters:

  • SAP_ODATA_SAP_MODE: "true" for SAP Gateway/RAP, "false" for generic OData (default: "true")
  • SAP_ODATA_PROXY: HTTP proxy URL (format: http://proxy.company.com:8080)
  • SAP_ODATA_PROXY_USER: Proxy authentication username
  • SAP_ODATA_PROXY_PASSWORD: Proxy authentication password

Security Notes

⚠️ Important: Storing passwords in mcp.json is not secure for production use. Consider:

  • Restricting file permissions on .vscode/mcp.json
  • Adding .vscode/mcp.json to .gitignore
  • Using a read-only SAP technical user

Commands

Access commands via Command Palette (Ctrl+Shift+P):

  • SAP OData MCP: Initialize Workspace - Deploy all files and configure SAP credentials in one step

Available Agents

After installation, you will have access to these specialized agents:

SAP OData Architect (invoke with @SAP OData Architect)

Top-level orchestrator with a dual persona — speaks OData V2/V4 terminology with developers, and plain business language with end users. Delegates read tasks to the Explorer and write tasks to the Write Agent. Enforces safety rules: always fetches $metadata first, never auto-selects when multiple services match, shows full payload before any write operation.

SAP OData Explorer (sub-agent — read & discovery)

Expert in discovering and querying SAP OData services. Searches V2 (Gateway) and V4 (RAP) catalogs simultaneously, fetches and analyses $metadata XML, builds version-correct $filter / $expand / $select / $orderby / $search expressions, and falls back to SAP Help Portal on any error.

SAP OData Write Agent (sub-agent — POST / PATCH / DELETE)

Expert in write operations. Runs a mandatory deep-insert check before every create (scans NavigationProperty elements, asks if you want header-only or header + children in one call). Constructs payloads entirely from metadata — never guesses field names or types. Handles V2 vs V4 payload format differences and CSRF token acquisition automatically.

Available Skills

Skills are loaded automatically by agents based on the operation type:

  • sap-odata-query - End-to-end query workflow: service discovery, metadata analysis, version-correct $filter/$expand/$select building, pagination, and error recovery via SAP Help
  • sap-odata-write - Write workflow: payload construction from metadata, V2/V4 format rules, deep insert patterns, required vs read-only field identification, write error recovery

How It Works

First Workspace Open

  1. Extension activates on VS Code startup
  2. Detects workspace folders
  3. For each new workspace (no .vscode/mcp.json found):
    • Launches the Initialize Workspace wizard
    • Copies AGENTS.md and .github/ folder to workspace root
    • Creates .vscode/mcp.json with the exe path and your SAP credentials

Subsequent Workspace Opens

  1. Extension finds existing .vscode/mcp.json
  2. Silently updates only the command field to the current exe path
  3. All your env credentials are preserved untouched

Extension Updates

  1. MCP server path is automatically updated to the new extension location on next startup
  2. No manual reconfiguration needed after updating the extension

MCP Tools Reference

The MCP server exposes 9 tools used automatically by the agents:

Tool Purpose
odata_query Read entities with $filter, $expand, $select, $orderby, $top, $skip
odata_count Count records without fetching data
odata_create POST — create a new entity
odata_update PATCH — partially update an existing entity by key
odata_delete DELETE — remove an entity by key
odata_search_service Search V2 + V4 service catalogs simultaneously by keyword
odata_fetch_metadata Fetch $metadata XML — source of truth for all field names and types
sap_help_search Search help.sap.com for official SAP documentation
sap_help_get Fetch the full content of a SAP Help article

Troubleshooting

MCP Server Not Working

  1. Verify .vscode/mcp.json exists in your workspace root
  2. Check the command field points to a valid .exe file
  3. Verify SAP credentials (SAP_ODATA_HOST, SAP_ODATA_USER, SAP_ODATA_PASSWORD) are correct
  4. Check network access to your SAP system
  5. Reload VS Code: Ctrl+Shift+P → Developer: Reload Window

Workspace Files Not Deploying

  1. Check the workspace folder is writable
  2. Run manual command: SAP OData MCP: Initialize Workspace
  3. Check Output panel for errors: View → Output → SAP OData MCP

SSL Certificate Errors

  1. Set SAP_ODATA_VERIFY_SSL to "false" in .vscode/mcp.json (development only)
  2. Or switch to HTTP: SAP_ODATA_HOST=http://sap-system:8000

Platform Errors

  • This extension only works on Windows
  • Mac/Linux users will see an error on activation

Log Files

MCP server logs are written automatically to:

  1. %APPDATA%\Code\User\sap-odata-mcp-logs\sap-odata-mcp-YYYYMMDD.log
  2. Or %TEMP%\sap-odata-mcp-logs\ as fallback

Version History

1.2.0

  • Initial release
  • MCP server auto-configuration with one-command initialization
  • Auto-deployment of agents, skills, and workspace rules
  • 3 specialized SAP OData agents (Architect, Explorer, Write Agent)
  • 2 SAP OData development skills (query, write)
  • 9 MCP tools for SAP OData V2 and V4

Credits & Acknowledgments

SAP Help Portal search tools (sap_help_search, sap_help_get) are based on the excellent work of:

  • mcp-sap-docs by Marian Zeis - SAP documentation MCP server

The core MCP server (sap-odata-mcp.exe) is licensed under Apache 2.0.

License

MIT License - see LICENSE file for details.

Copyright (c) 2026 HariePrasad

Support

For issues and feature requests, please open an issue on the GitHub repository.

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.


Note: This extension requires GitHub Copilot subscription and access to an SAP OData system (V2 Gateway or V4 RAP).

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft