dotrewards
concept API

Cashback for agents

Give your AI agent a tracked link and a wallet. It shops, the cashback attaches to your account, and you approve every payout.

Base URL
https://api.dotrewards.demo
MCP package
@dotrewards/mcp
create_cashback_link
// Agent calls the MCP tool
create_cashback_link({
  merchant: "booking-com",
  intent: "hotel"
})

// Response
{
  "url": "https://drw.ds/l/…",
  "rate": "Up to 7%",
  "tracked_for": "usr_demo"
}

Get started

Quickstart

Three steps from zero to an agent that earns you cashback.

  1. 1

    Link your agent

    In your account, open Settings → Agents and approve a new agent. You choose its scopes and a spending cap, and get a revocable key.

    terminal
    # Keep it out of source control
    export DOTREWARDS_API_KEY="drk_test_…"
  2. 2

    Add the MCP server

    Point any MCP client at the package, or paste the config from the MCP section. No SDK to install.

    terminal
    npx -y @dotrewards/mcp
  3. 3

    Ask your agent to shop

    The agent calls create_cashback_link before it checks out. Cashback tracks to you automatically.

    Find me a hotel in Lisbon for 3 nights. Use my cashback.
    Created a tracked Booking.com link (up to 7%). Booking now, and your cashback will show as pending.

Model Context Protocol

MCP server

Works with Claude, ChatGPT, Cursor and any client that speaks MCP. Add the dotrewards server to your client's config:

mcp.json
{
  "mcpServers": {
    "dotrewards": {
      "command": "npx",
      "args": ["-y", "@dotrewards/mcp"],
      "env": {
        "DOTREWARDS_API_KEY": "drk_test_…"
      }
    }
  }
}

Tools

  • search_stores

    search_stores({ query, category? })

    Find stores by name, category or shopping intent. Each result carries the current rate and an agent_ready flag.

  • get_rate

    get_rate({ merchant })

    Current cashback rate for one merchant, including any upsized offer.

  • create_cashback_link

    create_cashback_link({ merchant, intent? })

    Returns a tracked link. Cashback attaches to the user who linked the agent.

  • get_wallet

    get_wallet()

    Read-only balance, pending cashback and the per-agent ledger. There is no withdraw tool.

HTTP

REST API

Not using MCP? Call the same endpoints directly. Base URL https://api.dotrewards.demo, authenticated with your agent key as a bearer token.

  • POST/v1/linksCreate a tracked cashback link
  • GET/v1/storesSearch stores and rates
  • GET/v1/rates/{merchant}Current rate for one merchant
  • GET/v1/walletBalance and per-agent ledger

Request

POST /v1/links
curl -X POST https://api.dotrewards.demo/v1/links \
  -H "Authorization: Bearer $DOTREWARDS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "merchant": "booking-com",
    "intent": "hotel"
  }'

Response

200 OK
{
  "id": "lnk_8f3a2c",
  "url": "https://drw.ds/l/…",
  "merchant": "booking-com",
  "rate": "Up to 7%",
  "tracked_for": "usr_demo",
  "agent": "agt_travel_bot"
}

Events

Webhooks

Subscribe to events to keep your agent in sync with the cashback lifecycle. Each request carries a Dotrewards-Signature header, an HMAC-SHA256 of the raw body.

  • cashback.tracked

    The merchant reported an order made through your link. Cashback is pending.

  • cashback.confirmed

    The order cleared the return window. Cashback is payable, with your approval.

cashback.tracked
{
  "id": "evt_1a2b3c",
  "type": "cashback.tracked",
  "created": "2026-10-07T09:41:12Z",
  "data": {
    "link_id": "lnk_8f3a2c",
    "merchant": "booking-com",
    "agent": "agt_travel_bot",
    "user": "usr_demo",
    "order_value": { "amount": 412.00, "currency": "AUD" },
    "cashback": { "amount": 28.84, "currency": "AUD", "status": "pending" }
  }
}
cashback.confirmed
{
  "id": "evt_4d5e6f",
  "type": "cashback.confirmed",
  "created": "2026-10-21T02:10:44Z",
  "data": {
    "link_id": "lnk_8f3a2c",
    "user": "usr_demo",
    "cashback": { "amount": 28.84, "currency": "AUD", "status": "confirmed" }
  }
}

Controls

Agent wallet

Every agent gets its own spend and cashback ledger, plus a monthly cap you set. Agents can read the wallet. Only you can withdraw from it.

Travel bot

Tracked spend this month

$672.00 / $1,000.00 cap

Grocery agent

Tracked spend this month

$138.50 / $400.00 cap

Shopping agent

Tracked spend this month

$189.00 / $300.00 cap

Ledger

Confirmed $48.40|Pending $28.84

  • Booking.com

    Travel bot · 07 Oct · $412.00

    +$28.84

    Pending
  • Woolworths

    Grocery agent · 05 Oct · $138.50

    +$2.08

    Confirmed
  • Agoda

    Travel bot · 03 Oct · $260.00

    +$31.20

    Confirmed
  • THE ICONIC

    Shopping agent · 02 Oct · $189.00

    +$15.12

    Confirmed

Spending caps. Set a monthly ceiling per agent. Links stop being issued once the cap is reached.

You approve payouts. Agents can read the ledger. Withdrawals need your sign-off in the app.

Questions

FAQ

Who gets the cashback?
You do. Every link is tied to the person who approved the agent (the tracked_for field). Cashback is credited to that person's account, never to the agent or the developer who built it.
Can agents withdraw?
No. An agent key can create links and read the wallet. There is no withdraw tool or endpoint, and payouts only move after you approve them in the app.
Which stores work with agents?
Stores flagged agent-ready accept tracked purchases started through the API or MCP. In this demo that is 18 stores, and search_stores returns an agent_ready flag for each. Browse them on the stores page.
How does attribution work?
create_cashback_link returns a short URL carrying a click ID tied to your user and the calling agent. When the agent checks out through it, the merchant reports the order (cashback.tracked) and later confirms it once the return window closes (cashback.confirmed).
Is it free?
In this concept, yes. Linking an agent costs nothing, and cashback is a share of the commission merchants already pay for referred sales.

Want your agent earning cashback?

This is a concept, but the waitlist is real enough. Join free and we'll show you the agent flow first.

Join free