home / mcp / oscal mcp server

OSCAL MCP Server

Provides OSCAL models, schemas, and templates to AI assistants via MCP stdio with bundled content.

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "awslabs-mcp-server-for-oscal": {
      "command": "uvx",
      "args": [
        "--from",
        "mcp-server-for-oscal@latest",
        "server"
      ],
      "env": {
        "ENVIRONMENT": "development"
      }
    }
  }
}

You run a lightweight MCP server that provides OSCAL tooling to AI assistants locally. It connects via stdio using a predefined MCP configuration, bundles all necessary OSCAL content, and verifies content integrity at startup for security and reliability.

How to use

You interact with the server through an MCP client that supports the MCP protocol. Start the local server from your IDE or CLI, then configure your AI assistant to connect via the standard input/output channel. Once connected, you can query available OSCAL models, request schema details, and generate minimal OSCAL mappings or templates. The server’s built-in content is self-contained and does not require external network calls for its default tools.

In practice, you typically perform these actions with your MCP client: - Discover available OSCAL models and resources - Retrieve OSCAL schemas for specific models - Generate minimal, valid OSCAL templates or mappings for quick starts - Explore open OSCAL catalogs and example mappings to accelerate your workflows.

How to install

Prerequisites:
- Python 3.11+ or a compatible runtime environment for the MCP server package
- A Python package manager (pip) or your preferred Python tooling
- A compatible MCP client that supports the MCP stdio transport (for example kiro-cli or Claude desktop integrations)

Install and run the MCP server locally using the runtime command shown in configuration examples. The server is designed to run with a simple stdio MCP setup.

{
  "mcpServers": {
    "oscal": {
      "command": "uvx",
      "args": ["--from", "mcp-server-for-oscal@latest", "server"],
      "env": {
      }
    }
  }
}

Configuration and usage notes

Configure your MCP client to load the stdio server with the exact command and arguments shown in the example configuration. You can customize environment variables in the env object if needed for development or integration, though the default setup shows an empty environment.

Security and integrity

The server bundles all required OSCAL content and includes manifest hashes for file integrity verification. On startup, it checks the bundled content against the manifest. If any content hash does not match, startup will fail to protect you from tampered content.

Examples and templates

You can use the included tools to learn about OSCAL models, generate templates, and discover catalogs. The typical flow is to query what models exist, inspect a mapping or schema, and then create a minimal OSCAL template you can customize.

Troubleshooting

If startup fails due to content integrity, stop and re-check the bundled manifests. Ensure you are running with the exact command and arguments shown in the configuration example. If your MCP client cannot connect, verify that the stdio channel is correctly wired and that the server process is running in the expected environment.

Available tools

get_oscal_schema

Fetches the JSON schema for a specified OSCAL model to understand its structure.

list_oscal_models

Lists available OSCAL models across the OSCAL schema, grouped by layer and status.

list_oscal_resources

Discovers open source OSCAL catalogs and resources available to browse or import.

generate

Generates a minimal, valid OSCAL template or mapping template based on a selected model schema.

write

Writes generated templates or mappings to a file for further customization.

query_oscal_documentation

Queries documentation endpoints to fetch guidance or usage notes for OSCAL concepts.