> ## Documentation Index
> Fetch the complete documentation index at: https://handlebar.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Connecting your agent

> How to enable Handlebar on your agents

Connect Handlebar through framework-specific SDKs,
which plug directly into agents however they're configured.
Only a couple of simple lines of code are required to set Handlebar up,
and no need to rewrite your agent, prompts, flow, or tools.

## Handlebar Platform

Before you begin, make sure you have access to the Handlebar platform.
You can sign up for a free account at [https://app.gethandlebar.com](https://app.gethandlebar.com).
Handlebar is currently operating a waitlist.
To get access, get in touch with us at [contact@gethandlebar.com](mailto:contact@gethandlebar.com)
and we'll send you an invite code for you and your team.

Once you have access,
you will need to create an API key so that your agents can interact with the Handlebar API.
Go to `/org/<your-org>/settings` (**Settings** button in the left sidebar),
then click to create a new API key.
**Important:** You won't be able to see the key again, so make sure to copy it somewhere safe.
When setting up your agents (instructions below),
you will need to set this key in the `HANDLEBAR_API_KEY` environment variable.

## Agent Frameworks

*We're actively developing our support for more AI and agent building frameworks.
If you need support for tooling not listed here,
please get in touch with us at [contact@gethandlebar.com](mailto:contact@gethandlebar.com).*

Handlebar provides core support for integrating with agents built in Python and JavaScript/TypeScript.
These core packages can be plugged into the lifecycle of your agent, for any framework or self-built.

Handlebar additionally provides out-of-the-box integrations with popular frameworks like Vercel AI and Google Assistant, which require only a few lines of configuration in code.

### Claude code skill to setup Handlebar

We've provided a Claude Code skill that will analyse your agent and configure Handlebar for you.
Simply run

```bash theme={null}
npx skills add gethandlebar/agent-skills
```

and run the `/handlebar-setup` skill while in your agent's codebase to get started.

N.b. you can find our agent skills at [https://github.com/gethandlebar/agent-skills](https://github.com/gethandlebar/agent-skills)

### Framework integration guides

Read more about how to integrate Handlebar with your agent in one of the following guides.
Note that Handlebar currently only support JS/TS and Python agents.

<Columns cols={2}>
  <Card title="Vercel AI" icon="link" href="/integrations/vercel-agents" arrow="true" cta="Click here" />

  <Card title="Langchain" icon="link" href="/integrations/langchain-agents" arrow="true" cta="Click here" />

  <Card title="Google ADK" icon="link" href="/integrations/google-adk-agents" arrow="true" cta="Click here" />

  <Card title="Custom Python" icon="link" href="/integrations/custom-python-integration" arrow="true" cta="Click here" />

  <Card title="Custom Javascript" icon="link" href="/integrations/custom-javascript-integration" arrow="true" cta="Click here" />
</Columns>

## How the Handlebar SDKs work

Handlebar provides SDKs which wrap the various agent building frameworks
you know and love,
providing agent governance with just a couple lines of code.

### Audit logs

The Handlebar SDKs monitor agent actions
(e.g. user prompts, llm responses, tool calls, tool responses)
and emits logs to the Handlebar API asynchronously.
On Handlebar, the agent audit logs are **immutable**,
presenting a source of truth for the actions your agent took.

### Rules

Rules, policies and interventions
are currently configured
on the Handlebar platform
and loaded onto the SDK
at runtime using your Handlebar API key
and provided agent identity.

Rules are evaluated client-side,
making them fast, robust, and minimising data transfer.
Rules are evaluated by intercepting tool calls
the agent is attempting to make.
If there is a violation, the SDK
will exit the agent's tool call process
or throw an error to finish the execution run completely,
depending on what action is configured for the rule
(e.g. `block` vs. `hitl`)
and the specifics of the agent framework you're using.

## Viewing agent logs

Once you've connected your agents to Handlebar,
the next time it runs logs will be automatically be sent to the Handlebar platform.
To view them,
in the Handlebar platform head to the **Agents** page by clicking the button in the left sidebar,
then select the agent you want to view logs for.
You will see recent runs for that agent,
which you can dive deeper into by clicking on the run.
