/v2/advertisers
POST
https://<pcm-domain>/v2/advertisers
Body Parameters
- bodyExternalAdvertiserRequestrequired
- namestringMin Length1Max Length100Pattern^(?!\s*$).+
- brandsstring[]
- attributionProfilesstring[]
- archivedboolean
- publisherIdsinteger[]
Responses
200
- AdvertiserBrandOverlapResponse
- idinteger<int32>Formatint32
- namestring
- organizationIdinteger<int32>Formatint32
- organizationNamestring
- publishersIdNameResponse[]
- idinteger<int32>Formatint32
- namestring
- brandsstring[]
- attributionProfilesstring[]
- createdAtstring<date-time>Formatdate-time
- modifiedAtstring<date-time>Formatdate-time
- archivedboolean
- brandAdvertiserOverlapmap<string, string[]>
401
403
422
- ExceptionResponse
- messagesstring[]
curl
curl --request POST \
--url https://<pcm-domain>/v2/advertisers \
--header 'accept: application/json'javascript
var myHeaders = new Headers();
myHeaders.append("accept", "application/json");
myHeaders.append("content-type", "application/json");
var requestOptions = {
method: 'POST',
headers: myHeaders,
redirect: 'follow'
};
fetch("https://<pcm-domain>/v2/advertisers", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));ruby
require "uri"
require "json"
require "net/http"
url = URI("https://<pcm-domain>/v2/advertisers")
https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true
request = Net::HTTP::Post.new(url)
request["accept"] = "application/json"
request["content-type"] = "application/json"
response = https.request(request)
puts response.read_body
python
import requests
import json
url = "https://<pcm-domain>/v2/advertisers"
payload = {}
headers = {
'accept': 'application/json',
'content-type': 'application/json'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
200
// OK
{
"id": "",
"name": "",
"organizationId": "",
"organizationName": "",
"publishers": [
{
"id": "",
"name": ""
}
],
"brands": [
""
],
"attributionProfiles": [
""
],
"createdAt": "",
"modifiedAt": "",
"archived": false,
"brandAdvertiserOverlap": ""
}401
// Unauthorized
403
// Forbidden
422
// Unprocessable Content
{
"messages": [
""
]
}