Update Campaign
curl --request PUT \
--url https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/Campaign \
--header 'Content-Type: application/json' \
--header 'X-apikey: <api-key>' \
--data '
{
"Id": 1234567891234567,
"Name": "",
"ExternalId": "",
"AccountId": 1234567891234567,
"StartDate": "2014-12-31",
"EndDate": "2014-12-31",
"PartnerBudget": 0.1,
"SalesProbability": 0.1,
"CampaignBriefFields": [
{
"FieldName": "",
"FieldValue": ""
}
],
"SourceMarket": 1234567891234567,
"ContractSigned": false,
"CampaignStatusId": 1234567891234567
}
'import requests
url = "https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/Campaign"
payload = {
"Id": 1234567891234567,
"Name": "",
"ExternalId": "",
"AccountId": 1234567891234567,
"StartDate": "2014-12-31",
"EndDate": "2014-12-31",
"PartnerBudget": 0.1,
"SalesProbability": 0.1,
"CampaignBriefFields": [
{
"FieldName": "",
"FieldValue": ""
}
],
"SourceMarket": 1234567891234567,
"ContractSigned": False,
"CampaignStatusId": 1234567891234567
}
headers = {
"X-apikey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-apikey': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
Id: 1234567891234567,
Name: '',
ExternalId: '',
AccountId: 1234567891234567,
StartDate: '2014-12-31',
EndDate: '2014-12-31',
PartnerBudget: 0.1,
SalesProbability: 0.1,
CampaignBriefFields: [{FieldName: '', FieldValue: ''}],
SourceMarket: 1234567891234567,
ContractSigned: false,
CampaignStatusId: 1234567891234567
})
};
fetch('https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/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.uplifthub.io/P195_Exposed_Integrations/rest/V1/Campaign",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'Id' => 1234567891234567,
'Name' => '',
'ExternalId' => '',
'AccountId' => 1234567891234567,
'StartDate' => '2014-12-31',
'EndDate' => '2014-12-31',
'PartnerBudget' => 0.1,
'SalesProbability' => 0.1,
'CampaignBriefFields' => [
[
'FieldName' => '',
'FieldValue' => ''
]
],
'SourceMarket' => 1234567891234567,
'ContractSigned' => false,
'CampaignStatusId' => 1234567891234567
]),
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/Campaign"
payload := strings.NewReader("{\n \"Id\": 1234567891234567,\n \"Name\": \"\",\n \"ExternalId\": \"\",\n \"AccountId\": 1234567891234567,\n \"StartDate\": \"2014-12-31\",\n \"EndDate\": \"2014-12-31\",\n \"PartnerBudget\": 0.1,\n \"SalesProbability\": 0.1,\n \"CampaignBriefFields\": [\n {\n \"FieldName\": \"\",\n \"FieldValue\": \"\"\n }\n ],\n \"SourceMarket\": 1234567891234567,\n \"ContractSigned\": false,\n \"CampaignStatusId\": 1234567891234567\n}")
req, _ := http.NewRequest("PUT", 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.put("https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/Campaign")
.header("X-apikey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"Id\": 1234567891234567,\n \"Name\": \"\",\n \"ExternalId\": \"\",\n \"AccountId\": 1234567891234567,\n \"StartDate\": \"2014-12-31\",\n \"EndDate\": \"2014-12-31\",\n \"PartnerBudget\": 0.1,\n \"SalesProbability\": 0.1,\n \"CampaignBriefFields\": [\n {\n \"FieldName\": \"\",\n \"FieldValue\": \"\"\n }\n ],\n \"SourceMarket\": 1234567891234567,\n \"ContractSigned\": false,\n \"CampaignStatusId\": 1234567891234567\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/Campaign")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-apikey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"Id\": 1234567891234567,\n \"Name\": \"\",\n \"ExternalId\": \"\",\n \"AccountId\": 1234567891234567,\n \"StartDate\": \"2014-12-31\",\n \"EndDate\": \"2014-12-31\",\n \"PartnerBudget\": 0.1,\n \"SalesProbability\": 0.1,\n \"CampaignBriefFields\": [\n {\n \"FieldName\": \"\",\n \"FieldValue\": \"\"\n }\n ],\n \"SourceMarket\": 1234567891234567,\n \"ContractSigned\": false,\n \"CampaignStatusId\": 1234567891234567\n}"
response = http.request(request)
puts response.read_body{
"Success": false,
"Message": "",
"Id": 1234567891234567,
"ExternalId": ""
}Campaigns
Update Campaign
PUT
/
Campaign
Update Campaign
curl --request PUT \
--url https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/Campaign \
--header 'Content-Type: application/json' \
--header 'X-apikey: <api-key>' \
--data '
{
"Id": 1234567891234567,
"Name": "",
"ExternalId": "",
"AccountId": 1234567891234567,
"StartDate": "2014-12-31",
"EndDate": "2014-12-31",
"PartnerBudget": 0.1,
"SalesProbability": 0.1,
"CampaignBriefFields": [
{
"FieldName": "",
"FieldValue": ""
}
],
"SourceMarket": 1234567891234567,
"ContractSigned": false,
"CampaignStatusId": 1234567891234567
}
'import requests
url = "https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/Campaign"
payload = {
"Id": 1234567891234567,
"Name": "",
"ExternalId": "",
"AccountId": 1234567891234567,
"StartDate": "2014-12-31",
"EndDate": "2014-12-31",
"PartnerBudget": 0.1,
"SalesProbability": 0.1,
"CampaignBriefFields": [
{
"FieldName": "",
"FieldValue": ""
}
],
"SourceMarket": 1234567891234567,
"ContractSigned": False,
"CampaignStatusId": 1234567891234567
}
headers = {
"X-apikey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-apikey': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
Id: 1234567891234567,
Name: '',
ExternalId: '',
AccountId: 1234567891234567,
StartDate: '2014-12-31',
EndDate: '2014-12-31',
PartnerBudget: 0.1,
SalesProbability: 0.1,
CampaignBriefFields: [{FieldName: '', FieldValue: ''}],
SourceMarket: 1234567891234567,
ContractSigned: false,
CampaignStatusId: 1234567891234567
})
};
fetch('https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/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.uplifthub.io/P195_Exposed_Integrations/rest/V1/Campaign",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'Id' => 1234567891234567,
'Name' => '',
'ExternalId' => '',
'AccountId' => 1234567891234567,
'StartDate' => '2014-12-31',
'EndDate' => '2014-12-31',
'PartnerBudget' => 0.1,
'SalesProbability' => 0.1,
'CampaignBriefFields' => [
[
'FieldName' => '',
'FieldValue' => ''
]
],
'SourceMarket' => 1234567891234567,
'ContractSigned' => false,
'CampaignStatusId' => 1234567891234567
]),
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/Campaign"
payload := strings.NewReader("{\n \"Id\": 1234567891234567,\n \"Name\": \"\",\n \"ExternalId\": \"\",\n \"AccountId\": 1234567891234567,\n \"StartDate\": \"2014-12-31\",\n \"EndDate\": \"2014-12-31\",\n \"PartnerBudget\": 0.1,\n \"SalesProbability\": 0.1,\n \"CampaignBriefFields\": [\n {\n \"FieldName\": \"\",\n \"FieldValue\": \"\"\n }\n ],\n \"SourceMarket\": 1234567891234567,\n \"ContractSigned\": false,\n \"CampaignStatusId\": 1234567891234567\n}")
req, _ := http.NewRequest("PUT", 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.put("https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/Campaign")
.header("X-apikey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"Id\": 1234567891234567,\n \"Name\": \"\",\n \"ExternalId\": \"\",\n \"AccountId\": 1234567891234567,\n \"StartDate\": \"2014-12-31\",\n \"EndDate\": \"2014-12-31\",\n \"PartnerBudget\": 0.1,\n \"SalesProbability\": 0.1,\n \"CampaignBriefFields\": [\n {\n \"FieldName\": \"\",\n \"FieldValue\": \"\"\n }\n ],\n \"SourceMarket\": 1234567891234567,\n \"ContractSigned\": false,\n \"CampaignStatusId\": 1234567891234567\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.uplifthub.io/P195_Exposed_Integrations/rest/V1/Campaign")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-apikey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"Id\": 1234567891234567,\n \"Name\": \"\",\n \"ExternalId\": \"\",\n \"AccountId\": 1234567891234567,\n \"StartDate\": \"2014-12-31\",\n \"EndDate\": \"2014-12-31\",\n \"PartnerBudget\": 0.1,\n \"SalesProbability\": 0.1,\n \"CampaignBriefFields\": [\n {\n \"FieldName\": \"\",\n \"FieldValue\": \"\"\n }\n ],\n \"SourceMarket\": 1234567891234567,\n \"ContractSigned\": false,\n \"CampaignStatusId\": 1234567891234567\n}"
response = http.request(request)
puts response.read_body{
"Success": false,
"Message": "",
"Id": 1234567891234567,
"ExternalId": ""
}Authorizations
Body
application/json
Example:
1234567891234567
Example:
1234567891234567
Example:
"2014-12-31"
Example:
"2014-12-31"
Example:
0.1
Example:
0.1
Show child attributes
Show child attributes
Example:
1234567891234567
Example:
false
Example:
1234567891234567
Was this page helpful?