Skip to main content
Most of the work in connecting a custom store is mapping your own order, cart and product models onto Watx’s format. An AI coding assistant working in your store’s codebase does that well if it is given the whole contract at once. This page gives you that prompt.

Use it

1

Connect the store in Watx

Integrations → Custom store → Connect. Keep the Signing secret from the Send events step somewhere safe.
2

Copy the prompt

On the same step, Building it with an AI assistant? → Copy prompt copies the prompt below with your own webhook URL already filled in. Or copy it from this page and replace <the webhook URL shown in Watx> yourself.
3

Paste it into your assistant

Open Claude Code, Cursor, GitHub Copilot, Codex or any other coding assistant in your store’s codebase, so it can find your models and routes, and paste the prompt.
4

Set the secret yourself

Put the signing secret in your server’s environment as WATX_SECRET. The prompt never contains it, and you should not paste it into the assistant.
5

Check the result

Run the ping command the assistant wrote: it should print pong, and the store switches to Connected in Watx. Place a test order and look for an outcome that starts with order placed and has no — check: warnings.
6

Add the callback URL

The assistant tells you the path of the route it added. Enter its full https address under Connection settings → Callback URL and press Send a test.
Never paste the signing secret into an AI assistant, a chat or a prompt. Prompts end up in other companies’ logs and in shared chat histories, and anyone holding the secret can put orders into your workspace. If it has been pasted somewhere, rotate it under Connection settings → Rotate secret.

The prompt

Why it is written this way

  • The whole format is inline. An assistant that cannot browse still has every field. One that can is pointed at the JSON Schema for exact types.
  • It has a definition of done. Watx’s reply to every event names the fields it could not use ( — check: …), so the assistant can send a test event and fix its own mapping until the warnings are gone.
  • It keeps your checkout safe. Events are sent after the order is saved, in the background, with retries — a slow or unreachable Watx never fails a customer’s checkout.
  • It handles Watx’s requests correctly. It verifies the signature on the raw body, creates a discount code exactly as Watx sent it, and answers with a sentence Watx can show you when something goes wrong.
Review what the assistant writes as you would any other change to your checkout. The full contract is on the Custom store page.