Base URL
Authentication
All endpoints authenticate with an API key passed in thex-api-key header. The key is scoped to a single organization — studies are created in, and wallets are listed for, that organization.
Workflow
Create a draft study
POST /api/public/v1/studies/create with a title and a study guide. The guide is validated up front; if it passes, you get back a draft study’s id and linkId. Nothing is visible to participants yet — you can still review or edit the draft in the dashboard.Pick a wallet (optional)
GET /api/public/v1/wallets lists the wallets granted to your organization with their recruitment and project credit balances. walletId can only be omitted at launch when your organization has exactly one wallet (it’s auto-selected). If you have access to more than one, omitting it returns a 400 (wallet_required) — you must pass one from this list.Quickstart
A complete create → launch example you can copy and run.
Endpoints
| Endpoint | Description |
|---|---|
POST /api/public/v1/studies/create | Validate a study guide and create a draft study |
POST /api/public/v1/studies/{studyId}/launch | Publish a draft and return the self-recruit link |
GET /api/public/v1/wallets | List the organization’s wallets with balances |
Errors
Every error response shares one JSON envelope:error— a human-readable message. Useful for logs, but it may change; don’t branch on it.code— a stable, machine-readable identifier. Branch on this.issues— present only on400schema failures (code: invalid_request_body): an array of per-field violations, each with apathandmessage.
400 Schema violation
400 Invalid study guide
Error codes
| Status | Code | Meaning |
|---|---|---|
400 | invalid_json | Request body isn’t valid JSON. |
400 | invalid_request_body | Body failed schema validation. See issues for per-field details. |
400 | invalid_study_guide | The study guide broke a cross-field rule (create only). |
400 | wallet_required | The organization has multiple wallets and walletId was omitted (launch only). |
400 | insufficient_credits | The wallet can’t fund the launch — insufficient balance or grant limit (launch only). |
401 | missing_api_key | No x-api-key header. |
401 | invalid_api_key | The API key is invalid. |
403 | forbidden | The key’s user isn’t a member of the key’s organization. |
403 | launch_permission_denied | The key’s user lacks permission to launch this study. |
403 | wallet_access_denied | No access to the specified wallet. |
404 | study_not_found | Study not found in the key’s organization. |
409 | concurrent_modification | The draft was modified concurrently; retry (create only). |
409 | study_busy | An update is in flight; retry after a moment (launch only). |
409 | conflict | The publish raced a concurrent edit; refresh and retry (launch only). |
500 | internal_error | Internal error. Details are logged server-side, not returned. |
Beyond field-level validation, the server enforces cross-field rules on the study guide (screening block placement,
minSelect/maxSelect coupling, unique externalIds, reference resolution, exclusiveOption placement) and returns violations as 400 responses (code: invalid_study_guide). The full list is in the Study Guide Reference.