Skip to main content
The Seed Datasets API provides pre-built dataset packs that populate the platform with realistic sample data. Each pack includes schemas, categories, offers, channels, creatives, qualification rules, contact policies, algorithm models, decision flows, segments, and synthetic customer/interaction data.
See the Sample Data guide for a walkthrough of using seed datasets.

Base path

/api/v1/seed-dataset

List available datasets

GET /api/v1/seed-dataset
Returns all registered dataset packs with their metadata and current load status.

Response 200

{
  "datasets": [
    {
      "key": "starbucks",
      "name": "Starbucks Rewards",
      "description": "Coffee loyalty rewards program with seasonal promotions.",
      "source": "synthetic",
      "csvFiles": [],
      "testingFocus": "Multi-channel loyalty offers with frequency capping",
      "schemaCount": 2,
      "offerCount": 12,
      "modelCount": 2,
      "channelCount": 4,
      "categoryCount": 3,
      "creativeCount": 24,
      "loaded": false
    }
  ],
  "currentlyLoaded": null
}

Field reference

FieldTypeDescription
keystringUnique dataset identifier used in load/delete URLs.
loadedbooleanWhether this dataset is currently loaded for the tenant.
currentlyLoadedstring | nullKey of the currently loaded dataset, or null if none.

Load a dataset

POST /api/v1/seed-dataset/{key}
Loads a dataset pack into the platform. Creates all entities in correct foreign-key dependency order: schemas, categories, channels, offers, creatives, rules, models, decision flows, segments, synthetic data rows, and interaction history.

Path parameters

ParameterRequiredTypeDescription
keyYesstringDataset key (e.g., "starbucks").

Query parameters

ParameterRequiredTypeDescription
forceNostringSet to "true" to replace a currently loaded dataset.

Response 201

{
  "message": "Starbucks Rewards loaded successfully",
  "counts": {
    "schemas": 2,
    "categories": 3,
    "subCategories": 6,
    "channels": 4,
    "offers": 12,
    "creatives": 24,
    "qualificationRules": 5,
    "contactPolicies": 3,
    "outcomeTypes": 10,
    "models": 2,
    "experiments": 1,
    "decisionFlows": 1,
    "segments": 1,
    "customers_rows": 1000,
    "transactions_rows": 1000,
    "interactions": 500,
    "interactionSummaries": 500,
    "segmentCustomers": 450
  },
  "datasetKey": "starbucks"
}

Error codes

CodeReason
404Dataset key not found in registry.
409Another dataset is already loaded (use ?force=true to replace).
409Same dataset is already loaded.
429Rate limited (5 requests per 60 seconds).

Response 409 (dataset conflict)

{
  "status": 409,
  "currentlyLoaded": "banking",
  "requestedLoad": "starbucks",
  "message": "Banking NBA is currently loaded. Add ?force=true to remove it and load Starbucks Rewards."
}

Remove a dataset

DELETE /api/v1/seed-dataset/{key}
Removes all entities belonging to a dataset pack in reverse foreign-key dependency order. Drops associated PostgreSQL tables and segment views.

Path parameters

ParameterRequiredTypeDescription
keyYesstringDataset key to remove.

Response 200

{
  "message": "Starbucks Rewards removed successfully",
  "counts": {
    "interactions": 500,
    "interactionSummaries": 500,
    "creatives": 24,
    "offers": 12,
    "experiments": 1,
    "decisionFlows": 1,
    "channels": 4,
    "categories": 3,
    "qualificationRules": 5,
    "contactPolicies": 3,
    "models": 2,
    "runs": 0,
    "segments": 1,
    "schemas": 2
  }
}

Error codes

CodeReason
404Dataset key not found in registry.

Role requirements

MethodMinimum role
GETadmin
POSTadmin
DELETEadmin
Loading a dataset creates real PostgreSQL tables with synthetic data rows. In a production environment, only use this for testing purposes.