Prerequisites
Before creating an enquiry, ensure you have:- The Leads product enabled on your account.
- A secret key.
- A qualification configuration ID, if you want to collect qualification answers.
Permissions
Create an enquiry
Every field is optional, so you can capture a lead from as little as an email address and fill in the rest later.Create an enquiry
Response
Enquiry parameters
An enquiry created without qualification answers starts as
new. An enquiry created with answers starts as pending, because there is something for your team to review.Collect qualification answers
A qualification configuration defines the questions you ask a lead. You can build one in the Dashboard, or with the Qualification Configurations API. Each configuration exposes ahosted_qualification_url that a lead can complete in their browser — submitting it creates the enquiry for you. To put that same form on your own website, embed it with Yorlet.js.
To collect answers against an enquiry that already exists, choose one of the approaches below.
- Send a hosted form
- Submit answers yourself
Attach a configuration to the enquiry and let Yorlet host the form. Set Retrieve the link at any time — it is created on first use and reused for the lifetime of the enquiry.The response is a
notification.type to email to send the lead their link straight away.Attach a qualification configuration
Create a qualification link
leads.enquiry_qualification_link object with the enquiry it belongs to and the url of the hosted form. Send that URL to the lead however you like — the hosted page handles its own authentication, so you never expose an API key to the lead.An enquiry can only have one qualification configuration. Attaching a second one returns an error, so use the qualification link action when a configuration is already attached.
Standard answers
Read the score
Once answers are submitted, Yorlet scores them against the attached configuration and writes a short explanation. Retrieve the enquiry to read both, expanding the configuration if you need its questions too.Retrieve an enquiry
Response
score and reason are null for a short time after the first submission.
Move the enquiry through your pipeline
Use the status endpoint to progress a lead. Pass an optionalreason to record why.
Qualify an enquiry
Transitions to
qualified and disqualified record reviewed_at and reviewed_by on the enquiry. Moving to qualified also emails the lead their viewing booking link when the account has automatic booking links turned on.
Booking a viewing advances the enquiry to
viewing for you, so you do not need to set that status yourself. See Book a viewing.List and filter enquiries
List qualified enquiries
Enquiries are returned newest first, and
assignee, unit, and qualification_configuration can each be expanded with expand[].
Route enquiries automatically
Rather than attaching a configuration on every create call, use the Qualification Routes API to attach one whenever a matching enquiry arrives. Leave a condition empty to match anything, and give your most specific routes the lowestpriority.
Create a qualification route