Skip to main content

Customer Management — Create or Update Lead

Upserts a lead in your Superfone CRM, matched by phone number. If a lead with that phone already exists it is updated; otherwise a new lead is created (when enabled).

Authentication Required

This action runs against your organization using the Superfone connection (your API key).

Endpoint

POST https://prod-api.superfone.co.in/superfone/enterprise/api/lead

Input fields

FieldTypeRequiredDescription
customer_phonestringYesThe lead's phone number in E.164 format (e.g. +918000000001). Used to match an existing lead or create a new one.
create_customer_if_customer_phone_not_foundbooleanNoIf true, creates a new lead when no match is found. If false/omitted, a missing lead is not created. This is the "upsert" toggle.
first_namestringNoLead's first name.
last_namestringNoLead's last name.
emailarray of stringsNoOne or more email addresses.
business_namestringNoCompany / business name.
websitestringNoWebsite URL.
citystringNoCity.
deal_valuenumberNoMonetary value of the deal.
sourcestringNoFree-text source label.
source_typedropdownNoLead source type — dropdown populated by List Source Types.
lead_stage_namedropdownNoPipeline stage — dropdown populated by List Lead Stages.
lead_group_namedropdownNoLead group — dropdown populated by List Lead Groups.
add_labelsarray (dropdown)NoLabels to add — dropdown populated by List Labels.
remove_labelsarray (dropdown)NoLabels to remove — dropdown populated by List Labels.
add_productsarray (dropdown)NoProducts to attach — dropdown populated by List Products.
add_phonesarray of stringsNoAdditional phone numbers for the lead (E.164).
assignee_user_phonestringNoPhone number of the team member to assign this lead to (E.164).
additional_infostringNoFree-text notes stored on the lead.
customer_notestringNoAdds a note to the lead's timeline.
Dropdown fields

Fields marked dropdown load live values from your account, so you select from your real configuration instead of typing. See Dropdowns.

How to use in Pabbly

  1. Add the Create or Update Lead action to your workflow.
  2. Map customer_phone from the previous step (ensure E.164 format).
  3. Fill any other fields; pick from dropdowns where shown.
  4. Turn on Create customer if phone not found if you want new leads created.
  5. Save and send a test.

Create or Update Lead action configured in Pabbly

Example workflow

New paid order in your storeCreate or Update Lead (phone from the order, source_type = Online, lead_stage_name = New Paid Cx, create_customer_if_customer_phone_not_found = true) → Create Task (follow-up call tomorrow).

Response

Status Code: 200 OK

{
"data": null,
"message": "success"
}

The lead is created or updated; the action returns a success envelope rather than the lead body. To read the lead back (and get its lead_id), use Get Lead.

Common errors

Status CodeWhen it occursHow to fix
400Invalid phone format; a field validation failure; or the phone matched no lead and Create customer if phone not found was off (Customer not found)Ensure customer_phone is E.164; check field types (e.g. email is a list, deal_value is a number); turn on the create toggle to create new leads.
401Missing or invalid API keyReconnect your Superfone account in Pabbly.
404A referenced name doesn't exist in your account — an unknown lead_stage_name, lead_group_name, or assignee_user_phonePick values from the dropdowns; make sure the assignee is an existing team member.