# Search traffic (`mttr_traffic`)

Updated October 24, 2026.

## What does mttr_traffic do?

Clicks from search, from Search Console. With a site: clicks by day, the totals against as many days before, and each page’s clicks now against before. Without one: every site, and searches none of them answers. A key may make this call on the sites it has claimed.

Who may call it: Your claimed sites.

## When to use it

- Before and after a change, to have a baseline.
- Traffic fell and you want to know which pages lost it.

## What you ask

You might say: “How has search traffic to example.com moved?”

```
mttr_traffic({})
```

| Argument | Type | Needed | What it is |
| --- | --- | --- | --- |
| `site` | Text | No | The site, as a domain such as example.com. |
| `show` | One of these: lost, gained, all | No | lost (the default), gained, or all pages by clicks. |
| `limit` | Number | No | How many to return. |
| `offset` | Number | No | How many to skip, for the next part of a long list. |

## What comes back

- Clicks by day, and totals against the days before.
- Each page now against before, those that lost most first.
- Only sites whose owner added mttr in Search Console have any.

A sample, with made-up sites and figures:

| Day | Count |
| --- | --- |
| Mon | 41 |
| Tue | 48 |
| Wed | 52 |
| Thu | 45 |
| Fri | 39 |
| Sat | 22 |
| Sun | 26 |

| Total | Now | Before |
| --- | --- | --- |
| Clicks | 273 | 241 |
| Impressions | 9,820 | 9,104 |

## Over HTTP

```
curl "https://mttr.si/api/v1/sites/example.com/traffic" \
  -H "Authorization: Bearer $MTTR_KEY"
```

## When it fails

| When | Status | What to do |
| --- | --- | --- |
| Your assistant has no key yet | 401 over MCP | Sign up with `mttr_signup`, then connect again with the key it gives. |
| The key has not claimed the site | 404 | Claim it with `mttr_claim`, then `mttr_claim_check`. |

## Sources

- [Model Context Protocol: tools](https://modelcontextprotocol.io/specification/2025-06-18/server/tools), Model Context Protocol: How an assistant calls a tool.

The call in full: [mttr_traffic in the API reference](https://mttr.si/docs/reference#mttr_traffic).

## Goes with

- [Searches](https://mttr.si/docs/tools/queries.md)
- [Visits](https://mttr.si/docs/tools/visits.md)
