# API

Beans offers a comprehensible and very easy to use API to help integrate with your custom online store.&#x20;

#### Storefront Integration&#x20;

The storefront integration helps you integrate Beans on your online store. This script will display information to your customers (for example the loyalty program page) and also track customers' interactions (for example tracking referrals).

[Add Beans to Storefront](broken://pages/-MDyw4cx84C4zV6fn3LA)

#### Webhooks Integration

Webhooks are a simple way for Beans to be notified when a new event happens in your store (for example when a customer completes an order). They are used by Beans to perform event-based actions such as rewarding a customer after a purchase.&#x20;

[Setup Beans Webhooks](/integrations/api/webhooks.md)


---

# Agent Instructions: 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:

```
GET https://help.trybeans.com/integrations/api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
