v8

OpenAPI 3.1.02026-08-033623795.0 MB
Leads

Create lead

Record a new lead for a company, capturing a potential customer's interest in a specific product.

Required permissions:

  • lead:manage
  • member:email:read
  • access_pass:basic:read
  • member:basic:read
post/leads

Request body

company_idstring required

The unique identifier of the company to create the lead for, starting with 'biz_'.

metadataobject nullable

A JSON object of custom metadata to attach to the lead for tracking purposes.

product_idstring nullable

The unique identifier of the product the lead is interested in, starting with 'prod_'.

referrerstring nullable

The referral URL that brought the lead to the company, such as 'https://example.com/landing'.

user_idstring nullable

The unique identifier of the user to record as the lead. If authenticated as a user, that user is used automatically.

Example request

{
  "company_id": "biz_xxxxxxxxxxxxxx",
  "product_id": "prod_xxxxxxxxxxxxx",
  "user_id": "user_xxxxxxxxxxxxx"
}

Response

A successful response

created_atstring date-time required

The datetime the lead was created.

idstring required

The unique identifier for the lead.

metadataobject nullable required

Custom key-value pairs attached to this lead. Null if no metadata was provided.

referrerstring nullable required

The URL of the page that referred this lead to the company. Null if no referrer was captured.

updated_atstring date-time required

The datetime the lead was last updated.

Example response

{
  "created_at": "2023-12-01T05:00:00.401Z",
  "id": "lead_xxxxxxxxxxxxx",
  "product": {
    "id": "prod_xxxxxxxxxxxxx",
    "title": "Pickaxe Analytics"
  },
  "referrer": "https://twitter.com/whabormarket",
  "updated_at": "2023-12-01T05:00:00.401Z",
  "user": {
    "email": "john.doe@example.com",
    "id": "user_xxxxxxxxxxxxx",
    "name": "John Doe",
    "username": "johndoe42"
  }
}