Aira
Integrations

Framework integrations

First-class SDK integrations for LangChain, Vercel AI, OpenAI Agents, AWS Bedrock, Google ADK, CrewAI, and MCP. Each is honestly labeled gate, audit, or adapter.

Aira ships first-class integrations for every major agent framework. Each one is honestly labeled — we tell you exactly whether it's a real pre-execution gate, an audit-only recorder, or an API adapter, and why.

These labels are not marketing — they're pinned by tests. The SDK source of truth is an INTEGRATIONS registry in each SDK (Python, TypeScript) that CI verifies matches the actual code.

The three kinds of integration

gate — pre-execution interception

The framework exposes a public hook point that runs BEFORE the underlying side effect and can throw to abort. Aira wraps that hook, calls authorize(), and raises on denial. Denied actions never run.

audit — post-hoc recording

The framework has no upstream pre-execution hook that can abort. Aira's callback runs after the action has already executed. You get a signed receipt but not a gate. For real gating on an audit-classified framework, you call aira.authorize() directly inside your tool bodies. Today this is only CrewAI.

adapter — Aira exposed as tools

The integration exposes Aira's own API as tools the host framework can call. The Aira MCP server is the example — an MCP-aware agent can invoke authorize_action and notarize_action via MCP. Whether that becomes a real gate depends on whether the host honors the contract.

Matrix

IntegrationKindPre-execution gate?What it wrapsSDK
IntegrationKindGate?SurfaceSDK
LangChain

LangChain

gateon_tool_start / on_tool_endPython · TypeScript
Vercel

Vercel AI SDK

gatewrapTool() around a tool's executeTypeScript
OpenAI

OpenAI Agents

gateTool guardrail wrapperPython · TypeScript
AWS

AWS Bedrock

gateinvoke_model + invoke_agent wrappersPython
Google

Google ADK

gatebefore_tool_call plugin hookPython
CrewAI

CrewAI

audittask_callback + step_callback (post-hoc)Python
MCP

MCP

adapterN/AServer that exposes Aira as MCP toolsPython · TypeScript

Install

Each extra is a dependency group on the SDK package:

pip install aira-sdk[langchain]
pip install aira-sdk[openai-agents]
pip install aira-sdk[bedrock]
pip install aira-sdk[google-adk]
pip install aira-sdk[crewai]
pip install aira-sdk[mcp]
# Everything is in the base package — sub-imports pull
# in peer deps only when you import them.
npm install aira-sdk

Import from a subpath:

import { AiraCallbackHandler } from "aira-sdk/extras/langchain";
import { AiraVercelMiddleware } from "aira-sdk/extras/vercel-ai";
import { AiraGuardrail } from "aira-sdk/extras/openai-agents";
import { createServer } from "aira-sdk/extras/mcp";

The common pattern every gate uses

Under the hood, every gate integration does the same thing:

# Conceptually — every gate collapses to this
def wrap(fn):
    def wrapped(*args, **kwargs):
        try:
            auth = aira.authorize(
                action_type="tool_call",
                details=_describe(args, kwargs),
                agent_id=AGENT_ID,
            )
        except AiraError as e:
            raise  # POLICY_DENIED → never runs

        if auth.status == "pending_approval":
            raise  # held for human → never runs

        try:
            result = fn(*args, **kwargs)
        except Exception as e:
            aira.notarize(auth.action_uuid, outcome="failed", outcome_details=str(e))
            raise

        aira.notarize(auth.action_uuid, outcome="completed", outcome_details=str(result))
        return result
    return wrapped

The differences between integrations are just where the framework lets us plug in:

  • LangChain → BaseCallbackHandler.on_tool_start
  • Vercel AI → replace the tool's execute function
  • OpenAI Agents → guardrail + tool wrapper
  • Bedrock → replace boto3_client.invoke_model
  • Google ADK → before_tool_call plugin hook

When an upstream framework doesn't have a spot to plug in (CrewAI), we say so and document the workaround.

No lock-in

Every gate uses the framework's own public hook — BaseCallbackHandler, wrapTool(), before_tool_call, invoke_model. We don't fork LangChain, patch OpenAI Agents, or ship a CrewAI fork. Upgrading your framework is a normal pip install --upgrade, not a rebuild of the Aira layer.

Next steps

Pick the integration that matches your stack and read its dedicated guide:

  • LangChain — the most common path for Python agents
  • Vercel AI SDK — the standard for TypeScript agents on Vercel
  • OpenAI Agents — if you're using OpenAI's official agent SDK
  • AWS Bedrock — gate every Bedrock model and agent invocation
  • Google ADK — Vertex / Gemini agents
  • CrewAI — audit-only, with the inline-gate workaround documented
  • MCP — expose Aira to any MCP-aware agent including Claude Desktop

On this page