Create a journey
Creates one goal: a persona pursuing a task against one or more environments. To draft several with a model first, use POST /projects/{projectId}/goals/generate — that route persists nothing.
personaId and swarmId must belong to THIS project. Naming one from another project is a 404, not a silent cross-project reference.
Creating a goal does not run it. Launch it with POST /projects/{projectId}/goals/{goalId}/runs.
Authorizations
MCPJam API key (sk_…). Create one at Settings → API keys. Guest sessions cannot use the API, and API keys cannot manage other API keys.
Headers
Retry-safe create key. Replaying the SAME key with the SAME body returns the original resource instead of creating a second one; reusing it with a DIFFERENT body is a 409.
Path Parameters
ID of the hosted project that contains the server.
Body
The goal to create.
1–4000 characters.
4000An existing persona in this project.
1 <= x <= 1001 <= x <= 200200Authoring provenance only — which swarm container this was made in.
The environments to fan out across. NON-EMPTY when present: [] reads as "these, naming none", and would silently fall back to something else.
1Legacy host-pinned grounding.
Response
The created goal.
A persona's task: what they are trying to accomplish, and across which targets. Launching one is POST /projects/{projectId}/goals/{goalId}/runs.
What the persona is trying to accomplish. This drives the whole run.
The swarm container this goal was authored under. Provenance only — nothing resolves through it at run time, and a goal created outside a swarm has none.
Environments this goal fans out across. EMPTY on a host-pinned goal — that is a different execution model, not a goal with no targets.
Sessions run against EACH target. Total sessions = targets × this.
Epoch milliseconds.
Epoch milliseconds.
Legacy host-pinned grounding. Absent on an environment-based goal.
Whether prerequisite setup may create or modify workspace data before sessions run. Defaults to false.

