# Webhooks

### 🔍 What Are Webhooks?

Webhooks let you **trigger instant token buys through Bitfoot Bot** from external systems – without interacting with Telegram.

You can use them to:

* Connect your **alpha feed or trading bot**
* Automate buys from other alpha scanners, bots or Discord channels
* Trigger trades from your own scripts or alerts

> Perfect for users who want full automation and speed.

***

### ⚙️ How to Set Up and Use a Webhook

1. Open the[ **Bitfoot Bot** ](https://t.me/BitFootBot)on Telegram
2. Tap ⚡️ **Webhooks** in the main menu
3. Tap ➕ **Add Webhook** to create a new one
4. Enter a name (e.g. `myAlphaFeed`)

After creation, Bot will respond with:

* An **Access Token** (used to authorize requests):

<div align="left"><figure><img src="https://3111015691-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlwujP2ZYsEWYqnEdNMKG%2Fuploads%2FZ5BCs9ZGaHVxxJLrqW5O%2Fobrazek.png?alt=media&#x26;token=d124b845-9ba8-48fb-9196-055e7e6793ac" alt=""><figcaption></figcaption></figure></div>

* A unique **Webhook URL** (used to send requests):

<div align="left"><figure><img src="https://3111015691-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlwujP2ZYsEWYqnEdNMKG%2Fuploads%2F4dDEZAKXyZYpAAPegIhQ%2Fobrazek.png?alt=media&#x26;token=09c1c94d-08d5-4fa0-a57e-1ca6c99eb1ca" alt=""><figcaption></figcaption></figure></div>

* A default configuration (slippage, limits, wallets, etc.)

***

### 🛠 Webhook Configuration Explained

Each webhook has its own config panel directly in Telegram:

| Setting                | Description                                                               |
| ---------------------- | ------------------------------------------------------------------------- |
| **Max Amount**         | Limits how much USD can be used per trade                                 |
| **Max Webhook Calls**  | Number of total allowed calls (max: 1000)                                 |
| **Slippage**           | Default slippage % if not defined in request                              |
| **Min/Max Liquidity**  | Optional filters for token Liquidity                                      |
| **Min/Max Market Cap** | Optional filters for token MC                                             |
| **Priority Fee**       | Default priority fee (SOL or GWEI)                                        |
| **Max Priority Fee**   | Safety limit – higher values are rejected                                 |
| **Selected Wallets**   | Chain-specific wallets used to perform the swaps                          |
| **Enabled Chains**     | Chains where this webhook can trigger trades (SOL, ETH, BSC, Base, Sonic) |

> You don’t need to pass these values in every request – Bitfoot uses your webhook’s config as default.

**Make sure to:**

* ✅ Enable **Auto Buys**
* ✅ Select **Trigger Chains** (e.g. Solana)
* ✅ Connect wallets for the chains you want to use

***

### 🔗 Connecting Bitfoot Webhook to Other Tools

#### ✅ Any Alpha Bot or External Signal Tool

If you use any alpha feed, auto-caller, or trading signal tool that supports webhook output:

1. Create a webhook in Bitfoot Bot
2. Copy your **Webhook URL** and **Access Token**
3. In your external tool:
   * Go to the alert/filter/query you want to automate
   * Paste the Webhook URL in its webhook section
   * Provide your **Access Token** (usually as Bearer token or field)

> Done. Whenever the tool fires a signal, Bitfoot will handle the buy.

***

#### 🧪 Manual Testing (curl)

To test your webhook manually:

```
curl --request POST \
  --url https://api-app.bitfoot.com/webhook/YOUR_WEBHOOK_ID \
  --header 'Content-Type: application/json' \
  --header 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
  --data '{
    "network": "solana",
    "token_address": "TOKEN_ADDRESS_HERE",
    "amount_usd": 1,
    "priority_fee": 0.0001
  }'
```

**Required Fields:**

* `network`: solana / eth / bsc / base / sonic
* `token_address`: address of the token to buy
* `amount_usd`: (optional) how much to buy
* `priority_fee`: (optional) fee in SOL or GWEI

Bitfoot will respond with:

```
{
  "status": "success",
  "error": "",
  "data": ["transaction_hash_here"]
}
```

***

### 🔄 What Happens When Call Limit Is Reached?

Each webhook has a maximum of **1000 calls**.

Once reached:

* The webhook is **disabled**
* Any new requests will return an error: `maximum amount of calls reached`
* You need to create a **new webhook** to continue

> Replacing the webhook in your script or bot is required.

***

### 🧠 Pro Tips / Additional Notes

* You can have **multiple webhooks** (for different chains, strategies or tools)
* You can always tap `📎 Get Request Example` in the bot to see your exact `curl` command
* The webhook will only execute on **networks where you have wallets connected**
* Use `amount_usd` and `priority_fee` in request only if you want to override defaults
* You can use webhook with custom bots, Discord signals, scanners, Zapier, etc.

***

### ❓Still have questions?&#x20;

Contact [Support](mailto:support@bitfoot.com) or ask [Bitfoot team on X](https://x.com/BitfootBot) 👣
