Get campaign
curl --request GET \
--url https://app.leadbeast.io/api/v1/campaigns/{campaign} \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.leadbeast.io/api/v1/campaigns/{campaign}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.leadbeast.io/api/v1/campaigns/{campaign}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.leadbeast.io/api/v1/campaigns/{campaign}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.leadbeast.io/api/v1/campaigns/{campaign}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.leadbeast.io/api/v1/campaigns/{campaign}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.leadbeast.io/api/v1/campaigns/{campaign}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"status": "completed",
"id": "<string>",
"name": "<string>",
"campaign_status": "<string>",
"is_on": true,
"leads_found": 123,
"contacted": 123,
"accepted": 123,
"replied": 123,
"pending_approvals": 123,
"linkedin_account": {
"id": "<string>",
"name": "<string>"
},
"steps": [
{
"order": 123,
"type": "connection_request",
"mode": "template",
"message": "<string>",
"with_note": true,
"wait_days": 30
}
],
"last_run": {
"status": "<string>",
"completed_at": "<string>",
"new_leads": 123
},
"next_run_at": "<string>",
"signals": [
{
"type": "ai_signal",
"keyword": "<string>",
"audience": "post_creators",
"signal_name": "<string>",
"qualification_prompt": "<string>",
"template_key": "competitor_engagers",
"source_url": "<string>",
"signal_type": "profile_tracking",
"source_name": "<string>",
"id": "<string>",
"group_id": "<string>"
}
],
"icp": {
"target_job_titles": [
"<string>"
],
"target_industries": [
"<string>"
],
"target_company_sizes": [
"1-10"
],
"target_locations": [
"<string>"
],
"exclude_locations": [
"<string>"
],
"exclude_companies": [
"<string>"
],
"exclude_keywords": [
"<string>"
],
"ai_refinement_prompt": "<string>",
"lead_score_threshold": 123
},
"review_prospects": true,
"exclude_first_degree": true,
"ai_instructions": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}campaigns
Get campaign
One campaign in full: status, totals, and its editable state in the shape update-campaign takes (signals, icp, steps, review_prospects, exclude_first_degree, ai_instructions, linkedin_account), plus its last search and when the next one runs.
GET
/
campaigns
/
{campaign}
Get campaign
curl --request GET \
--url https://app.leadbeast.io/api/v1/campaigns/{campaign} \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.leadbeast.io/api/v1/campaigns/{campaign}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.leadbeast.io/api/v1/campaigns/{campaign}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.leadbeast.io/api/v1/campaigns/{campaign}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.leadbeast.io/api/v1/campaigns/{campaign}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.leadbeast.io/api/v1/campaigns/{campaign}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.leadbeast.io/api/v1/campaigns/{campaign}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"status": "completed",
"id": "<string>",
"name": "<string>",
"campaign_status": "<string>",
"is_on": true,
"leads_found": 123,
"contacted": 123,
"accepted": 123,
"replied": 123,
"pending_approvals": 123,
"linkedin_account": {
"id": "<string>",
"name": "<string>"
},
"steps": [
{
"order": 123,
"type": "connection_request",
"mode": "template",
"message": "<string>",
"with_note": true,
"wait_days": 30
}
],
"last_run": {
"status": "<string>",
"completed_at": "<string>",
"new_leads": 123
},
"next_run_at": "<string>",
"signals": [
{
"type": "ai_signal",
"keyword": "<string>",
"audience": "post_creators",
"signal_name": "<string>",
"qualification_prompt": "<string>",
"template_key": "competitor_engagers",
"source_url": "<string>",
"signal_type": "profile_tracking",
"source_name": "<string>",
"id": "<string>",
"group_id": "<string>"
}
],
"icp": {
"target_job_titles": [
"<string>"
],
"target_industries": [
"<string>"
],
"target_company_sizes": [
"1-10"
],
"target_locations": [
"<string>"
],
"exclude_locations": [
"<string>"
],
"exclude_companies": [
"<string>"
],
"exclude_keywords": [
"<string>"
],
"ai_refinement_prompt": "<string>",
"lead_score_threshold": 123
},
"review_prospects": true,
"exclude_first_degree": true,
"ai_instructions": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}{
"error": {
"status": "completed",
"message": "<string>",
"reason_code": "<string>"
},
"meta": {
"request_id": "<string>",
"replayed": true
}
}