Skip to main content

Model Context Protocol (MCP) server for OpenFGA

Project description

OpenFGA MCP Server

An experimental Model Context Protocol (MCP) server that enables Large Language Models (LLMs) to read, search, and manipulate OpenFGA stores. Unlocks authorization for agentic AI, and fine-grained vibe coding✨ for humans.

Requirements

Features

Tools

  • check: Check if a user has a relation to an object
  • list_objects: List objects of a type that a user has a relation to
  • list_relations: List relations for which a user has a relation to an object
  • list_users: List users that have a given relationship with a given object

Resources

Prompts

Usage

We recommend running the server using UVX:

uvx openfga-mcp@latest

Configuration

The server accepts the following arguments:

  • --openfga_url: URL of your OpenFGA server
  • --openfga_store: ID of the OpenFGA store the MCP server will use
  • --openfga_model: ID of the OpenFGA authorization model the MCP server will use

For API token authentication:

  • --openfga_token: API token for use with your OpenFGA server

For Client Credentials authentication:

  • --openfga_client_id: Client ID for use with your OpenFGA server
  • --openfga_client_secret: Client secret for use with your OpenFGA server
  • --openfga_api_issuer: API issuer for use with your OpenFGA server
  • --openfga_api_audience: API audience for use with your OpenFGA server

For example:

uvx openfga-mcp@latest \
  --openfga_url="http://127.0.0.1:8000" \
  --openfga_store="your-store-id" \
  --openfga_model="your-model-id"

Using with Claude Desktop

To configure Claude to use this server, add the following to your Claude config:

{
    "mcpServers": {
        "openfga-mcp": {
            "command": "uvx",
            "args": [
                "openfga-mcp@latest",
            ]
        }
    }
}
  • You may need to specify the full path to your uvx executable. Use which uvx to find it.
  • You must restart Claude after updating the configuration.

Using with Raycast

Using with Cursor

Using with Windsurf

Development

To setup your development environment, run:

uv sync

To run the development server:

uv run openfga-mcp

License

Apache 2.0

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

openfga_mcp-0.1.0.tar.gz (90.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

openfga_mcp-0.1.0-py3-none-any.whl (10.4 kB view details)

Uploaded Python 3

File details

Details for the file openfga_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: openfga_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 90.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.5.25

File hashes

Hashes for openfga_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 8a3b39b6ec6c3a6e4dce3135fc3849815791dfc443c2b449be9b6e7cf9a8bf70
MD5 790bad4ff0b94719031f49470ae32ddf
BLAKE2b-256 5f275bf51f0dd8e5a042bf5422ec301ad7856820a6a56444b78a2c8b4517f479

See more details on using hashes here.

File details

Details for the file openfga_mcp-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for openfga_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 27d2f7b4d14f5a4859af7af9e675be34d10bcce68f741f9ae4b80b2ffb26b50c
MD5 e4d2a9877576ecf21df7579399eff47c
BLAKE2b-256 1b54eda4b474b18e42e82de1f407c04d75c3b6747a34447c920386c369c3b9b5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page