> For the complete documentation index, see [llms.txt](https://daddy-studios.gitbook.io/daddy-studios-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://daddy-studios.gitbook.io/daddy-studios-docs/scripts/daddy-marketplace/configuration/webhooks.md).

# Discord Webhooks

Every marketplace event can be logged to Discord. Each log type has its own webhook, so you can split them across channels — or leave a URL empty to disable that log.

```lua
Config.Webhooks = {
    enabled   = true,
    botName   = 'Daddy Marketplace',
    botAvatar = '',

    listing    = '',    -- new listings/auctions, cancellations, featured purchases
    purchase   = '',    -- purchases
    bid        = '',    -- auction bids
    auctionEnd = '',    -- auction results
    offer      = '',    -- offers made / accepted
    buyOrder   = '',    -- buy orders created / filled / cancelled
    admin      = '',    -- admin moderation commands

    colors = {          -- embed colors, decimal
        listing    = 3447003,
        purchase   = 5763719,
        bid        = 16776960,
        auctionEnd = 15548997,
        offer      = 10181046,
        buyOrder   = 15105570,
        admin      = 10038562,
    },
}
```

## Setting one up

1. In Discord: **Server Settings → Integrations → Webhooks → New Webhook**.
2. Pick the channel and copy the webhook URL.
3. Paste it into the matching field in `Config.Webhooks`.
4. `restart daddy-marketplace`.

`enabled = false` turns off every log at once without clearing your URLs.

{% hint style="warning" %}
A webhook URL is a write key to that channel. Never put it in a public repository or share a config file that still contains one.
{% endhint %}

## Colours

`colors` are decimal, not hex. Convert a hex colour by dropping the `#` and reading it as base 16 — `#3498DB` becomes `3447003`.

## Queueing

Messages are queued and sent with a delay between them, so a busy market cannot hit Discord's rate limit and lose logs. Nothing is dropped when several events happen in the same second; they simply arrive one after the other.

## What gets logged

| Webhook      | Events                                                                          |
| ------------ | ------------------------------------------------------------------------------- |
| `listing`    | A listing or auction is created or cancelled, a featured highlight is purchased |
| `purchase`   | Something is bought, including partial purchases and cart checkouts             |
| `bid`        | Every auction bid                                                               |
| `auctionEnd` | Auction results: winner, price, or no bids                                      |
| `offer`      | Offers made, accepted, rejected and countered                                   |
| `buyOrder`   | Buy orders created, filled and cancelled                                        |
| `admin`      | Every `/marketplaceadmin` action, with the admin's name and server id           |

The `admin` log is the one worth keeping even if you disable the rest — it is your record of who removed what.

## Next steps

* [Security](/daddy-studios-docs/scripts/daddy-marketplace/configuration/security.md)
* [Commands & Permissions](/daddy-studios-docs/scripts/daddy-marketplace/commands-and-permissions.md)


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://daddy-studios.gitbook.io/daddy-studios-docs/scripts/daddy-marketplace/configuration/webhooks.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
