OpenFGA MCP Server
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@OpenFGA MCP Servercheck if user:alice has viewer relation for document:1 in prod"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
OpenFGA MCP Server
OpenFGA를 위한 Model Context Protocol (MCP) 서버입니다. Claude Code에서 OpenFGA 권한 관리 작업을 수행할 수 있습니다.
기능
스토어 관리: 스토어 목록 조회
모델 관리: Authorization Model 조회/배포
튜플 관리: 권한 관계(튜플) CRUD
권한 체크: Check, ListObjects, Expand
Related MCP server: Azure Omni-Tool MCP Server
설치
npm install
npm run build환경 설정
방법 1: JSON 환경변수 (권장)
export OPENFGA_ENVIRONMENTS='{
"prod": {
"url": "https://openfga.example.com",
"defaultStoreId": "01ABC..."
},
"staging": {
"url": "https://openfga-staging.example.com"
}
}'방법 2: 개별 환경변수
# 각 환경별로 설정
export OPENFGA_PROD_URL="https://openfga.example.com"
export OPENFGA_PROD_STORE_ID="01ABC..."
export OPENFGA_STAGING_URL="https://openfga-staging.example.com"방법 3: 로컬 전용
# 기본값: http://localhost:8080
export OPENFGA_LOCAL_URL="http://localhost:8080"
export OPENFGA_LOCAL_STORE_ID="01XYZ..."Claude Code 설정
프로젝트별 설정 (.claude/settings.json)
{
"mcpServers": {
"openfga": {
"type": "stdio",
"command": "node",
"args": ["/path/to/openfga-mcp/dist/index.js"]
}
},
"env": {
"OPENFGA_ENVIRONMENTS": "{\"prod\":{\"url\":\"https://openfga.example.com\",\"defaultStoreId\":\"01ABC...\"}}"
}
}글로벌 설정 (~/.claude.json)
{
"mcpServers": {
"openfga": {
"type": "stdio",
"command": "node",
"args": ["/path/to/openfga-mcp/dist/index.js"],
"env": {
"OPENFGA_ENVIRONMENTS": "{\"prod\":{\"url\":\"https://openfga.example.com\"}}"
}
}
}
}사용 가능한 도구
도구 | 설명 |
| 스토어 목록 조회 |
| Authorization Model 조회 |
| Authorization Model 배포 (DSL 파일/문자열) |
| 튜플 조회 (필터 지원) |
| 단일 튜플 생성 |
| 여러 튜플 일괄 생성 |
| 튜플 삭제 |
| 권한 체크 |
| 접근 가능한 오브젝트 목록 |
| 권한 트리 확장 |
openfga_model_write
DSL 파일을 OpenFGA에 배포합니다.
요구사항: fga CLI 설치 필요 (설치 가이드)
# macOS
brew install openfga/tap/fga
# 기타
go install github.com/openfga/cli/cmd/fga@latest사용 예시
# 모델 조회
openfga_model_read(env: "prod")
# 모델 배포
openfga_model_write(env: "prod", filePath: "/path/to/model.fga")
# 권한 체크
openfga_check(env: "prod", user: "user:alice", relation: "can_view", object: "document:1")
# 튜플 생성
openfga_tuple_write(env: "prod", user: "user:alice", relation: "viewer", object: "document:1")
# 튜플 배치 생성
openfga_tuple_batch_write(env: "prod", tuples: [
{user: "user:alice", relation: "viewer", object: "document:1"},
{user: "user:bob", relation: "editor", object: "document:1"}
])자연어로도 요청 가능:
prod 환경에서 user:alice가 document:1을 can_view 할 수 있는지 확인해줘Hooks 연동 (선택)
모델 배포 후 설정 파일 자동 업데이트 등의 프로젝트별 작업이 필요하면 Claude Code Hook을 사용하세요:
{
"hooks": {
"PostToolUse": [{
"matcher": "mcp__openfga__openfga_model_write",
"hooks": [{
"type": "command",
"command": "./scripts/post-model-deploy.sh"
}]
}]
}
}Hook 스크립트는 stdin으로 JSON을 받습니다:
{
"tool_name": "mcp__openfga__openfga_model_write",
"tool_output": "모델 배포 완료!\nAuthorization Model ID: 01ABC...\nEnvironment: prod"
}개발
# 소스 수정 후 빌드
npm run build
# 개발 모드 (watch)
npm run dev라이선스
MIT
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
Alicense-qualityAmaintenanceEnables AI assistants to interact with Scalekit's identity and access management platform through natural language queries. Supports managing environments, organizations, users, OIDC connections, workspace operations, and MCP server configurations with OAuth-protected access.Last updated3054Apache 2.0- AlicenseBqualityDmaintenanceEnables intelligent interaction with Azure resources through natural language by translating requests into safe, auditable Azure CLI commands with plan/review workflows and direct access to 8 Azure services including Storage, Cosmos DB, Key Vault, and more.Last updated31MIT
- Alicense-qualityDmaintenanceEnables management of Okta identity platform through natural language, allowing users to perform operations on applications, groups, and users with secure API token authentication.Last updated722MIT

aptible-mcpofficial
Alicense-qualityDmaintenanceEnables interaction with the Aptible API for managing Aptible resources such as accounts, apps, and databases through natural language.Last updatedMIT
Related MCP Connectors
Runtime permission, approval, and audit layer for AI agent tool execution.
Create and manage AI agents that collaborate and solve problems through natural language interacti…
Connect AI assistants to GitHub - manage repos, issues, PRs, and workflows through natural language.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Gyeom/openfga-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server