Setting Up a Lead Post API
Creating a New Destination
- Navigate to https://app.leadstreams.co/destinations
- Either:
- Find your existing campaign and create a destination for it
- Click "New Destination" and select your campaign
Choosing Integration Type
Note: While we offer both no-code and Lead Post Webhook options, no-code integrations are temporarily paused for optimization.
Select "Lead Post Webhook" as your integration type.
Configuring Your Webhook
Basic Configuration
- Type: Select "Data Post"
- Method: Choose your preferred HTTP method
- Endpoint URL: Enter your API endpoint
Content Type Options
Format | Description |
---|---|
Form Data | Sends data as multipart/form-data |
JSON | Sends data as application/json |
URL Encoded | Sends data as application/x-www-form-urlencoded |
XML | Sends data as application/xml |
Custom Headers
You can add custom headers if needed for authentication or other purposes.
JSON Properties
When using JSON format, you can map our variables to your required property names:
- Key: Your required property name
- Value: Either a static string or a variable in the format
{variable}
Available Variables
Use these variables in your JSON properties by wrapping them in curly braces, e.g., {email}
Tip: For detailed information about variable formats and examples, see our Properties Reference Guide.
The Lead Post API accepts a comprehensive set of variables that can be used to enrich and qualify leads. Below is the complete list of available variables:
Property | Values | Value Type | Description |
---|---|---|---|
{first_name} | - | string | Lead's first name |
{last_name} | - | string | Lead's last name |
{email} | - | string | Valid email address |
{phone} | - | string | Valid phone number |
{campaign_id} | - | string | Campaign identifier |
{created_at} | YYYY-MM-DD HH:mm:ss | datetime | Lead creation timestamp |
{ip_address} | - | string | Lead's IP address |
{address} | - | string | Street address |
{city} | - | string | City name |
{state} | - | string | State/province |
{zip} | 99999 | string | Postal code |
{country} | US | string | Country name |
{phone_formatted} | - | string | Formatted phone number |
{email_confidence_match} | 0-100 | number | Email confidence score |
{age} | 0-120 | number | Age |
{gender} | Male, Female | string | Gender |
{income_hh} | see all | string | Household income |
{marital_status} | see all | string | Marital status |
{education} | see all | string | Education level |
{lat} | -90 to 90 | number | Latitude |
{lon} | -180 to 180 | number | Longitude |
{timezone} | - | string | Timezone |
{country_code} | US | string | Country code |
{user_agent} | - | string | Browser user agent |
{trusted_form_url} | - | string | TrustedForm certificate URL |
{consent_date} | YYYY-MM-DD HH:mm:ss | datetime | Consent timestamp |
{verified_phone} | 0, 1 | boolean | Phone verification status |
{verified_email} | 0, 1 | boolean | Email verification status |
{ethnic_group} | see all | string | Ethnic group identification |
{generation} | see all | string | Generational category |
{political_party} | see all | string | Political party affiliation |
{religion} | see all | string | Religious affiliation |
{education_ordinal} | 1-10 | number | Numeric education level |
{white_collar} | 0, 1 | boolean | White collar occupation indicator |
{blue_collar} | 0, 1 | boolean | Blue collar occupation indicator |
{birth_year} | YYYY | number | Year of birth |
{personality} | see all | string | Personality type |
{income_levels} | see all | string | Income bracket categorization |
{credit_range} | see all | string | Credit score range |
{net_worth_hh} | see all | string | Household net worth |
{credit_card} | 0, 1 | boolean | Credit card ownership status |
{owns_investments} | 0, 1 | boolean | Investment ownership indicator |
{owns_stocks_and_bonds} | 0, 1 | boolean | Stock/bond ownership indicator |
{political_contributor} | 0, 1 | boolean | Political contribution history |
{home_owner} | 0, 1 | boolean | Home ownership status |
{dwelling_type} | see all | string | Type of residence |
{length_of_residence} | 0-100 | number | Duration at current residence (years) |
{home_value} | see all | string | Estimated home value |
{mortgage_amount} | see all | string | Mortgage amount if applicable |
{mortgage_loan_type} | see all | string | Type of mortgage loan |
{children_hh} | 0, 1 | boolean | Presence of children in household |
{num_generations_hh} | 1-5 | number | Number of generations in household |
{veteran_hh} | 0, 1 | boolean | Veteran presence in household |
{num_persons_hh} | 1-20 | number | Total persons in household |
{num_adults_hh} | 1-10 | number | Number of adults in household |
{num_children_hh} | 0-10 | number | Number of children in household |
{child_aged_0_3_hh} | 0, 1 | boolean | Children aged 0-3 in household |
{child_aged_4_6_hh} | 0, 1 | boolean | Children aged 4-6 in household |
{child_aged_7_9_hh} | 0, 1 | boolean | Children aged 7-9 in household |
{child_aged_10_12_hh} | 0, 1 | boolean | Children aged 10-12 in household |
{child_aged_13_18_hh} | 0, 1 | boolean | Children aged 13-18 in household |
{number_of_vehicles_in_hh} | 0-10 | number | Number of vehicles in household |
{investment_type} | see all | string | Type of investments preferred |
{phone_voip} | 0, 1 | boolean | Phone is VoIP |
{phone_carrier} | - | string | Phone carrier name |
{phone_type} | mobile, landline, etc | string | Type of phone |
{phone_dialing_code} | - | string | Phone dialing code |
{phone_do_not_call} | 0, 1 | boolean | Phone is on do not call list |
{phone_activity} | active, inactive | string | Phone activity status |
{phone_is_callable} | 0, 1 | boolean | Phone can be called |
{phone_can_receive_texts} | 0, 1 | boolean | Phone can receive texts |
{email_array} | - | array | Array of associated emails |
{phone_array} | - | array | Array of associated phones |
{custom_one} | - | string | Custom field 1 |
{custom_two} | - | string | Custom field 2 |
{custom_three} | - | string | Custom field 3 |
{custom_four} | - | string | Custom field 4 |
{custom_five} | - | string | Custom field 5 |
Note: This is a subset of available variables. For a complete list of variables and their formats, see our Properties Reference Guide. For implementation support, contact our support team.
Testing and Response Validation
After saving your webhook configuration, you'll have access to two important features:
-
Test Lead Sending: You can send a test lead to verify your webhook integration is working correctly.
-
Response Validation: Configure how LeadStreams should interpret the responses from your endpoint:
- Response Format: Choose the format of the expected response (e.g., JSON)
- Response Field: Specify the field to validate (e.g.,
status
ordata.status
) - Response Operator: Select how to compare the field value (e.g., Equals)
- Success Value: Define what value indicates a successful post (e.g.,
success
)
This validation ensures LeadStreams can properly track successful lead deliveries and handle any potential errors.
Example Response Validation
If your endpoint returns a response like:
{
"status": "success",
"message": "Lead received successfully"
}
You would configure the validation as:
- Response Format:
Json
- Response Field:
status
- Response Operator:
Equals
- Success Value:
success
Testing Your Integration
After configuration:
- Save your webhook settings
- Use the "Test" button to send a sample lead
- Check your endpoint for the test data
- Verify the data mapping is correct
Support
Need help?
- Contact us at support@leadstreams.co
- Check our API status