{"data":{"slug":"superagent-ai-superagent","name":"superagent","tagline":"Superagent protects your AI applications against prompt injections, data leaks, and harmful outputs. Embed safety directly into your app and prove compliance to your customers.","github_url":"https://github.com/superagent-ai/superagent","owner":"superagent-ai","repo":"superagent","owner_avatar_url":"https://avatars.githubusercontent.com/u/152537519?v=4","primary_language":"TypeScript","stars":6669,"forks":963,"topics":["ai","anthropic","guardrails","llm","openai","prompt-injection","security"],"archived":false,"github_pushed_at":"2026-04-11T08:34:31+00:00","maintenance_label":"Slowing","url":"https://www.graphcanon.com/tools/superagent-ai-superagent","markdown_url":"https://www.graphcanon.com/tools/superagent-ai-superagent.md","api_url":"https://www.graphcanon.com/api/graphcanon/tools/superagent-ai-superagent","graph_url":"https://www.graphcanon.com/api/graphcanon/graph?tool=superagent-ai-superagent","description":"Superagent protects your AI applications against prompt injections, data leaks, and harmful outputs. Embed safety directly into your app and prove compliance to your customers.","homepage_url":"https://superagent.sh","license":"MIT","open_issues":9,"watchers":59,"ai_summary":null,"readme_excerpt":"<p align=\"center\">\n  <img src=\"logo.png\" width=\"80\" alt=\"Superagent\" />\n</p>\n\n<h1 align=\"center\">Superagent SDK</h1>\n\n<p align=\"center\">\n  <strong>Make your AI apps safe.</strong>\n</p>\n\n<p align=\"center\">\n  <a href=\"https://superagent.sh\">Website</a> ·\n  <a href=\"https://docs.superagent.sh\">Docs</a> ·\n  <a href=\"https://discord.gg/spZ7MnqFT4\">Discord</a> ·\n  <a href=\"https://huggingface.co/superagent-ai\">HuggingFace</a>\n</p>\n\n<p align=\"center\">\n  <img src=\"https://img.shields.io/badge/Y%20Combinator-Backed-orange\" alt=\"Y Combinator\" />\n  <img src=\"https://img.shields.io/github/stars/superagent-ai/superagent?style=social\" alt=\"GitHub stars\" />\n  <img src=\"https://img.shields.io/badge/license-MIT-blue\" alt=\"MIT License\" />\n</p>\n\n---\n\nAn open-source SDK for AI agent safety. Block prompt injections, redact PII and secrets, scan repositories for threats, and run red team scenarios against your agent.\n\n## Features\n\n### Guard\n\nDetect and block prompt injections, malicious instructions, and unsafe tool calls at runtime.\n\n**TypeScript:**\n\n```typescript\nimport { createClient } from \"safety-agent\";\n\nconst client = createClient();\n\nconst result = await client.guard({\n  input: userMessage\n});\n\nif (result.classification === \"block\") {\n  console.log(\"Blocked:\", result.violation_types);\n}\n```\n\n**Python:**\n\n```python\nfrom safety_agent import create_client\n\nclient = create_client()\n\nresult = await client.guard(input=user_message)\n\nif result.classification == \"block\":\n    print(\"Blocked:\", result.violation_types)\n```\n\n### Redact\n\nRemove PII, PHI, and secrets from text automatically.\n\n**TypeScript:**\n\n```typescript\nconst result = await client.redact({\n  input: \"My email is john@example.com and SSN is 123-45-6789\",\n  model: \"openai/gpt-4o-mini\"\n});\n\nconsole.log(result.redacted);\n// \"My email is <EMAIL_REDACTED> and SSN is <SSN_REDACTED>\"\n```\n\n**Python:**\n\n```python\nresult = await client.redact(\n    input=\"My email is john@example.com and SSN is 123-45-6789\",\n    model=\"openai/gpt-4o-mini\"\n)\n\nprint(result.redacted)\n# \"My email is <EMAIL_REDACTED> and SSN is <SSN_REDACTED>\"\n```\n\n### Scan\n\nAnalyze repositories for AI agent-targeted attacks such as repo poisoning and malicious instructions.\n\n**TypeScript:**\n\n```typescript\nconst result = await client.scan({\n  repo: \"https://github.com/user/repo\"\n});\n\nconsole.log(result.result);  // Security report\nconsole.log(`Cost: $${result.usage.cost.toFixed(4)}`);\n```\n\n**Python:**\n\n```python\nresult = await client.scan(repo=\"https://github.com/user/repo\")\n\nprint(result.result)  # Security report\nprint(f\"Cost: ${result.usage.cost:.4f}\")\n```\n\n### Test\n\nRun red team scenarios against your production agent. *(Coming soon)*\n\n```typescript\nconst result = await client.test({\n  endpoint: \"https://your-agent.com/chat\",\n  scenarios: [\"prompt_injection\", \"data_exfiltration\"]\n});\n\nconsole.log(result.findings);  // Vulnerabilities discovered\n```\n\n## Get Started\n\nSign up at [superagent.sh](https://superagent.sh) to get your API key.\n\n**TypeScript:**\n\n```bash\nnpm install safety-agent\n```\n\n**Python:**\n\n```bash\nuv add safety-agent\n```\n\n**Set your API key:**\n\n```bash\nexport SUPERAGENT_API_KEY=your-key\n```\n\n## Integration Options\n\n| Option | Description | Link |\n|--------|-------------|------|\n| **TypeScript SDK** | Embed guard, redact, and scan directly in your app | [sdk/typescript](sdk/typescript/README.md) |\n| **Python SDK** | Embed guard, redact, and scan directly in Python apps | [sdk/python](sdk/python/README.md) |\n| **CLI** | Command-line tool for testing and automation | [cli](cli/README.md) |\n| **MCP Server** | Use with Claude Code and Claude Desktop | [mcp](mcp/README.md) |\n\n## Why Superagent SDK?\n\n- **Works with any model** — OpenAI, Anthropic, Google, Groq, Bedrock, and more\n- **Open-weight models** — Run Guard on your infrastructure with 50-100ms latency\n- **Low latency** — Optimized for runtime use\n- **Open source** — MIT license with full transparency\n\n## Open-Weight Models\n\nRun Guard on your own infrastructure. No API","github_created_at":"2023-05-10T18:50:39+00:00","created_at":"2026-07-11T10:46:42.068045+00:00","updated_at":"2026-07-11T10:46:50.645711+00:00","categories":[{"slug":"ai-agents","name":"AI Agents","url":"https://www.graphcanon.com/categories/ai-agents","markdown_url":"https://www.graphcanon.com/categories/ai-agents.md","api_url":"https://www.graphcanon.com/api/graphcanon/categories/ai-agents"},{"slug":"llm-frameworks","name":"LLM Frameworks","url":"https://www.graphcanon.com/categories/llm-frameworks","markdown_url":"https://www.graphcanon.com/categories/llm-frameworks.md","api_url":"https://www.graphcanon.com/api/graphcanon/categories/llm-frameworks"},{"slug":"inference-serving","name":"Inference & Serving","url":"https://www.graphcanon.com/categories/inference-serving","markdown_url":"https://www.graphcanon.com/categories/inference-serving.md","api_url":"https://www.graphcanon.com/api/graphcanon/categories/inference-serving"}],"tags":[{"slug":"prompt-injection","name":"prompt-injection"},{"slug":"llm","name":"llm"},{"slug":"ai","name":"ai"},{"slug":"security","name":"security"},{"slug":"openai","name":"openai"},{"slug":"typescript","name":"typescript"},{"slug":"anthropic","name":"anthropic"},{"slug":"guardrails","name":"guardrails"}],"trust":{"provenance":{"is_fork":false,"github_id":639096757,"owner_type":"Organization","methodology":"github_public_v1","parent_repo":null,"near_duplicate_slugs":[]},"computed_at":"2026-07-11T10:46:42.657Z","maintenance":{"label":"Slowing","score":36,"methodology":"github_public_v1","releases_90d":0,"days_since_push":91,"last_release_at":"2025-09-14T06:34:49Z"},"security_summary":{"status":"no_lockfile","scanner":null,"low_count":0,"high_count":0,"last_scan_at":"2026-07-11T10:46:46.234Z","medium_count":0,"scan_profile":"none","critical_count":0}},"capability_facts":{"scan":{"source":"repo_scan","observed_at":"2026-07-11T10:46:45.846Z"},"languages":{"value":["typescript"],"source":"github.language","observed_at":"2026-07-11T10:46:45.846Z"},"license_spdx":{"value":"MIT","source":"github.license","observed_at":"2026-07-11T10:46:45.846Z"}}}}