API
Sending someone in from your own code
Anything a form can do, your server can do too. No key is needed, because this is what a form on your site does anyway. Fields are email, first_name, last_name, company, title, phone, country; anything else is kept with the person.
curl https://harrowsoft.com/eloquent/f/FORM_TOKEN/submit -H "content-type: application/json" \
-d '{"values": {"email": "rosa@example.com", "first_name": "Rosa", "company": "Copper Kettle"}}'
| POST /eloquent/f/{token}/submit | values, and optionally visitor and utm. |
| GET /eloquent/f/{token}/config | What the form asks, shorter for a known v visitor. |
| POST /eloquent/v/{site_key} | Notes a page visit: v, url, title. |
Managing it from a script
Make a token on your tokens page, and send it as Authorization: Bearer hs_.... It can do what you can, no more.
| GET /leads | Highest score first. q finds a name, email or company, stage narrows it, before gets the next page. |
| POST /leads | email, and any other fields. |
| POST /leads/import | A CSV file as the body. Needs an email column. |
| GET /lead/{id} | One person, with everything they've done and the points for it. |
| PATCH /lead/{id} | stage, owner, first_name, last_name, company, title, phone, country. |
| DELETE /lead/{id} | Removes them and their history, for when someone asks to be forgotten. |
| POST /lead/{id}/enroll | nurture: puts them in it. |
| GET /forms | Your forms and their numbers. |
| POST /forms | name, headline, intro, fields, submit_label, thanks, redirect. |
| PUT /form/{id} | The same. |
| DELETE /form/{id} | The people it brought in stay. |
| GET /emails | Your emails and how they did. |
| POST /emails | name, subject, preheader, body. |
| PUT /email/{id} | The same. |
| DELETE /email/{id} | Refused while a nurture uses it. |
| POST /email/{id}/test | to: sends one copy. |
| POST /email/draft | brief: writes a first draft. |
| GET /nurtures | Your nurtures and how many people are in each. |
| POST /nurtures | name, enter_kind (form, stage or manual), enter_value, steps. |
| GET /nurture/{id} | One, with how each email did. |
| PUT /nurture/{id} | The same as making one. |
| POST /nurture/{id}/status | status: running, paused or draft. |
| GET /rules | The scoring rules, and the score that means ready. |
| POST /rules | name, kind (form, visit, email_open, email_click, fit), value, field, points. |
| PUT /rules | mql_at, decay. |
| GET /reports | Sources, stages, weeks, sends, forms. |
| GET /inventory | What came from your old system, and what's still on. |
| POST /import/marketo | munchkin, client_id, client_secret. Admins only. |
| POST /import/pardot | token, business_unit. Admins only. |
| POST /import/eloqua | base_url, company, username, password. Admins only. |
What a nurture's steps look like
[
{"id": "a", "type": "email", "email": 12},
{"id": "b", "type": "wait", "days": 3},
{"id": "c", "type": "if", "cond": {"kind": "clicked"},
"then": [{"id": "d", "type": "tell", "member": 4}],
"otherwise": [{"id": "e", "type": "email", "email": 13}]},
{"id": "f", "type": "stage", "value": "mql"}
]
A condition's kind is clicked, opened, form, score (with a value) or stage (with a value). Stages are lead, mql, sql, customer and lost.