Mcp Ory Kratos — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited Mcp Ory Kratos (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
MCP server enabling AI assistants to manage Ory Kratos identities, sessions, and authentication flows. Built for developers integrating identity management into Claude Code, GitHub Copilot, or Gemini CLI workflows.
Note: Kratos deployment and configuration is out of scope for this MCP server. See the Ory Kratos documentation for deployment guidance.
Install via npm or run directly with npx:
# Using npm
npm install -g mcp-ory-kratos
# Using npx (no installation required)
npx mcp-ory-kratos
# Using bun
bun add -g mcp-ory-kratos| Variable | Required | Default | Description |
|---|---|---|---|
KRATOS_ADMIN_URL | Yes | - | Kratos Admin API base URL (e.g., http://localhost:4434) |
KRATOS_AUTH_TYPE | No | none | Authentication type: none, api-key, or custom-headers |
KRATOS_API_KEY | Conditional | - | Required when KRATOS_AUTH_TYPE=api-key |
KRATOS_CUSTOM_HEADERS | Conditional | - | JSON object of headers when KRATOS_AUTH_TYPE=custom-headers |
KRATOS_TIMEOUT_MS | No | 30000 | Request timeout in milliseconds |
LOG_LEVEL | No | info | Log level: trace, debug, info, warn, error |
Note: This MCP server can run alongside other MCP servers in your configuration. Each server operates independently.
Add to ~/.claude.json for global configuration:
{
"mcpServers": {
"kratos": {
"type": "stdio",
"command": "npx",
"args": ["-y", "mcp-ory-kratos"],
"env": {
"KRATOS_ADMIN_URL": "http://localhost:4434"
}
}
}
}For project-scoped configuration, create .mcp.json in your project root:
{
"mcpServers": {
"kratos": {
"type": "stdio",
"command": "npx",
"args": ["-y", "mcp-ory-kratos"],
"env": {
"KRATOS_ADMIN_URL": "http://localhost:4434"
}
}
}
}Create .vscode/mcp.json in your workspace:
{
"servers": {
"kratos": {
"type": "stdio",
"command": "npx",
"args": ["-y", "mcp-ory-kratos"],
"env": {
"KRATOS_ADMIN_URL": "http://localhost:4434"
}
}
}
}For secrets handling with input variables:
{
"inputs": [
{
"type": "promptString",
"id": "kratos-url",
"description": "Kratos Admin API URL",
"password": false
}
],
"servers": {
"kratos": {
"type": "stdio",
"command": "npx",
"args": ["-y", "mcp-ory-kratos"],
"env": {
"KRATOS_ADMIN_URL": "${input:kratos-url}"
}
}
}
}Add to ~/.gemini/settings.json for global configuration:
{
"mcpServers": {
"kratos": {
"command": "npx",
"args": ["-y", "mcp-ory-kratos"],
"env": {
"KRATOS_ADMIN_URL": "http://localhost:4434"
}
}
}
}For project-scoped configuration, create .gemini/settings.json in your project:
{
"mcpServers": {
"kratos": {
"command": "npx",
"args": ["-y", "mcp-ory-kratos"],
"env": {
"KRATOS_ADMIN_URL": "http://localhost:4434"
}
}
}
}Choose your MCP client from the Configuration section above and add the appropriate configuration.
Start your MCP client and verify the tools are available:
/mcp to see available serversAsk your AI assistant:
"List all identities in Kratos"
The MCP server will execute kratos_list_identities and return the results.
| Tool | Description |
|---|---|
kratos_list_identities | List identities with optional filtering by credential identifier (e.g., email) |
kratos_get_identity | Get detailed information about a specific identity by ID |
kratos_get_identity_by_external_id | Look up identity by external identifier |
kratos_create_identity | Create a new identity with schema, traits, and optional metadata |
kratos_update_identity | Full update of an identity (replaces all fields) |
kratos_patch_identity | Partial update using JSON Patch operations |
kratos_delete_identity | Permanently delete an identity and all associated data |
kratos_delete_identity_credential | Delete a specific credential type from an identity |
| Tool | Description |
|---|---|
kratos_list_sessions | List all sessions with optional filtering by active status |
kratos_get_session | Get session details by ID |
kratos_list_identity_sessions | List all sessions for a specific identity |
kratos_disable_session | Revoke/disable a session (log user out) |
kratos_extend_session | Extend session expiration time |
kratos_delete_identity_sessions | Delete all sessions for an identity |
| Tool | Description |
|---|---|
kratos_list_courier_messages | List emails/SMS sent by Kratos with delivery status |
kratos_get_courier_message | Get courier message details including delivery attempts |
| Tool | Description |
|---|---|
kratos_create_recovery_link | Generate account recovery link for a user |
kratos_create_recovery_code | Generate account recovery code for a user |
| Tool | Description |
|---|---|
kratos_session_analytics | Aggregated session statistics (auth methods, devices, browsers) |
kratos_credential_analytics | Authentication method adoption statistics and MFA rates |
| Tool | Description |
|---|---|
kratos_health_alive | Check if Kratos server is alive and accepting requests |
kratos_health_ready | Check if Kratos is ready (database connectivity, dependencies) |
kratos_version | Get Kratos server version |
List all identities in KratosFind the identity with email [email protected]Is Kratos healthy and ready?Show all active sessions in KratosWhat authentication methods are users using? Show session analytics.Create a recovery link for user with ID abc-123Symptom: ECONNREFUSED or connection timeout errors
Solutions:
curl http://localhost:4434/health/aliveKRATOS_ADMIN_URL is correct (use Admin API port, typically 4434)Symptom: Authentication errors when calling Kratos API
Solutions:
KRATOS_AUTH_TYPE=api-keyKRATOS_API_KEY with a valid API keyKRATOS_AUTH_TYPE=custom-headers with KRATOS_CUSTOM_HEADERSSymptom: MCP client doesn't show Kratos tools
Solutions:
npx mcp-ory-kratos manually to verify the server startsSymptom: Requests timeout before completing
Solutions:
KRATOS_TIMEOUT_MS (default: 30000ms)# Clone the repository
git clone https://github.com/feedback-loop-ai/mcp-ory-kratos.git
cd mcp-ory-kratos
# Install dependencies
bun install
# Start the MCP server
bun run start# Lint (Biome)
bun run lint
bun run lint:fix # Auto-fix issues
# Type check
bun x tsc --noEmit
# Run unit tests
bun x vitest run --config tests/vitest.config.ts --dir tests/unit
# Run all tests (requires Kratos - see .env.test.local.example)
bun run test
# Run tests with coverage
bun run test -- --coverage.enabledContributions are welcome! Please follow these steps:
git checkout -b feature/my-feature)bun run lint && bun run test)git commit -m 'Add my feature')git push origin feature/my-feature)If you find this project useful, consider sponsoring its development:
Your support helps maintain and improve the MCP Ory Kratos server.
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.