> For the complete documentation index, see [llms.txt](https://docs.usepylon.com/pylon-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.usepylon.com/pylon-docs/ai-agents/build/bring-your-own-agent.md).

# Bring Your Own Agent

An alternative to building an agent directly in Pylon is to bring your own custom agent.

### First Party

If you are developing an in-house agent, you can connect the agent directly into your Pylon workflows using one of several approaches.

**Runbooks**

If you'd like to combine Pylon's agent with your own agent (for example, have Pylon's agent just handle simple questions and orchestration), you can use [Runbooks](/pylon-docs/ai-agents/build/runbooks.md). You can specify handoffs from Pylon's agent to your agent via. custom actions.

**Webhooks, APIs, and MCP**

Using a combination of [Webhooks](/pylon-docs/developer/webhooks.md), [API](/pylon-docs/developer/api.md), and/or [Pylon MCP](/pylon-docs/integrations/pylon-mcp.md), you can connect your agent to ticketing workflows in Pylon.

For example, you can setup webhooks to listen for new issues, messages, and other ticket events and post replies or make metadata changes via. API.

### Third Party

A number of third party agents directly integrate with Pylon. If you're already using an agent that you'd like to connect into Pylon, please reach out directly to your account rep for help getting the connection setup.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.usepylon.com/pylon-docs/ai-agents/build/bring-your-own-agent.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
