Skip to main content
GET
/
v2
/
{workspace}
/
template
/
{template_slug}
/
mock_data
Get Mock Data
curl -X GET "https://management-api.suprsend.com/v2/{workspace}/template/{template_slug}/mock_data/?mode=draft" \
  --header 'Authorization: ServiceToken <token>'
{
  "data": {
    "payload": {
      "order_id": "ORD-8821",
      "order_total": "$149.99",
      "delivery_date": "2026-04-10",
      "tracking_url": "https://yourapp.com/track/ORD-8821"
    },
    "tenant_id": "tenant_abc",
    "is_batch": false,
    "batch_count": 2,
    "recipient_sub_type": "user",
    "recipient_object": null,
    "recipient_distinct_id": "user_12345",
    "actor_sub_type": "user",
    "actor_object": null,
    "actor_distinct_id": null
  },
  "transformed_data": {
    "order_id": "ORD-8821",
    "order_total": "$149.99",
    "delivery_date": "2026-04-10",
    "tracking_url": "https://yourapp.com/track/ORD-8821",
    "$batch_key": "evaluated batch_key",
    "$batched_events": [
      {
        "order_id": "ORD-8821",
        "order_total": "$149.99"
      },
      {
        "order_id": "ORD-8821",
        "order_total": "$149.99"
      }
    ],
    "$batched_events_count": 2,
    "$brand": {
      "brand_id": "tenant_abc",
      "brand_name": "Acme Inc.",
      "logo": "https://cdn.acme.com/logo.png",
      "primary_color": "#1a73e8",
      "secondary_color": "#34a853",
      "tertiary_color": "#ffffff",
      "embedded_preference_url": "https://preferences.example.com/embed",
      "hosted_preference_domain": "preferences.example.com",
      "blocked_channels": null,
      "social_links": {
        "website": "https://www.example.com",
        "linkedin": "https://linkedin.com/company/example",
        "twitter": ""
      },
      "properties": {},
      "timezone": "America/New_York"
    },
    "$user": {
      "name": "Jamie Rivera",
      "email": "jamie.rivera@example.com"
    },
    "$recipient": {
      "name": "Jamie Rivera",
      "email": "jamie.rivera@example.com"
    },
    "$actor": {},
    "$embedded_preference_url": "https://preferences.example.com/embed",
    "$hosted_preference_url": "https://preferences.example.com/?key=xxxxxxxxxxxxxxx"
  }
}

Authorizations

ServiceToken <token>
string
header
required

You can get Service Token from SuprSend dashboard -> Account Settings -> Service Tokens section.

Path Parameters

workspace
string
required
template_slug
string
required

Query Parameters

mode
enum<string>
default:draft
Available options:
draft,
live

Response

Mock data retrieved. Returns both the raw data (what the user configured) and the transformed_data (resolved values including tenant, recipient, actor properties, and batched events).

data
object

The raw mock data configuration set by the user.

transformed_data
object

Resolved data used for rendering previews — includes tenant branding, recipient/actor profiles, batched events, and preference URLs.