Skip to main content
POST
/
projects
/
{project_id}
/
simulations
/
execute
curl --location 'https://api.withblast.com/projects/550e8400-e29b-41d4-a716-446655440000/simulations/execute' \
--header 'Authorization: Bearer YOUR_JWT_TOKEN' \
--header 'Content-Type: application/json' \
--data '{
  "simulation_type": "goal",
  "simulation_params": {
    "seed": [
      {
        "goal": "plan a kitchen renovation"
      },
      {
        "goal": "replace bathroom tiles"
      }
    ],
    "persona": [
      "Spanish-speaking, first-time homeowner"
    ],
    "max_turns": 5
  },
  "payload_params": [
    {"name": "store_id", "value": "1124"}
  ],
  "evaluators": [1, 2, 3, 4, 5, 6],
  "k": 1,
  "metadata": {
    "tags": [27]
  }
}'
{
  "created": 2
}

Authentication

Authorization
string
required
Bearer token

Path Parameters

project_id
string
required
The unique identifier of the project (UUID format)

Body Parameters

simulation_type
string
required
Type of simulation to run (e.g., “follow_up”, “persona”, “safety”)
simulation_params
object
required
Parameters for the simulation. Each simulator type has a set of required parameters. Values can be single values or lists - lists will be expanded into all combinations.
payload_params
array
Optional array of payload parameters. Each item should have name and value fields.
k
integer
default:"1"
Number of times to run each parameter combination (minimum: 1)
evaluators
array
required
List of evaluator IDs
metadata
object
Additional metadata (e.g., {"tags": [27], "version": "1.0.0"} for associating tag IDs with simulations)

Response

created
integer
required
Number of simulation runs created and queued
curl --location 'https://api.withblast.com/projects/550e8400-e29b-41d4-a716-446655440000/simulations/execute' \
--header 'Authorization: Bearer YOUR_JWT_TOKEN' \
--header 'Content-Type: application/json' \
--data '{
  "simulation_type": "goal",
  "simulation_params": {
    "seed": [
      {
        "goal": "plan a kitchen renovation"
      },
      {
        "goal": "replace bathroom tiles"
      }
    ],
    "persona": [
      "Spanish-speaking, first-time homeowner"
    ],
    "max_turns": 5
  },
  "payload_params": [
    {"name": "store_id", "value": "1124"}
  ],
  "evaluators": [1, 2, 3, 4, 5, 6],
  "k": 1,
  "metadata": {
    "tags": [27]
  }
}'
{
  "created": 2
}