Getting Started
Getting StartedUpdated February 18, 2025
Getting Started
Follow these steps to start using the MachFive API.
1. Create an API key
API keys are created in the MachFive app and are scoped to a workspace.
- Log in at app.machfive.io.
- Open Settings (or Workspace → API Keys).
- Go to the API Keys section.
- Click Create API Key.
- Enter a name (e.g. "Production" or "OpenClaw") and create the key.
- Copy the key and store it securely. It is shown only once and cannot be retrieved later.
Key format: mf_live_ followed by 32 characters (e.g. mf_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx).
2. Base URL and headers
- Base URL:
https://app.machfive.io - Auth: Send your API key on every request (see Authorization).
Example:
curl -X GET "https://app.machfive.io/api/v1/campaigns" \
-H "Authorization: Bearer mf_live_YOUR_KEY_HERE"3. First request: list campaigns
To see which campaigns you can use for generation:
curl -X GET "https://app.machfive.io/api/v1/campaigns" \
-H "Authorization: Bearer YOUR_API_KEY"Response:
{
"campaigns": [
{ "id": "uuid", "name": "Q1 Outbound", "created_at": "2025-01-15T12:00:00.000Z" }
]
}Use a campaign id in the generate or generate-batch endpoints.
4. Generate for one lead (sync)
To generate a sequence for a single lead (takes 3–10 minutes):
curl -X POST "https://app.machfive.io/api/v1/campaigns/CAMPAIGN_ID/generate" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"lead": {
"name": "Jane Doe",
"title": "VP Marketing",
"company": "Acme Inc",
"email": "jane@acme.com"
}
}'Important: Use a timeout of at least 300 seconds (5 minutes) or 600 seconds (10 minutes). Shorter timeouts will cut off the response.
5. Generate for multiple leads (async)
To process many leads without waiting:
- POST to
POST /api/v1/campaigns/:id/generate-batchwith{ "leads": [ {...}, ... ], "options": { ... } }. - You get 202 Accepted with
list_id. - Poll
GET /api/v1/lists/:list_iduntilprocessing_statusiscompleted(orfailed). - Export results with
GET /api/v1/lists/:list_id/export?format=csvor?format=json.
See Generate Batch and Lists for details.