Skip to main content
POST
Draft personas with a model

Authorizations

Authorization
string
header
required

MCPJam API key (sk_…). Create one at Settings → API keys. Guest sessions cannot use the API, and API keys cannot manage other API keys.

Path Parameters

projectId
string
required

ID of the hosted project that contains the server.

Body

application/json

Grounding source and slate size.

Exactly ONE grounding source: serverAttachmentId or environmentId. Sending both is a 400 — a request that is already confused about what it wants should not have a winner picked for it.

serverAttachmentId
string
environmentId
string
journeyCount
integer

Journeys to draft per persona.

personaCount
integer

Ask for a SLATE of N personas. Omitting it is not the same as 1: it selects the legacy single-persona response shape, so a default would switch the response under a caller that only knows the other one.

Required range: 1 <= x <= 12
description
string

Free-text audience brief, forwarded verbatim into the prompt.

Maximum string length: 2000
existingPersonas
object[]

Personas you already have, so the model drafts different ones. A prompt hint, not a data feed — only the first few dozen are used.

Response

Draft personas and journeys.

DRAFTS. Nothing here is persisted — feed what you want to keep to POST /projects/{projectId}/personas or POST /projects/{projectId}/journeys.

The shape depends on the request: POST /personas/generate returns {persona, journeys} without personaCount and {personas: [{persona, journeys}]} with it; POST /journeys/generate returns {journeys}.

persona
object

A generated persona draft. Nothing is persisted until you create it.

personas
object[]
journeys
object[]