Docs · Quick start
Your first lead, in one request.
Send a lead to Fernway and it lands in GoHighLevel as a contact, with its note and its opportunity. You get a waybill number back, and every step it takes is a scan you can read.
1The key
Every request carries an API key in its Authorization header. This one is public, so you can run everything on this page now.
fw_jncy4l3m_clxvwux3d59fix5gqqapmysy9hb0ouezThe demo key reaches only the demo account. Its leads go to a stand-in GHL inside Fernway, not a real CRM, and are deleted after a day. A real account gets its own keys, shown once and stored only as a hash.
2Send a lead
Post the person and the route it takes. The route decides the pipeline, stage and tags in GHL. An email or a phone number is required, so GHL can keep one person as one contact.
curl https://fernway.jeromebadour.com/api/v1/leads \
-H "Authorization: Bearer fw_jncy4l3m_clxvwux3d59fix5gqqapmysy9hb0ouez" \
-H "Content-Type: application/json" \
-d '{
"idempotencyKey": "docs-bcd592b50d8d",
"route": "demo",
"contact": {
"firstName": "Ada",
"email": "ada@example.com"
}
}'Run it here
The same request, sent from this page with the demo key.
The answer comes at once, before GHL is reached: 201 with the waybill number, the lead’s API link and a receipt page you can hand to the person who sent it. Delivery into GHL follows, usually within seconds.
3Track it
Ask for the lead by its number, with dashes. You get where it is and every scan so far.
curl https://fernway.jeromebadour.com/api/v1/leads/FW-26-00817 \
-H "Authorization: Bearer fw_jncy4l3m_clxvwux3d59fix5gqqapmysy9hb0ouez"picked_up- Fernway has it and has checked it.
in_transit- Being handed to GHL right now.
waiting- GHL was busy or down; the next try is scheduled. 8 tries over 24 hours.
signed- GHL has it: the contact, its note, and its opportunity or meeting.
held- GHL refused it for a reason a retry can't fix. Its reason is on the lead.
4Sending twice is safe
The idempotencyKey is your own id for the lead: an order number, a form entry id, anything that stays the same for the same lead. Sent again, after a timeout or a crash, it gives the same waybill back with "duplicate": true, and nothing reaches GHL twice. A send that may have failed is always safe to repeat.
When something’s wrong
Every refusal says what to change, one line per problem, the field first. Nothing is made when a lead is refused.
| # | Status | Means | Good to know |
|---|---|---|---|
| 1 | 401 | No key, or a revoked one. | The key travels in the Authorization header. |
| 2 | 422 | The lead was refused at the door. | Each problem names its field and what the field needs. |
| 3 | 429 | Over the limit: 60 requests a minute per key. | Retry-After gives the wait in seconds; the same key sends nothing twice. |
{
"ok": false,
"problems": [
"contact.email: a real email address"
]
}Every field, every answer: the API reference.