# Block and allow AI agents

> Choose which AI agents can use your store. Everything is allowed until you block it, and people are never blocked.

Every store starts with every agent **allowed**. You block the ones you do not want; people are never blocked.

## The agents you can switch

| Agent | ID | Vendor |
|---|---|---|
| ChatGPT | `chatgpt` | OpenAI |
| ChatGPT search | `openai-search` | OpenAI |
| OpenAI training | `openai-training` | OpenAI |
| Claude | `claude` | Anthropic |
| Claude search | `claude-search` | Anthropic |
| Claude training | `claude-training` | Anthropic |
| Gemini (in testing) | `gemini` | Google |
| Perplexity (in testing) | `perplexity` | Perplexity |
| Dia (in testing) | `dia` | The Browser Company |
| Browser agents | `browser-agents` | unbranded |
| Other crawlers | `other-crawlers` | unbranded |
| Scripts and scrapers | `scripts` | unbranded |
| Fake AI visitors | `fake-agents` | unbranded |

The IDs are what the [API](/docs/api) uses.

The old `openai-crawlers` and `claude-crawlers` IDs still work. Each old ID applies the same choice to both its search and training rules.

## Change a rule

1. Open [/app](https://tryostia.com/app) > **Block or allow**.
2. Flip the switch for each agent.
3. Check the preview and click **Save rules**.

Rules reach your store within about a minute.

## What a blocked agent gets

| Install | What the blocked agent sees |
|---|---|
| Cloudflare worker | an HTTP 403 with a short plain-text note: this store does not accept visits from this automated agent |
| WordPress / WooCommerce plugin | the same HTTP 403 and note, before the page renders |
| Shopify app | the same 403 on the app's own pages (agent cart, product feed, store facts). Your theme pages are served by Shopify, so rules do not reach them; put the store behind Cloudflare for that |
| Script tag / theme tag (watch only) | your normal page: the tag never changes what anyone sees, so rules are not enforced there |

People always get your normal site. Search engines (Google, Bing, Apple and the like) always get your normal site too: no rule applies to them. If our service cannot be reached, everyone is allowed: a rule never takes your store down.

## Search and AI answers

Blocking training keeps those crawlers from using your pages for model training without removing the pages from ChatGPT or Claude search. Blocking a search rule can keep your products out of AI answers and AI search. Block shopping agents only if you are sure you do not want those orders. A common setup: allow ChatGPT, Claude and their search rules; block training, scripts, scrapers and fake AI visitors.

## Platform notes

- **Cloudflare and WordPress / WooCommerce:** full protection. Both enforce the /app switches on every page. The plugin's **Mode** (Observe only / On) only controls its agent features.
- **Shopify:** watch plus rules on our app's own pages (the app is coming). For full blocking, run the store behind Cloudflare.
- **Any other site (script tag):** watch only.

## By API

```sh
curl -X PUT https://tryostia.com/api/v1/stores/<site-id>/rules \
  -H "Authorization: Bearer agt_..." -H "content-type: application/json" \
  -d '{"rules": {"scripts": "block", "fake-agents": "block"}}'
```

Needs a token with write access. See [the API reference](/docs/api).

Source: https://tryostia.com/docs/rules
