Skip to main content
Use Remarkety through Corsair: one client, typed API calls. The token comes from your Remarkety account and goes in the X-Token header. The API also accepts token as a query parameter, but the plugin never uses it: a key in a URL is logged by every proxy. Accept: application/json is load-bearing. Sent without it, a failed call comes back as an HTML login page instead of the JSON error {"message":"Missing or invalid API Key","status":"ERROR","guid":"…"}. The plugin always sends it, and it keeps the guid on the error because that is what support asks for. The store ID is the short string on Settings > API Keys (for example AbC123xy); every store route takes it as storeId. Building a campaign takes two reads first:
  • rules.list gives every rule type, keyed by type (CART_FOLLOWUP_TIME, …), with its operators, possibleValues and defaultValue. A campaign action’s rules must use those exact operator strings.
  • campaigns.types gives the campaign types the store supports (TRIGGER_CART_RECOVERY, …) with their mandatory and optional rules.
Things worth knowing before a write:
  • contacts.create emails the contact by default. Remarkety’s doubleOptin defaults to true and sends a confirmation request; pass doubleOptin: false to add a contact without it. properties is one object, not a list.
  • stores.create and stores.update carry a different secret. The apiKey there is the key Remarkety uses to sync that store; it is not the token this plugin authenticates with.
  • stores.update is PUT /stores with the id in the body, not PUT /stores/{id}. The same is true of campaigns.update, which is PUT /stores/{storeId}/campaigns.
  • mode decides whether a campaign sends. run starts it contacting shoppers, test sends a sample to testEmail, and stop halts it. Check the current mode with campaigns.get before updating, and remember a stop is the safe state to build in.
  • An email action needs a subject and a baseTemplate; an api action needs a webhook. The plugin rejects either omission rather than creating a campaign Remarkety cannot run. This endpoint version expects exactly one action.
  • stores.status is the sync health check, and syncStatus is the field to read. syncLastError holds the last runner message even on a healthy store (for example Campaign runner completed ( success: 0 ) with syncStatus: OK), so a non-empty value is not a failure.
  • Deleting a store is destructive and final. There is no archive state, and a store’s campaigns and contacts go with it.
What you get:
  • 20 typed API operations

Setup

1

Install

2

Add the plugin

corsair.ts
With multiTenancy: true, scope calls with corsair.withTenant(id). See Quick start for KEK + Hub keys, and Multi-tenancy for account isolation.
3

Choose authentication

4

Connect a tenant

Mint a connect link and send the tenant to it. Hub hosts the page and delivers the result to your app — see Connect / OAuth.

Example API calls

List the rules a campaign can use
Create a contact with marketing permission
See the full list on the API page.

What’s next

API reference

Every remarkety.api.* operation with input and output types.

Connect / OAuth

createLink, Hub delivery, and tenant connect flows.

Use with agents

Expose this plugin’s operations as MCP tools.