> For the complete documentation index, see [llms.txt](https://docs.guayaba.run/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.guayaba.run/documentation/api-guide/editor.md).

# API Introduction

The Guayaba Public API lets you create, manage, and chat with your AI agents programmatically — no web UI needed.

### Base URL

```
https://api.guayaba.run/api/v1
```

All endpoints are relative to this base URL.

### Quick Start

#### 1. Create an API key

Go to **Settings → API Keys** in the [Guayaba dashboard](https://app.guayaba.run/) and create a **Master Key**.

#### 2. List your agents

```
curl https://api.guayaba.run/api/v1/agents \
  -H "Authorization: Bearer g_master_YOUR_KEY"
```

#### 3. Start an agent

```
curl -X POST https://api.guayaba.run/api/v1/agents/{id}/start \
  -H "Authorization: Bearer g_master_YOUR_KEY"
```

#### 4. Chat with your agent

```
curl -X POST https://api.guayaba.run/api/v1/agents/{id}/chat \
  -H "Authorization: Bearer g_master_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"message": "Hello, what can you do?"}'
```

### Requirements

* An active Guayaba subscription (any tier).
* At least one API key (Master or Agent).
* Sufficient credits for billed operations.
