Skip to main content

AgentR

AgentR is a Python framework for building MCP servers to serve agentic applications and LLM clients. It provides a clean abstraction for incorporating various API services as "applications" into your agent workflow.

🌟 Features

  • MCP (Model Context Protocol) Integration: Seamlessly works with MCP server architecture
  • Simplified API Integration: Connect to services like GitHub, Google Calendar, Gmail, Reddit, Tavily, and more with minimal code
  • Managed Authentication: Built-in support for API keys and OAuth-based authentication flows
  • Extensible Architecture: Easily build and add new app integrations with minimal boilerplate
  • Credential Management: Flexible storage options for API credentials with memory and environment-based implementations

🔧 Installation

Install AgentR using pip:

pip install agentr

🚀 Quick Start

1. Get an API Key

Before using AgentR with services that require authorization (like GitHub, Gmail, etc.), you'll need an AgentR API key:

Visit https://agentr.dev to create an account Generate an API key from your dashboard Set it as an environment variable or include it directly in your code:

export AGENTR_API_KEY="your_api_key_here"

2. Create a basic server

from agentr.server import TestServer

# Define your applications list
apps_list = [
    {
        "name": "tavily",
        "integration": {
            "name": "tavily_api_key",
            "type": "api_key",
            "store": {
                "type": "environment",
            }
        },        
    },
    {
        "name": "zenquotes",
        "integration": None
    },
    {
        "name": "github",
        "integration": {
            "name": "github",
            "type": "agentr",
        }
    }
]

# Create a server with these applications
server = TestServer(name="My Agent Server", description="A server for my agent apps", apps_list=apps_list)

# Run the server
if __name__ == "__main__":
    server.run()

🧩 Available Applications

AgentR comes with several pre-built applications:

Application Description Authentication Type
GitHub Star repositories and more OAuth (AgentR)
Google Calendar Retrieve calendar events OAuth (AgentR)
Gmail Send emails OAuth (AgentR)
Reddit Access Reddit data OAuth (AgentR)
Resend Send emails via Resend API API Key
Tavily Web search capabilities API Key
ZenQuotes Get inspirational quotes None

Note: More applications are coming soon! Stay tuned for updates to our application catalog.

🔐 Integration Types

AgentR supports two primary integration types:

1. API Key Integration

For services that authenticate via API keys:

{
    "name": "service_name",
    "integration": {
        "name": "service_api_key",
        "type": "api_key",
        "store": {
            "type": "environment",  # or "memory"
        }
    }
}

2. OAuth Integration (via AgentR)

For services requiring OAuth flow:

{
    "name": "service_name",
    "integration": {
        "name": "service_name",
        "type": "agentr"
    }
}

When using OAuth integrations, users will be directed to authenticate with the service provider through a secure flow managed by AgentR.

🤖 CLI Usage

AgentR includes a command-line interface for common operations:

# Get version information
agentr version

# Generate API client from OpenAPI schema
agentr generate --schema path/to/openapi.yaml

# Run the test server
agentr run

# Install AgentR for specific applications
agentr install claude

📋 Requirements

  • Python 3.11+
  • Dependencies (automatically installed):
    • loguru >= 0.7.3
    • mcp >= 1.5.0
    • pyyaml >= 6.0.2
    • typer >= 0.15.2

📝 License

This project is licensed under the MIT License.

Release files for agentr 0.1.9

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for agentr 0.1.9
File Size Uploaded
agentr-0.1.9.tar.gz 42.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for agentr 0.1.9
File Interpreter ABI Platform
agentr-0.1.9-py3-none-any.whl Python 3 none any Details

Total release size: 77.6 kB

Release files / agentr-0.1.9.tar.gz

Download URL agentr-0.1.9.tar.gz
Size 42.0 kB
Tags Source
SHA-256 checksum
How to use checksums
6380cc8731ba236d44dbdd484dc64140097ccc7de54f5be42917c1a9f3f332d7
BLAKE2b-256 checksum
How to use checksums
526ed1a9678c72816845a56a2447010cb765b9a90a98eb4af0dc94ad00218e64
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.6.2

Release files / agentr-0.1.9-py3-none-any.whl

Download URL agentr-0.1.9-py3-none-any.whl
Size 35.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5dca628ed66f653f8180188403dc8620ff8884a2ce161fa34836efa9e4014579
BLAKE2b-256 checksum
How to use checksums
13384aae25242814ed0652620c2380f610c5d439c056db17155e29859024ee88
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.6.2

Release history Release notifications | RSS feed

This release

0.1.9 This release

2 release files

0.1.8

2 release files

0.1.7

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page