RulesGraph API documentation

A typed graph of cybersecurity compliance frameworks, exposed as a REST API and an MCP server. Free tier is 600 requests per minute. Free read access for everything in the graph.

Quickstart

Three steps from zero to a working query:

  1. Get an API key. Sign up with an email and confirm via the magic link. Takes about 60 seconds.
  2. Set RG_KEY in your environment.
  3. Make a request:
bash
# List every control in NIST SP 800-53 Rev 5
curl -H "X-API-Key: $RG_KEY" \
  "https://api.rulesgraph.com/v1/controls?framework=nist-sp-800-53-r5&limit=10"

Authentication

Every authenticated request needs an X-API-Key: <key> header. An Authorization: Bearer <key> header is also accepted, which is the convention the MCP server uses. Keys are issued via the signup flow and can be regenerated or revoked from the account page.

Tip: A small number of read endpoints work without a key (the viewer's bootstrap data, for example). Anything programmatic should send a key so it's properly counted against your rate-limit bucket.

Rate limits

Free tier: 600 requests per minute, sliding window. Headers on every response tell you where you stand:

response headers
X-RateLimit-Limit:     600
X-RateLimit-Remaining: 593
X-RateLimit-Reset:     2026-05-23T11:48:00Z

Higher tiers are available for GRC platforms and high-volume integrations. Email contact@rulesgraph.com.

Response shape

List endpoints return { "data": [...], "count": N }. Single-resource endpoints return the resource directly. Every object carries provenance fields so any query result is independently verifiable:

GET /v1/controls/nist-800-53-r5-ac-1
{
  "id": "nist-800-53-r5-ac-1",
  "framework": "nist-sp-800-53-r5",
  "control_id": "AC-1",
  "title": "Policy and Procedures",
  "family": "Access Control",
  "layer": 1,
  "status": "live",
  "provenance": {
    "source_url": "https://csrc.nist.gov/pubs/sp/800/53/r5/final",
    "fetched_at": "2026-04-12T03:14:22Z",
    "content_hash": "sha256:8f1b2...",
    "plan_cid": "bafyrei...g4"
  }
}

Controls

Individual compliance controls, normalised across frameworks. Every control is a node in the graph with typed edges to its dependents, cross-mappings, and predecessor versions.

GET/v1/controlsList controls
ParameterDescription
frameworkoptionalFilter by framework ID (e.g. nist-sp-800-53-r5, iso-27001-2022, soc2-tsc-2017).
familyoptionalFilter by control family (e.g. Access Control, Cryptography).
layeroptionalFilter by layer (1 through 7).
statusoptionalOne of live, planned, candidate, reference.
limitoptionalPage size, default 50, max 500.
GET/v1/controls/:idFetch a single control

Returns the full control object including text, family, layer, status, and provenance.

GET/v1/controls/:id/maps_toCross-mapped controls in other frameworks
GET /v1/controls/soc2-cc6.1/maps_to
{
  "data": [
    {
      "target": "nist-800-53-r5-ac-3",
      "target_framework": "nist-sp-800-53-r5",
      "strength": "strong",
      "direction": "bidirectional",
      "source": "aicpa-2022-tsc-mapping"
    },
    {
      "target": "iso-27001-2022-a-5-15",
      "target_framework": "iso-27001-2022",
      "strength": "partial"
    }
  ],
  "count": 2
}

Frameworks

The top-level umbrella objects. ISO 27001, NIST CSF, SOC 2, PCI DSS, and so on. Each framework groups its controls and points to its publishing source.

GET/v1/frameworksList frameworks
GET/v1/frameworks/:idFetch a framework
GET/v1/frameworks/:id/controlsEvery control in a framework
GET /v1/frameworks/iso-27001-2022
{
  "id": "iso-27001-2022",
  "name": "ISO/IEC 27001:2022",
  "publisher": "ISO/IEC",
  "layer": 1,
  "published": "2022-10-25",
  "control_count": 93,
  "supersedes": "iso-27001-2013",
  "provenance": { "source_url": "https://www.iso.org/standard/82875.html" }
}

Cross-mappings

Typed edges between controls in different frameworks. The mapping table is computed by the pipeline and continuously validated against authoritative crosswalks (AICPA, NIST OLIR, Secure Controls Framework, OSCAL libraries).

GET/v1/mappingsList mappings
ParameterDescription
from_frameworkoptionalSource framework filter.
to_frameworkoptionalTarget framework filter.
strengthoptionalOne of strong, partial, weak.

Sources

The publishing bodies whose feeds the pipeline crawls. Standards bodies (Tier A), regulators (Tier B), control catalogs (Tier C).

GET/v1/sourcesList active sources
GET/v1/sources/:idSource details + last fetch info

Revisions

Every snapshot the pipeline has captured. Use this to diff a framework over time or build a webhook that fires on changes you care about.

GET/v1/revisionsRecent revisions across all sources
GET/v1/revisions/:idSingle revision with full diff

Stats

GET/v1/statsLive graph counts

Returns the same numbers shown on the homepage: total controls, frameworks, edges, sources. Useful for status dashboards.

Viewer

The browser-based viewer at rulesgraph.com/viewer is a thin client over this API. Each tab maps to a question a compliance operator actually asks.

#overview
Headline stats, top frameworks by cross-mapping density, recent activity. The landing surface; learn what is in the graph in fifteen seconds.
#coverage
Square heatmap, frameworks on both axes, cells coloured by mapping count. Click any cell for the underlying mappings table with per-edge citations.
#control
Pick a control, see it across every framework. Force-directed cross-mapping web with edge colour encoding relation type. Backed by /v1/methodologies/:id/dependencies.
#compliance
Pick frameworks you have (left), pick a target (right). The graph computes the three-way split: covered, partial, gap. Shows the specific frameworks that would close the gap.
#frameworks
Browse every framework in the catalogue. Filter by layer or jurisdiction. Click any row to walk into the control deep-dive.
#activity
Reverse-chronological timeline of publisher releases, regulator enforcements, and ingestions into the graph. Backed by /v1/revisions/recent.

Every tab is hash-routable. Share or bookmark any of these to land directly:

deep links
https://rulesgraph.com/viewer#overview
https://rulesgraph.com/viewer#coverage
https://rulesgraph.com/viewer#control:nist-sp800-53-r5
https://rulesgraph.com/viewer#compliance
https://rulesgraph.com/viewer#frameworks
https://rulesgraph.com/viewer#activity

The viewer hits the same /v1/* endpoints documented above using your saved API key (paste it via the top-right key bar). Demo key is rate-limited; sign up for your own at /signup.

MCP server

RulesGraph runs a Model Context Protocol server at mcp.rulesgraph.com. Plug it into Claude Desktop, Cursor, Windsurf, or any MCP-compatible agent.

Connecting from Claude Desktop

~/.../claude_desktop_config.json
{
  "mcpServers": {
    "rulesgraph": {
      "url": "https://mcp.rulesgraph.com",
      "auth": { "bearer": "$RG_MCP_KEY" }
    }
  }
}

Available tools

Note: The MCP server is the paid tier. Free tier covers REST access; MCP access is metered separately. Email contact@rulesgraph.com for an MCP key.

Error codes

StatusCodeMeaning
400bad_requestRequest malformed or missing required parameters.
401unauthorizedMissing or invalid API key.
403forbiddenKey valid but not authorised for this resource.
404not_foundResource doesn't exist or has been deprecated.
429rate_limitedSliding-window quota exceeded. Retry after the time in Retry-After.
500internal_errorServer-side issue. If persistent, please report.

Changelog

Breaking changes are versioned via the URL prefix (/v1/, /v2/, …). Non-breaking additions are announced here and via the JSON changelog.

Questions or feedback? Email contact@rulesgraph.com. We read everything.