NAME

Tomba::Leads - Leads management for the Tomba.io API

SYNOPSIS

use Tomba::Leads;

my $tomba = Tomba::Leads->new("ta_xxxxx", "ts_xxxxx");
my $leads = $tomba->ListLeads();

DESCRIPTION

Create, read, update, and delete leads.

ListLeads

my $data = $tomba->ListLeads();
my $data = $tomba->ListLeads({ domain => "tomba.io", page => 1, limit => 10 });

Retrieve a paginated list of leads. Optionally filter by domain.

See https://docs.tomba.io/api/leads#retrieve-a-single-leads

GetLead

my $data = $tomba->GetLead($lead_id);

Retrieve detailed information for a specific lead.

See https://docs.tomba.io/api/leads#retrieve-a-single-leads-leadid

CreateLead

my $data = $tomba->CreateLead({
    email      => "test@example.com",
    first_name => "John",
    last_name  => "Doe",
    company    => "Example Inc",
});

Create a new lead. If the email already exists, fails with 422 status code.

See https://docs.tomba.io/api/leads#post-leads

UpdateLead

my $data = $tomba->UpdateLead($lead_id, { first_name => "Jane" });

Update the fields of a lead using its ID.

See https://docs.tomba.io/api/leads#put-leads-leadid

DeleteLead

my $data = $tomba->DeleteLead($lead_id);

Delete a lead using its ID.

See https://docs.tomba.io/api/leads#delete-a-leads-leadid

AUTHOR

Mohamed Ben rebia, <b.mohamed@tomba.io>

COPYRIGHT AND LICENSE

Copyright 2023 Mohamed Benrebia <b.mohamed@tomba.io>

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0