Create Campaign Document
curl --request POST \
--url https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument \
--header 'Content-Type: application/json' \
--header 'X-apikey: <api-key>' \
--data '
{
"CampaignId": 1234567891234567,
"Name": "",
"DocumentTypeId": 1234567891234567,
"FileURL": ""
}
'import requests
url = "https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument"
payload = {
"CampaignId": 1234567891234567,
"Name": "",
"DocumentTypeId": 1234567891234567,
"FileURL": ""
}
headers = {
"X-apikey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-apikey': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
CampaignId: 1234567891234567,
Name: '',
DocumentTypeId: 1234567891234567,
FileURL: ''
})
};
fetch('https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument', 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.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument",
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' => 1234567891234567,
'Name' => '',
'DocumentTypeId' => 1234567891234567,
'FileURL' => ''
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-apikey: <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://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument"
payload := strings.NewReader("{\n \"CampaignId\": 1234567891234567,\n \"Name\": \"\",\n \"DocumentTypeId\": 1234567891234567,\n \"FileURL\": \"\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-apikey", "<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://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument")
.header("X-apikey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"CampaignId\": 1234567891234567,\n \"Name\": \"\",\n \"DocumentTypeId\": 1234567891234567,\n \"FileURL\": \"\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-apikey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"CampaignId\": 1234567891234567,\n \"Name\": \"\",\n \"DocumentTypeId\": 1234567891234567,\n \"FileURL\": \"\"\n}"
response = http.request(request)
puts response.read_body{
"Success": false,
"Message": "",
"Id": 1234567891234567,
"ExternalId": ""
}Campaigns
Create Campaign Document
POST
/
CampaignDocument
Create Campaign Document
curl --request POST \
--url https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument \
--header 'Content-Type: application/json' \
--header 'X-apikey: <api-key>' \
--data '
{
"CampaignId": 1234567891234567,
"Name": "",
"DocumentTypeId": 1234567891234567,
"FileURL": ""
}
'import requests
url = "https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument"
payload = {
"CampaignId": 1234567891234567,
"Name": "",
"DocumentTypeId": 1234567891234567,
"FileURL": ""
}
headers = {
"X-apikey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-apikey': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
CampaignId: 1234567891234567,
Name: '',
DocumentTypeId: 1234567891234567,
FileURL: ''
})
};
fetch('https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument', 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.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument",
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' => 1234567891234567,
'Name' => '',
'DocumentTypeId' => 1234567891234567,
'FileURL' => ''
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-apikey: <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://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument"
payload := strings.NewReader("{\n \"CampaignId\": 1234567891234567,\n \"Name\": \"\",\n \"DocumentTypeId\": 1234567891234567,\n \"FileURL\": \"\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-apikey", "<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://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument")
.header("X-apikey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"CampaignId\": 1234567891234567,\n \"Name\": \"\",\n \"DocumentTypeId\": 1234567891234567,\n \"FileURL\": \"\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/CampaignDocument")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-apikey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"CampaignId\": 1234567891234567,\n \"Name\": \"\",\n \"DocumentTypeId\": 1234567891234567,\n \"FileURL\": \"\"\n}"
response = http.request(request)
puts response.read_body{
"Success": false,
"Message": "",
"Id": 1234567891234567,
"ExternalId": ""
}Authorizations
Body
application/json
Was this page helpful?