curl --request POST \
--url https://api.linkedcamp.com/v2/flow_from_template \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--data '
{
"campaignId": "<string>",
"sequence": "<string>",
"content": {
"longNote": "<string>",
"shortNote": "<string>",
"message1": "<string>",
"message2": "<string>",
"message3": "<string>",
"subject1": "<string>",
"subject2": "<string>",
"subject3": "<string>",
"content1": "<string>",
"content2": "<string>",
"content3": "<string>"
}
}
'import requests
url = "https://api.linkedcamp.com/v2/flow_from_template"
payload = {
"campaignId": "<string>",
"sequence": "<string>",
"content": {
"longNote": "<string>",
"shortNote": "<string>",
"message1": "<string>",
"message2": "<string>",
"message3": "<string>",
"subject1": "<string>",
"subject2": "<string>",
"subject3": "<string>",
"content1": "<string>",
"content2": "<string>",
"content3": "<string>"
}
}
headers = {
"X-Api-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-Api-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
campaignId: '<string>',
sequence: '<string>',
content: {
longNote: '<string>',
shortNote: '<string>',
message1: '<string>',
message2: '<string>',
message3: '<string>',
subject1: '<string>',
subject2: '<string>',
subject3: '<string>',
content1: '<string>',
content2: '<string>',
content3: '<string>'
}
})
};
fetch('https://api.linkedcamp.com/v2/flow_from_template', 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.linkedcamp.com/v2/flow_from_template",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'campaignId' => '<string>',
'sequence' => '<string>',
'content' => [
'longNote' => '<string>',
'shortNote' => '<string>',
'message1' => '<string>',
'message2' => '<string>',
'message3' => '<string>',
'subject1' => '<string>',
'subject2' => '<string>',
'subject3' => '<string>',
'content1' => '<string>',
'content2' => '<string>',
'content3' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.linkedcamp.com/v2/flow_from_template"
payload := strings.NewReader("{\n \"campaignId\": \"<string>\",\n \"sequence\": \"<string>\",\n \"content\": {\n \"longNote\": \"<string>\",\n \"shortNote\": \"<string>\",\n \"message1\": \"<string>\",\n \"message2\": \"<string>\",\n \"message3\": \"<string>\",\n \"subject1\": \"<string>\",\n \"subject2\": \"<string>\",\n \"subject3\": \"<string>\",\n \"content1\": \"<string>\",\n \"content2\": \"<string>\",\n \"content3\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Api-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.linkedcamp.com/v2/flow_from_template")
.header("X-Api-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"campaignId\": \"<string>\",\n \"sequence\": \"<string>\",\n \"content\": {\n \"longNote\": \"<string>\",\n \"shortNote\": \"<string>\",\n \"message1\": \"<string>\",\n \"message2\": \"<string>\",\n \"message3\": \"<string>\",\n \"subject1\": \"<string>\",\n \"subject2\": \"<string>\",\n \"subject3\": \"<string>\",\n \"content1\": \"<string>\",\n \"content2\": \"<string>\",\n \"content3\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.linkedcamp.com/v2/flow_from_template")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Api-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"campaignId\": \"<string>\",\n \"sequence\": \"<string>\",\n \"content\": {\n \"longNote\": \"<string>\",\n \"shortNote\": \"<string>\",\n \"message1\": \"<string>\",\n \"message2\": \"<string>\",\n \"message3\": \"<string>\",\n \"subject1\": \"<string>\",\n \"subject2\": \"<string>\",\n \"subject3\": \"<string>\",\n \"content1\": \"<string>\",\n \"content2\": \"<string>\",\n \"content3\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_bodyusing RestSharp;
var options = new RestClientOptions("https://api.linkedcamp.com/v2/flow_from_template");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("X-Api-Key", "<api-key>");
request.AddJsonBody("{\n \"campaignId\": \"<string>\",\n \"sequence\": \"<string>\",\n \"content\": {\n \"longNote\": \"<string>\",\n \"shortNote\": \"<string>\",\n \"message1\": \"<string>\",\n \"message2\": \"<string>\",\n \"message3\": \"<string>\",\n \"subject1\": \"<string>\",\n \"subject2\": \"<string>\",\n \"subject3\": \"<string>\",\n \"content1\": \"<string>\",\n \"content2\": \"<string>\",\n \"content3\": \"<string>\"\n }\n}", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);
{}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}Apply a prebuilt sequence template
Write. It changes data in your account.
Attach one of the platform’s named sequence templates to a campaign and fill in its copy placeholders. Only works on a campaign that has no flow yet. The template decides which slots exist — supply whichever of longNote, shortNote, message1..3, subject1..3, content1..3 it uses. One of three ways to get a sequence, and the only one that reuses a prebuilt shape: flow_set writes an arbitrary sequence from a step list, and campaign_generate_ai_sequence has the platform draft one from a brief. List the available templates with template_list first — the name is matched against that library. To change the copy afterwards, call flow_set; this endpoint cannot be re-run on a campaign that already has a flow.
curl --request POST \
--url https://api.linkedcamp.com/v2/flow_from_template \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--data '
{
"campaignId": "<string>",
"sequence": "<string>",
"content": {
"longNote": "<string>",
"shortNote": "<string>",
"message1": "<string>",
"message2": "<string>",
"message3": "<string>",
"subject1": "<string>",
"subject2": "<string>",
"subject3": "<string>",
"content1": "<string>",
"content2": "<string>",
"content3": "<string>"
}
}
'import requests
url = "https://api.linkedcamp.com/v2/flow_from_template"
payload = {
"campaignId": "<string>",
"sequence": "<string>",
"content": {
"longNote": "<string>",
"shortNote": "<string>",
"message1": "<string>",
"message2": "<string>",
"message3": "<string>",
"subject1": "<string>",
"subject2": "<string>",
"subject3": "<string>",
"content1": "<string>",
"content2": "<string>",
"content3": "<string>"
}
}
headers = {
"X-Api-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-Api-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
campaignId: '<string>',
sequence: '<string>',
content: {
longNote: '<string>',
shortNote: '<string>',
message1: '<string>',
message2: '<string>',
message3: '<string>',
subject1: '<string>',
subject2: '<string>',
subject3: '<string>',
content1: '<string>',
content2: '<string>',
content3: '<string>'
}
})
};
fetch('https://api.linkedcamp.com/v2/flow_from_template', 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.linkedcamp.com/v2/flow_from_template",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'campaignId' => '<string>',
'sequence' => '<string>',
'content' => [
'longNote' => '<string>',
'shortNote' => '<string>',
'message1' => '<string>',
'message2' => '<string>',
'message3' => '<string>',
'subject1' => '<string>',
'subject2' => '<string>',
'subject3' => '<string>',
'content1' => '<string>',
'content2' => '<string>',
'content3' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.linkedcamp.com/v2/flow_from_template"
payload := strings.NewReader("{\n \"campaignId\": \"<string>\",\n \"sequence\": \"<string>\",\n \"content\": {\n \"longNote\": \"<string>\",\n \"shortNote\": \"<string>\",\n \"message1\": \"<string>\",\n \"message2\": \"<string>\",\n \"message3\": \"<string>\",\n \"subject1\": \"<string>\",\n \"subject2\": \"<string>\",\n \"subject3\": \"<string>\",\n \"content1\": \"<string>\",\n \"content2\": \"<string>\",\n \"content3\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Api-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.linkedcamp.com/v2/flow_from_template")
.header("X-Api-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"campaignId\": \"<string>\",\n \"sequence\": \"<string>\",\n \"content\": {\n \"longNote\": \"<string>\",\n \"shortNote\": \"<string>\",\n \"message1\": \"<string>\",\n \"message2\": \"<string>\",\n \"message3\": \"<string>\",\n \"subject1\": \"<string>\",\n \"subject2\": \"<string>\",\n \"subject3\": \"<string>\",\n \"content1\": \"<string>\",\n \"content2\": \"<string>\",\n \"content3\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.linkedcamp.com/v2/flow_from_template")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Api-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"campaignId\": \"<string>\",\n \"sequence\": \"<string>\",\n \"content\": {\n \"longNote\": \"<string>\",\n \"shortNote\": \"<string>\",\n \"message1\": \"<string>\",\n \"message2\": \"<string>\",\n \"message3\": \"<string>\",\n \"subject1\": \"<string>\",\n \"subject2\": \"<string>\",\n \"subject3\": \"<string>\",\n \"content1\": \"<string>\",\n \"content2\": \"<string>\",\n \"content3\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_bodyusing RestSharp;
var options = new RestClientOptions("https://api.linkedcamp.com/v2/flow_from_template");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("X-Api-Key", "<api-key>");
request.AddJsonBody("{\n \"campaignId\": \"<string>\",\n \"sequence\": \"<string>\",\n \"content\": {\n \"longNote\": \"<string>\",\n \"shortNote\": \"<string>\",\n \"message1\": \"<string>\",\n \"message2\": \"<string>\",\n \"message3\": \"<string>\",\n \"subject1\": \"<string>\",\n \"subject2\": \"<string>\",\n \"subject3\": \"<string>\",\n \"content1\": \"<string>\",\n \"content2\": \"<string>\",\n \"content3\": \"<string>\"\n }\n}", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);
{}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "<string>",
"hint": "<string>"
}
}Body
Response
The result, as JSON. Writes answer { "ok": true, "message": ..., "data": ... }.
The response is of type object.
