curl --request GET \
--url https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey', 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://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$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://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"lead_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "<string>",
"steps": [
{
"node_key": "<string>",
"node_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"sequence_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"step_number": 123,
"email_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"subject": "<string>",
"sent_at": "2023-11-07T05:31:56Z",
"opened_at": "2023-11-07T05:31:56Z",
"bounced_at": "2023-11-07T05:31:56Z",
"scheduled_for": "2023-11-07T05:31:56Z",
"sent": false,
"opened": false,
"bounced": false,
"trigger_invalidated": false,
"message_id": "<string>",
"inbox_email": "<string>"
}
],
"enrollments": [
{
"entry_node_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"entry_edge_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"trigger_reason": "<string>",
"entered_at": "2023-11-07T05:31:56Z"
}
],
"replies": [
{
"reply_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"received_at": "2023-11-07T05:31:56Z",
"subject": "<string>",
"message_id": "<string>",
"in_reply_to": "<string>",
"references": "<string>"
}
],
"current": "<string>",
"next_scheduled": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Get a lead's journey through the campaign
Trace one lead’s path through the campaign step graph
Returns every touchpoint the lead has had, which subsequence branches it entered, its replies, and where it currently sits.
This is the only endpoint that reports subsequence branch emails. GET /campaigns/{id}/leads/{lead_id} walks the linear MAIN chain and drops branch
steps, so a lead that was pulled into a branch looks idle there while it is
actually being emailed.
What comes back
steps[]— one per scheduled or sent email, MAIN and branch alike: subject,scheduled_for,sent_at,opened_at,bounced_at, plustrigger_invalidatedwhen a pending step was cancelled (a manual move into a branch does this to the rest of the MAIN chain),message_idandinbox_email.enrollments[]— each subsequence the lead entered:entry_node_id,entry_edge_id,trigger_reason,entered_at, andcompleted_atonce it has finished the branch.replies[]— with threading headers for step attribution.current/next_scheduled— the derived node keys for where the lead is now and what fires next.
node_key on a step is a stable, human-readable identifier for the graph
position; node_id is the flow node UUID.
Example
import requests
campaign_id = "550e8400-e29b-41d4-a716-446655440000"
lead_id = "650e8400-e29b-41d4-a716-446655440000"
response = requests.get(
f"https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey",
headers={"X-API-Key": "your-api-key"}
)
print(response.json())
curl --request GET \
--url https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey', 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://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$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://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.coldsend.pro/api/public/v1/campaigns/{campaign_id}/leads/{lead_id}/journey")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"lead_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "<string>",
"steps": [
{
"node_key": "<string>",
"node_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"sequence_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"step_number": 123,
"email_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"subject": "<string>",
"sent_at": "2023-11-07T05:31:56Z",
"opened_at": "2023-11-07T05:31:56Z",
"bounced_at": "2023-11-07T05:31:56Z",
"scheduled_for": "2023-11-07T05:31:56Z",
"sent": false,
"opened": false,
"bounced": false,
"trigger_invalidated": false,
"message_id": "<string>",
"inbox_email": "<string>"
}
],
"enrollments": [
{
"entry_node_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"entry_edge_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"trigger_reason": "<string>",
"entered_at": "2023-11-07T05:31:56Z"
}
],
"replies": [
{
"reply_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"received_at": "2023-11-07T05:31:56Z",
"subject": "<string>",
"message_id": "<string>",
"in_reply_to": "<string>",
"references": "<string>"
}
],
"current": "<string>",
"next_scheduled": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
API key with format cs_live_xxx
Response
Journey retrieved successfully
Read-only journey of one lead through a campaign's step graph.
Powers the Lead Journey canvas: steps draw/light the path, enrollments
mark branch jumps, replies attribute a "Replied" marker, and current /
next_scheduled name the lead's present position.
Lead ID
Lead status
Touchpoints in send order
Show child attributes
Show child attributes
Subsequence branch enrollments
Show child attributes
Show child attributes
Replies from the lead
Show child attributes
Show child attributes
node_key of the last sent touchpoint
node_key of the earliest future, unsent, non-invalidated follow-up
Was this page helpful?

