# SAS Viya (MCP server)

> SAS Viya is an MCP server that adds developer tools to AI assistants such as Claude Desktop, Claude Code and Cursor. Execute SAS code and query Compute, CAS, and model APIs on SAS Viya via OAuth… It has 62 GitHub stars, is released under the Apache-2.0 license and runs locally with docker run -i --rm -e VIYA_ENDPOINT ghcr.io/sassoftware/sas-mcp-server:1.18.0.

A Model Context Protocol (MCP) server for executing SAS code, training AutoML projects, scoring models and so much more for SAS Viya environments.

## Key facts

| Fact | Value |
|---|---|
| Repository | https://github.com/sassoftware/sas-mcp-server |
| GitHub stars | 62 |
| License | Apache-2.0 |
| Language | Python |
| Transport | stdio |
| Packages | docker: ghcr.io/sassoftware/sas-mcp-server:1.18.0 |
| Remote URL | none |
| Needs API key | no |
| Official | yes |
| Works with | Claude Desktop, Claude Code, Cursor, VS Code |
| Category | Developer tools |
| Latest release | v1.18.0 (Sep 29, 2026) |
| Last commit | Sep 29, 2026 |
| MCP registry name | io.github.sassoftware/sas-mcp-server |

## Install

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "sas-viya": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "VIYA_ENDPOINT",
        "ghcr.io/sassoftware/sas-mcp-server:1.18.0"
      ],
      "env": {
        "VIYA_ENDPOINT": "your-value"
      }
    }
  }
}
```

Settings > Developer > Edit Config. macOS: ~/Library/Application Support/Claude/, Windows: %APPDATA%\Claude\. Restart Claude Desktop afterwards.

### Claude Code

```sh
claude mcp add --env VIYA_ENDPOINT=your-value --transport stdio sas-viya -- docker run -i --rm -e VIYA_ENDPOINT ghcr.io/sassoftware/sas-mcp-server:1.18.0
```

### Cursor (.cursor/mcp.json)

```json
{
  "mcpServers": {
    "sas-viya": {
      "type": "stdio",
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "VIYA_ENDPOINT",
        "ghcr.io/sassoftware/sas-mcp-server:1.18.0"
      ],
      "env": {
        "VIYA_ENDPOINT": "your-value"
      }
    }
  }
}
```

Project file; use ~/.cursor/mcp.json to enable it in every project.

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "sas-viya": {
      "type": "stdio",
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "VIYA_ENDPOINT",
        "ghcr.io/sassoftware/sas-mcp-server:1.18.0"
      ],
      "env": {
        "VIYA_ENDPOINT": "your-value"
      }
    }
  }
}
```

Config formats checked against the official docs on 2026-10-07.

## Environment variables

- `VIYA_ENDPOINT` (required): Base URL of your SAS Viya environment, e.g. https://viya.example.com. No trailing slash.
- `SSL_VERIFY`: Set false only for a self-signed Viya certificate. Disables verification for the whole process, so prefer a trusted certificate.
- `CLIENT_ID`: SASLogon OAuth client id used for the token refresh exchange.
- `COMPUTE_CONTEXT_NAME`: Compute context that backs SAS code execution.
- `MCP_TIERS`: Expose only some tool tiers, e.g. 0-4 or 0,1,7. Empty exposes all 92 tools. Tiers: 0 Compute, 1 Data Discovery, 2 Data Operations, 3 Reports, 4 Batch Jobs, 5…
- `MCP_READ_ONLY`: Expose only tools that neither change server-side state nor cause server-side work (51 of 92). Composes with MCP_TIERS.
- `MCP_APPS`: Register interactive views (MCP Apps) for the data, SAS log and glossary tools. Additive: text-only clients are unaffected. Set false to register none.
- `MCP_STATELESS_HTTP`: Serve HTTP requests without an MCP session. Needed by clients that speak only the sessionless 2026-07-28 protocol revision (claude.ai custom connectors); the…
- `VIYA_CLIENT_TIMEOUT`: Timeout in seconds for every SAS Viya REST call the tools make.

## Tools

- `execute_sas_code`: Execute SAS code snippets and retrieve execution results (log and listing output), plus a link to the HTML results…
- `list_compute_contexts`: List available compute contexts
- `reset_compute_session`: Delete the cached compute session for a context, discarding its SAS state and forcing a fresh session on the next call
- `catalog_search`: Search the catalog for assets (tables, columns, reports, …) using the SAS catalog search grammar (free text, facets…
- `catalog_search_helper`: Discover how to query the catalog — list the available facets, or the valid values for one facet — so you can build…
- `catalog_find_instance`: Resolve the catalog instance for a source-asset resourceuri, bridging a search hit to the profiling and download tools…
- `catalog_run_adhoc_analysis`: Submit an ad-hoc profiling job for a table. NLP enrichment (language, sentiment, semantic IDs) is on by default,…
- `catalog_get_adhoc_analysis`: Poll a profiling job and cross-check the target instance, reporting profileready once results have landed on the asset…
- `catalog_download_table_profile`: Download a table's data dictionary and column profile as CSV, identified by either instanceid or resourceuri.
- `catalog_list_agents`: List the catalog's discovery agents (the crawlers that populate metadata).
- `catalog_run_agent`: Start a discovery agent run (asynchronous) to crawl its data source and refresh catalog metadata.
- `catalog_get_agent_history`: Inspect an agent's run history — status and how much metadata each run enumerated/added/updated/removed.
- `list_cas_servers`: List available CAS servers
- `list_caslibs`: List CAS libraries on a server
- `list_castables`: List tables in a CAS library
- `list_source_tables`: List source tables not yet loaded into memory (candidates for promotion)
- `get_castable_info`: Get table metadata (row count, columns, size)
- `get_castable_columns`: Get column names, types, labels, formats
- `get_castable_data`: Fetch sample rows from a CAS table
- `query_data`: Run a FedSQL SELECT against CAS or compute data and get the rows back — one SQL surface over both storage tiers.
- `list_compute_libraries`: List the SAS libraries (librefs) assigned in a compute context
- `list_compute_tables`: List the tables in a SAS library within a compute context
- `list_compute_columns`: List the columns of a table in a SAS library
- `get_compute_table_data`: Fetch a page of rows from a table in a SAS library, values formatted as SAS displays them — the compute-tier…
- `upload_data`: Upload a data file into a CAS table — read server-side so the data never passes through the model's context — from…
- `upload_inline_data`: Create a small CAS table from inline csv/tsv text passed as a string (a lookup/mapping table the model builds on the…
- `promote_table_to_memory`: Load a source table into memory at global scope (idempotent)
- `list_files`: List files in the Viya Files Service
- `upload_file`: Upload a file to the Viya Files Service, optionally into a Content folder (parentfolderuri).
- `download_file`: Download file content
- `list_reports`: List Visual Analytics reports
- `get_report`: Get report metadata and definition
- `export_report`: export a report (or specific report objects) in any format the VA service supports — package (zip), pdf, png, svg,…
- `describe_report_objects`: Discover what a report can contain — the eight report operations and every addable object (bar chart, list table, geo…
- `create_report`: Create a Visual Analytics report and return its id. Optionally pass an operations array to build the whole report in…
- `apply_report_operations`: The authoring workhorse — apply an ordered batch of native VA operations (addData, addPage, addObject, updateObject,…
- `get_report_outline`: Read a report's structure back — pages → objects with the handles the other tools need (object name for…
- `copy_report`: Copy a report to a new one (optionally renaming/refoldering). Pairs with a changeData operation for the…
- `delete_report`: Delete a report and its content.
- `submit_batch_job`: Submit a SAS job for async execution

## Similar MCP servers

- [Gemini CLI](https://appsgit.com/mcp-servers/gemini-cli): An open-source AI agent that brings the power of Gemini directly into your terminal. (107,240 stars, Apache-2.0)
- [Front-End Checklist](https://appsgit.com/mcp-servers/front-end-checklist): Review frontend code and live pages against 386 quality-gated web development rules. (74,390 stars, MIT)
- [Claude Flow](https://appsgit.com/mcp-servers/claude-flow): AI orchestration with hive-mind swarms, neural networks, and 87 MCP tools for enterprise dev. (74,016 stars, MIT, needs API key)
- [Codebase Memory](https://appsgit.com/mcp-servers/codebase-memory): Codebase knowledge graph for AI agents — 162 languages, sub-ms queries, 99% fewer tokens. (45,917 stars, MIT)
- [Bytedance Filesystem](https://appsgit.com/mcp-servers/bytedance-filesystem): MCP server for filesystem access. (39,206 stars, Apache-2.0)
- [GitHub](https://appsgit.com/mcp-servers/github): Connect AI assistants to GitHub - manage repos, issues, PRs, and workflows through natural language. (33,414 stars, MIT, official, needs API key)

---

Canonical page: https://appsgit.com/mcp-servers/sas-viya
Source: appsgit (https://appsgit.com), the app store for github. Data from the GitHub API, refreshed nightly.
Machine access: JSON API https://appsgit.com/api/v1/apps (OpenAPI: https://appsgit.com/openapi.json), MCP server https://mcp.appsgit.com/mcp, full index https://appsgit.com/llms-full.txt.
