Call it
curl https://api.peume.com/v1/call/create-a-lead-from-your-own-form \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"email": "your email",
"phone": "your phone"
}
}'const res = await fetch("https://api.peume.com/v1/call/create-a-lead-from-your-own-form", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"email": "your email",
"phone": "your phone"
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/create-a-lead-from-your-own-form",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"email": "your email",
"phone": "your phone"
}
},
)
print(res.json()["output"])Answer: {"id": "run_…", "status": "completed", "cost_usd": …, "output": {…}}. Long jobs answer 202 with a run id to read later. From an AI agent, connect the MCP server and ask for this by name: create-a-lead-from-your-own-form.
Parameters
emailstringRequired unless phone is given.
phonestringRequired unless email is given. E.164 is best.
fieldsobjectOther answers, field name to value (`full_name`, `company`,...). Stored on the lead, never sent to an ad platform.
formIdstringYour id for the form. Defaults to `api`.
formNamestringleadIdstringYour id for this lead (a CRM id, a submission id). Makes the call idempotent.
submittedAtstringWhen the form was submitted. Defaults to now.
sourceUrlstringThe page the form was submitted on, with its query string.
visitorIdstringThe tag visitor id, from the `_zid` cookie.
clickIdsobjectAd click and browser ids: `fbclid` or `fbc`, `fbp`, `gclid`, `gbraid`, `wbraid`, `ttclid`, `msclkid`, `li_fat_id`,...
utmobject`utm_source`, `utm_campaign`,...
