{"swagger":"2.0","info":{"version":"2.0.0","title":"StackAdapt API","description":"Use this API to create Native Ads and Campaigns on the StackAdapt Platform","termsOfService":"http://api.stackadapt.com/terms/","contact":{"name":"The StackAdapt Team"}},"tags":[{"name":"Advertiser","description":"Advertiser operations","externalDocs":{"description":"Find more info here","url":"https://swagger.io"}},{"name":"Line Item (Campaign Group)","description":"Line Item operations","externalDocs":{"description":"Find more info here","url":"https://swagger.io"}},{"name":"Campaign","description":"Campaign operations","externalDocs":{"description":"Find more info here","url":"https://swagger.io"}},{"name":"Native Ad","description":"Native Ad operations","externalDocs":{"description":"Find more info here","url":"https://swagger.io"}},{"name":"Conversion Tracker","description":"ConversionTracker operations","externalDocs":{"description":"Find more info here","url":"https://swagger.io"}},{"name":"stats","description":"Stats operations","externalDocs":{"description":"Find more info here","url":"https://swagger.io"}}],"host":"api.stackadapt.com","basePath":"/service/v2","consumes":["application/json"],"produces":["application/json"],"securityDefinitions":{"api_key":{"type":"apiKey","name":"X-Authorization","in":"header"}},"paths":{"Authorization":{"options":{"tags":["General"],"summary":"Authorization","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003eAll API requests must be authenticated by attaching the X-AUTHORIZATION header, with the value being your API Key that you can request for from the Stackadapt team.\u003cbr\u003e\u003cbr\u003eExample:\u003cbr\u003e\u003cbr\u003e\u003cpre\u003e\u003ccode\u003eX-Authorization: 'API_KEY'\u003c/code\u003e\u003c/pre\u003e\u003cbr\u003e\u003cbr\u003e\u003c/div\u003e","operationId":"authorization"}},"Rate Limits":{"options":{"tags":["General"],"summary":"Rate Limits","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003eCurrently, our API rate limit is 150 requests / 30 seconds. In a case of hitting the limit, you will receive an error code `429`.\u003c/div\u003e","operationId":"rate_limits"}},"Scenario 1":{"options":{"tags":["Scenarios"],"summary":"Creating an Advertiser","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003e\u003ch3\u003e Use Case \u003c/h3\u003eI want to create an advertiser so I can start setting up my campaign hierarchy.\u003cbr\u003e\u003ch3\u003e Description \u003c/h3\u003eThe first step into a creating a campaign hierarchy is to create an Advertiser. An 'Advertiser' is basically an agency, or brand name to which all of the Campaign Groups, Campaigns, and Creatives will belong to.\u003cbr\u003e\u003cbr\u003eTo create one, please check \u003ca href='javascript:window.location.assign(`/v2#!/Advertiser/createAdvertiser`); javascript:window.location.reload()'\u003eCreate new Advertiser\u003c/a\u003e endpoint for more detail on what the request requires.\u003c/div\u003e","operationId":"create_advertiser"}},"Scenario 2":{"options":{"tags":["Scenarios"],"summary":"Creating a Campaign Group","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003e\u003ch3\u003e Use Case \u003c/h3\u003eI want to create a campaign group so I can start setting up my campaign hierarchy.\u003cbr\u003e\u003ch3\u003e Description \u003c/h3\u003eThe next step into a creating a campaign hierarchy is to create a Campaign Group. A 'Campaign Group' (formely Line Item) allows for grouping of campaigns as one marketing initiative.This allows you to set over-arching budgets, flight dates, and revenue management parameters to multiple campaigns.\u003cbr\u003e\u003cbr\u003eTo create one, please check \u003ca href='javascript:window.location.assign(`/v2#!/Campaign_Group/createLineItem`); javascript:window.location.reload()'\u003eCreate new Campaign Group\u003c/a\u003e endpoint for more detail on what the request requires.\u003c/div\u003e","operationId":"create_campaign_group"}},"Scenario 3":{"options":{"tags":["Scenarios"],"summary":"Creating a Display Campaign","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003e\u003ch3\u003e Use Case \u003c/h3\u003eI want to create my first display campaign.\u003cbr\u003e\u003ch3\u003e Description \u003c/h3\u003eTo create a display campaign, ensure the \u003ccode\u003etype\u003c/code\u003e parameter in your request is set to \u003ccode\u003edisplay\u003c/code\u003e.Furthermore, ensure that the creatives in the campaign are also \u003ccode\u003edisplay\u003c/code\u003e type, set using \u003ccode\u003etype\u003c/code\u003e parameter.\u003cbr\u003e\u003cbr\u003eYou can also attach an existing creative to the campaign. To do so, in the campaign request body under the \u003ccode\u003eall_native_ads\u003c/code\u003e section, include the ids of the existing creatives in the following format:\u003cbr\u003e\u003cbr\u003e\u003ccode\u003eall_native_ads: [{ \"id\": 1 }, {\"id\": 2 }]\u003c/code\u003e\u003cbr\u003e\u003cbr\u003eTo create a campaign, please check \u003ca href='javascript:window.location.assign(`/v2#!/Campaign/createCampaign`); javascript:window.location.reload()'\u003eCreate new Campaign\u003c/a\u003e endpoint for more detail on what the request requires.\u003cbr\u003e\u003cbr\u003eTo create a creative, please check \u003ca href='javascript:window.location.assign(`/v2#!/Creative/addNativeAd`); javascript:window.location.reload()'\u003eCreate new Creative\u003c/a\u003e endpoint for more detail on what the request requires.\u003cbr\u003e\u003cbr\u003e\u003c/div\u003e","operationId":"create_display_campaign"}},"Scenario 4":{"options":{"tags":["Scenarios"],"summary":"Creating a Display Campaign with JS Tag","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003e\u003ch3\u003e Use Case \u003c/h3\u003eI want to create my first display campaign with a JS Tag.\u003cbr\u003e\u003ch3\u003e Description \u003c/h3\u003eThere are two ways to approach this case.\u003cbr\u003e\u003col\u003e\u003cli\u003eCreate a Creative (formerly known as Native Ad) and then create a Campaign and attach the creative to it.\u003c/li\u003e\u003cli\u003eCreate a Campaign, and within the campaign, create the Creative, which will attach itself to the campaign.\u003c/li\u003e\u003c/ol\u003eWhen creating the creative, ensure to create \u003ccode\u003edisplay_js_creative\u003c/code\u003e array with an object that contains \u003ccode\u003ejs_code\u003c/code\u003e, \u003ccode\u003ewidth\u003c/code\u003e, and \u003ccode\u003eheight\u003c/code\u003e. The \u003ccode\u003ejs_code\u003c/code\u003e should have a click url and any tracker urls implemented in the js code tag itself on top of populating the fields. This will be inside of the \u003ccode\u003einput_data\u003c/code\u003e object.\u003cbr\u003e\u003cbr\u003eYou also need to include the \u003ccode\u003eheading\u003c/code\u003e and \u003ccode\u003etagline\u003c/code\u003e parameters.\u003cbr\u003e\u003cbr\u003eTo add, ensure that you are setting the \u003ccode\u003etype\u003c/code\u003e parameter for both campaign and creative to be \u003ccode\u003edisplay\u003c/code\u003e.\u003cbr\u003e\u003cbr\u003eTo create one, please check \u003ca href='javascript:window.location.assign(`/v2#!/Campaign/createCampaign`); javascript:window.location.reload()'\u003eCreate new Campaign\u003c/a\u003e endpoint and \u003ca href='javascript:window.location.assign(`/v2#!/Creative/addNativeAd`); javascript:window.location.reload()'\u003eCreate new Creative\u003c/a\u003e for more detail on what the request requires.\u003c/div\u003e","operationId":"create_display_js_tag_campaign"}},"Scenario 5":{"options":{"tags":["Scenarios"],"summary":"Upload Files","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003e\u003ch3\u003e Use Case \u003c/h3\u003eI want to upload a file for audience creation or update.\u003cbr\u003e\u003ch3\u003e Description \u003c/h3\u003eIn order to create/update audience (CRM, IP, Location, Device) or geo radius targeting, users need to first upload corresponding files to our services by using response returned from presign endpoint.\u003cbr\u003e\u003cbr\u003e Notes: \u003cbr\u003e\u003col\u003e\u003cli\u003e1. All fields returned by presign endpoint are required in the file uploading, otherwise it would result in 400 bad request.\u003c/li\u003e\u003cli\u003e2. File has to be the last field in the post body. \u003c/li\u003e\u003cli\u003e3. Each file size should not be larger than 1GB, and should not be empty, otherwise it would return 400 bad request.\u003c/li\u003e\u003cli\u003e4. File should be csv file only, otherwise audience creation/update would fail. \u003c/li\u003e\u003cli\u003e5. Content-type of post needs to be \u003ccode\u003emultipart/form-data\u003c/code\u003e\u003c/li\u003e\u003c/ol\u003eThe following code snippet is an example of how files are uploading in ruby on rails (you could choose any other languages)\u003cbody\u003e\u003cpre\u003e\u003ccode\u003e\n    fields = {\n      \"key\"=\u003e \"temp/development/31124ab1-4ab6-4503-846a-d05d3c3255ad\",\n      \"policy\"=\u003e \"eyJleHBpcmF0aW9uIjoiMjAyMi0wNi0xN1QyMzoyMjowNloiLCJjb25kaXRpb25zIjpbeyJidWNrZXQiOiJzYS1saXZlcmFtcC1jcm0tZGV2In0seyJrZXkiOiJ0ZW1wL2RldmVsb3BtZW50LzMxMTI0YWIxLTRhYjYtNDUwMy04NDZhLWQwNWQzYzMyNTVhZCJ9LFsiY29udGVudC1sZW5ndGgtcmFuZ2UiLDEsMl0seyJ4LWFtei1jcmVkZW50aWFsIjoiQUtJQVI0MzdJRk9QNlFaS0pHNVovMjAyMjA2MTcvdXMtZWFzdC0xL3MzL2F3czRfcmVxdWVzdCJ9LHsieC1hbXotYWxnb3JpdGhtIjoiQVdTNC1ITUFDLVNIQTI1NiJ9LHsieC1hbXotZGF0ZSI6IjIwMjIwNjE3VDIyMjIwNloifV19\",\n      \"x-amz-credential\"=\u003e \"AKIAR437IFOP6QZKJG5Z/20220617/us-east-1/s3/aws4_request\",\n      \"x-amz-algorithm\"=\u003e \"AWS4-HMAC-SHA256\",\n      \"x-amz-date\"=\u003e \"20220617T222206Z\",\n      \"x-amz-signature\"=\u003e \"efbc092d49302b861213ac7a252356c004d28269e63e3b07188490dba5ab1aa0\",\n      \"file\" =\u003e File.read(\"file.csv\")\n    }\n\n    uri = URI(\"https://sa-liveramp-crm-dev.s3.amazonaws.com\")\n    request = Net::HTTP::Post.new(uri)\n    request.set_form fields, \"multipart/form-data\"\n\n    response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) do |http|\n      http.request(request)\n    end\n\n    case response\n    when Net::HTTPSuccess\n      puts \"Content uploaded!\"\n    else\n      puts response.value\n    end\n  \u003c/code\u003e\u003c/pre\u003e\u003c/body\u003e\u003cbr\u003e\u003cbr\u003eAnother code snippets example by using curl: \u003cbr\u003e\u003cbody\u003e\u003cpre\u003e\u003ccode\u003e\n    curl -X POST\n      -F key=temp/staging/9753739f-5c48-42d0-b67e-ceae2e865444\n      -F x-amz-signature=18dbd96fb0e6f113963a43974c121f6ff4f39bf7558e5b57ec9ddc6c1306f366\n      -F x-amz-credential=AKIAR437IFOP6QZKJG5Z/20220617/us-east-1/s3/aws4_request\n      -F x-amz-algorithm=AWS4-HMAC-SHA256\n      -F x-amz-date=20220617T222206Z\n      -F file=@file.csv\n      https://sa-liveramp-crm.s3.amazonaws.com\n  \u003c/code\u003e\u003c/pre\u003e\u003c/body\u003e\u003cbr\u003e\u003cbr\u003eFor details, please check \u003ca href='javascript:window.location.assign(`/v2#!/Audience/presignURL`); javascript:window.location.reload()'\u003ePresign\u003c/a\u003e endpoint for Location, IP and Device file uploads and \u003ca href='javascript:window.location.assign(`/v2#!/Audience/presignCRMSegment`); javascript:window.location.reload()'\u003eCRM Presign\u003c/a\u003e endpoint for CRM file uploads.\u003cbr\u003e\u003cbr\u003e\u003c/div\u003e","operationId":"upload_files"}},"Scenario 6":{"options":{"tags":["Scenarios"],"summary":"Create CRM Audience using Data and Attach to Campaign","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003e\u003ch3\u003e Use Case \u003c/h3\u003eI want to create a CRM audience with the first-party data file that I have and add it to a campaign I’ve already created.\u003cbr\u003e\u003ch3\u003e Description \u003c/h3\u003eTo perform this, you will need to follow the following steps.\u003cbr\u003e\u003cbr\u003e\u003cb\u003eStep 1. Upload the CRM data file\u003c/b\u003e\u003cbr\u003e\u003cbr\u003eTo upload the CRM data file follow the steps on \u003ca href='javascript:window.location.assign(`/v2#!/Scenarios/upload_files`); javascript:window.location.reload()'\u003eUpload Audience files\u003c/a\u003e guide and use \u003ca href='javascript:window.location.assign(`/v2#!/Audience/presignCRMSegment`); javascript:window.location.reload()'\u003eGet CRM Segment URL\u003c/a\u003e endpoint to get information on where to upload to. Note down the `file_url` retrieved from the \u003ca href='javascript:window.location.assign(`/v2#!/Audience/presignCRMSegment`); javascript:window.location.reload()'\u003eGet CRM Segment URL\u003c/a\u003e response.\u003cbr\u003e\u003cbr\u003e\u003cb\u003eStep 2. Creating the CRM Audience\u003c/b\u003e\u003cbr\u003e\u003cbr\u003eNext step is to create a CRM audience. We will use \u003ca href='javascript:window.location.assign(`/v2#!/Audience/createCRMAudience`); javascript:window.location.reload()'\u003eCreate CRM Audience\u003c/a\u003e endpoint. Ensure to use the `file_url` attribute from the \u003ca href='javascript:window.location.assign(`/v2#!/Scenarios/upload_files`); javascript:window.location.reload()'\u003eUpload Audience Files\u003c/a\u003e response as the `file_path` parameter in \u003ca href='javascript:window.location.assign(`/v2#!/Audience/createCRMAudience`); javascript:window.location.reload()'\u003eCreate CRM Audience\u003c/a\u003e request. Note down the `identifier` retrieved from the \u003ca href='javascript:window.location.assign(`/v2#!/Audience/createCRMAudience`); javascript:window.location.reload()'\u003eCreate CRM Audience\u003c/a\u003e response.\u003cbr\u003e\u003cbr\u003e\u003cb\u003eStep 3. Attaching the CRM Audience to an existing campaign\u003c/b\u003e\u003cbr\u003e\u003cbr\u003eThe last step is to attach the audience to an existing campaign. First, lets fetch the campaign data using \u003ca href='javascript:window.location.assign(`/v2#!/Campaign/findCampaign`); javascript:window.location.reload()'\u003eFetch Campaign by ID\u003c/a\u003e endpoint. Ensure to note down all of the existing item in the `custom_segments_list`. Now use the \u003ca href='javascript:window.location.assign(`/v2#!/Campaign/updateCampaign`); javascript:window.location.reload()'\u003eUpdate Campaign\u003c/a\u003e endpoint with the body including `custom_segements_list`. The `custom_segments_list` should include the new CRM audience identifier (noted in the previous step) and the existing items from the `custom_segment_lists` fetched from the \u003ca href='javascript:window.location.assign(`/v2#!/Campaign/findCampaign`); javascript:window.location.reload()'\u003eFetch Campaign by ID\u003c/a\u003e endpoint. If you do not include the existing audience identifier then they will be detached from the campaign, only the ones included in the update request will remain.\u003cbr\u003e\u003cbr\u003eThis should update your existing campaign to include the new CRM audience that you just created.\u003c/div\u003e","operationId":"crm_audience"}},"Scenario 7":{"options":{"tags":["Scenarios"],"summary":"Create Location Audience using Data and Attach to Campaign","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003e\u003ch3\u003e Use Case \u003c/h3\u003eI want to create a location audience and add it to a campaign I've already created.\u003cbr\u003e\u003ch3\u003e Description \u003c/h3\u003eTo perform this, you will need to follow the following steps.\u003cbr\u003e\u003cbr\u003e\u003cb\u003eStep 1. Upload the Location audience data file\u003c/b\u003e\u003cbr\u003e\u003cbr\u003eTo upload the location data file follow the steps on \u003ca href='javascript:window.location.assign(`/v2#!/Scenarios/upload_files`); javascript:window.location.reload()'\u003eUpload Audience files\u003c/a\u003e guide and use \u003ca href='javascript:window.location.assign(`/v2#!/Audience/presignURL`); javascript:window.location.reload()'\u003eGet Presigned URL\u003c/a\u003e endpoint to get information on where to upload to. Note down the `file_url` retrieved from the \u003ca href='javascript:window.location.assign(`/v2#!/Audience/presignURL`); javascript:window.location.reload()'\u003eGet Presigned URL\u003c/a\u003e response.\u003cbr\u003e\u003cbr\u003e\u003cb\u003eStep 2. Creating the Local Audience\u003c/b\u003e\u003cbr\u003e\u003cbr\u003eNext step is to create a CRM audience. We will use \u003ca href='javascript:window.location.assign(`/v2#!/Audience/createLocationAudience`); javascript:window.location.reload()'\u003eCreate Local Audience\u003c/a\u003e endpoint. Ensure to use the `file_url` attribute from the \u003ca href='javascript:window.location.assign(`/v2#!/Scenarios/upload_files`); javascript:window.location.reload()'\u003eUpload Audience Files\u003c/a\u003e response as the `file_path` parameter in \u003ca href='javascript:window.location.assign(`/v2#!/Audience/createLocationAudience`); javascript:window.location.reload()'\u003eCreate Local Audience\u003c/a\u003e request. Also ensure to include the csv extension in the name of the file, therefore, the name should be \u003ccode\u003eFileName.csv\u003c/code\u003e, otherwise it would cause error when create/update audience. Note down the `identifier` retrieved from the \u003ca href='javascript:window.location.assign(`/v2#!/Audience/createLocationAudience`); javascript:window.location.reload()'\u003eCreate Local Audience\u003c/a\u003e response.\u003cbr\u003e\u003cbr\u003e\u003cb\u003eStep 3. Attaching the CRM Audience to an existing campaign\u003c/b\u003e\u003cbr\u003e\u003cbr\u003eThe last step is to attach the audience to an existing campaign. First, lets fetch the campaign data using \u003ca href='javascript:window.location.assign(`/v2#!/Campaign/findCampaign`); javascript:window.location.reload()'\u003eFetch Campaign by ID\u003c/a\u003e endpoint. Ensure to note down all of the existing item in the `custom_segments_list`. Now use the \u003ca href='javascript:window.location.assign(`/v2#!/Campaign/updateCampaign`); javascript:window.location.reload()'\u003eUpdate Campaign\u003c/a\u003e endpoint with the body including `custom_segements_list`. The `custom_segments_list` should include the new local audience identifier (noted in the previous step) and the existing items from the `custom_segment_lists` fetched from the \u003ca href='javascript:window.location.assign(`/v2#!/Campaign/findCampaign`); javascript:window.location.reload()'\u003eFetch Campaign by ID\u003c/a\u003e endpoint. If you do not include the existing audience identifier then they will be detached from the campaign, only the ones included in the update request will remain.\u003cbr\u003e\u003cbr\u003eThis should update your existing campaign to include the new local audience that you just created.\u003c/div\u003e","operationId":"location_audience"}},"Scenario 8":{"options":{"tags":["Scenarios"],"summary":"Get Campaign Group Total Stats","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003e\u003ch3\u003e Use Case \u003c/h3\u003eI want to get total stats for all campaigns on my account for a specific campaign group.\u003cbr\u003e\u003ch3\u003e Description \u003c/h3\u003eGet stats for a campaign group would aggregate the stats of each campaign belongs to that campaign group. To get the campaign group data, set the `resource` to `line_item` (this is the old name for campaign group). You will also need to set the `type` to `total` and `group_by_resource` to `campaign`. Lastly, do not forget to add the `id` for the campaign group.\u003cbr\u003e\u003cbr\u003eFor details, please check \u003ca href='javascript:window.location.assign(`/v2#!/Stats/getStats`); javascript:window.location.reload()'\u003eStats\u003c/a\u003e endpoint.\u003cbr\u003e\u003cbr\u003e\u003c/div\u003e","operationId":"get_total_stats"}},"Scenario 9":{"options":{"tags":["Scenarios"],"summary":"Create and Attach Geo Radius to a Campaign","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003e\u003ch3\u003e Use Case \u003c/h3\u003eI want to create a geo targeted campaign by creating and attaching geo targeting to a campaign.\u003cbr\u003e\u003ch3\u003e Description \u003c/h3\u003eTo perform this, you will need to follow the following steps.\u003cbr\u003e\u003cbr\u003e\u003cb\u003eStep 1. Upload the Geo target data file\u003c/b\u003e\u003cbr\u003e\u003cbr\u003eTo upload the geo target data file follow the steps on \u003ca href='javascript:window.location.assign(`/v2#!/Scenarios/upload_files`); javascript:window.location.reload()'\u003eUpload Audience files\u003c/a\u003e guide and use \u003ca href='javascript:window.location.assign(`/v2#!/Targeting/getPresignedGeoRadiusUrl`); javascript:window.location.reload()'\u003eGet Presigned URL\u003c/a\u003e endpoint to get information on where to upload to. Note down the `file_url` retrieved from the \u003ca href='javascript:window.location.assign(`/v2#!/Targeting/getPresignedGeoRadiusUrl`); javascript:window.location.reload()'\u003eCampaign Geo Radius Targeting Presigned URL\u003c/a\u003e response. Note down the \u003ccode\u003ekey\u003c/code\u003e and \u003ccode\u003eurl\u003c/code\u003e for later use.\u003cbr\u003e\u003cbr\u003e\u003cb\u003eStep 2. Attaching it to a campaign\u003c/b\u003e\u003cbr\u003e\u003cbr\u003eNext step is to create/attach the geo target to the campaign. We can attach this to a campaign or add it to a new campaign using their respective requests. Within the create campaign or update campaign request, use the \u003ccode\u003egeo_radius_targeting\u003c/code\u003e parameter in the body of the request. For the \u003ccode\u003efile_name\u003c/code\u003e, ensure that it ends with \".csv\". Lastly for the \u003ccode\u003efile_url\u003c/code\u003e, combine the url and key from the step above using \"/\" to form a valid URL.\u003c/div\u003e","operationId":"attach_geo_radius"}},"Deprecation 1":{"options":{"tags":["Deprecations"],"summary":"Two-Year Lookback Limit on Insights Reporting","description":"\u003cdiv style='color: black; font-size: 16px; line-height:20px'\u003e\u003ctable style='border-collapse: collapse; margin-bottom: 16px'\u003e\u003ctr\u003e\u003cth style='border: 1px solid #d0d0d0; padding: 6px 12px; text-align: left; background-color: #f5f5f5'\u003eField\u003c/th\u003e\u003cth style='border: 1px solid #d0d0d0; padding: 6px 12px; text-align: left; background-color: #f5f5f5'\u003eValue\u003c/th\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd style='border: 1px solid #d0d0d0; padding: 6px 12px'\u003eAnnounced\u003c/td\u003e\u003ctd style='border: 1px solid #d0d0d0; padding: 6px 12px'\u003e2026-09-29\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd style='border: 1px solid #d0d0d0; padding: 6px 12px'\u003eEffective\u003c/td\u003e\u003ctd style='border: 1px solid #d0d0d0; padding: 6px 12px'\u003e2026-11-02\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd style='border: 1px solid #d0d0d0; padding: 6px 12px'\u003eType\u003c/td\u003e\u003ctd style='border: 1px solid #d0d0d0; padding: 6px 12px'\u003eBreaking — behavioral change\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd style='border: 1px solid #d0d0d0; padding: 6px 12px'\u003eAffects\u003c/td\u003e\u003ctd style='border: 1px solid #d0d0d0; padding: 6px 12px'\u003e\u003ca href='javascript:window.location.assign(`/v2#!/Stats/getInsightStats`); javascript:window.location.reload()'\u003eGet Insight Stats\u003c/a\u003e\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd style='border: 1px solid #d0d0d0; padding: 6px 12px'\u003eReplacement\u003c/td\u003e\u003ctd style='border: 1px solid #d0d0d0; padding: 6px 12px'\u003e\u003ccode\u003edate_range_type=prev_two_years\u003c/code\u003e, or \u003ccode\u003ecustom\u003c/code\u003e with dates within the two-year window\u003c/td\u003e\u003c/tr\u003e\u003c/table\u003e\u003ch3\u003e What is being deprecated \u003c/h3\u003eRequesting insights data older than two years, whether through \u003ccode\u003edate_range_type=all_time\u003c/code\u003e, an omitted \u003ccode\u003edate_range_type\u003c/code\u003e, or a \u003ccode\u003ecustom\u003c/code\u003e range that starts more than two years ago.\u003cbr\u003e\u003ch3\u003e Behavior on and after November 2, 2026 \u003c/h3\u003e\u003cul\u003e\u003cli\u003e\u003ccode\u003edate_range_type=all_time\u003c/code\u003e returns an error directing you to \u003ccode\u003eprev_two_years\u003c/code\u003e.\u003c/li\u003e\u003cli\u003eAn omitted \u003ccode\u003edate_range_type\u003c/code\u003e defaults to \u003ccode\u003eprev_two_years\u003c/code\u003e instead of \u003ccode\u003eall_time\u003c/code\u003e.\u003c/li\u003e\u003cli\u003eA \u003ccode\u003ecustom\u003c/code\u003e range whose \u003ccode\u003estart_date\u003c/code\u003e is earlier than the cutoff returns an error. Ranges fully within the window are unchanged.\u003c/li\u003e\u003cli\u003eThe cutoff is account-local (today minus two calendar years) inclusive.\u003c/li\u003e\u003c/ul\u003e\u003ch3\u003e How to migrate \u003c/h3\u003e\u003col\u003e\u003cli\u003eIf you send \u003ccode\u003edate_range_type=all_time\u003c/code\u003e or omit it, switch to \u003ccode\u003edate_range_type=prev_two_years\u003c/code\u003e. It is available today and keeps working after November 2.\u003c/li\u003e\u003cli\u003eIf you send \u003ccode\u003edate_range_type=custom\u003c/code\u003e, confirm \u003ccode\u003estart_date\u003c/code\u003e is no earlier than two years before the request date.\u003c/li\u003e\u003cli\u003eRetrieve and store any data older than two years that you rely on before November 2, 2026.\u003c/li\u003e\u003c/ol\u003e\u003c/div\u003e","operationId":"insights_two_year_lookback"}},"/campaigns":{"get":{"tags":["Campaign"],"summary":"Return all Campaigns","description":"Returns all campaigns that the user has access to.","operationId":"findCampaigns","produces":["application/json"],"parameters":[{"name":"page","in":"path","description":"Page of results. Will return first page if not provided (each page contains 30 results)","required":false,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Campaign response","schema":{"type":"object","properties":{"object":{"type":"string","description":"The type of object in the response","default":"campaign"},"page":{"type":"int64","description":"Page indicator","default":1},"total_campaigns":{"type":"int64","description":"Total number of campaigns","default":1},"data":{"type":"array","items":{"$ref":"#/definitions/CampaignResponse"},"description":"Campaigns"}}}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/campaign/{id}":{"get":{"tags":["Campaign"],"summary":"Find Campaign by id","description":"Returns a specific campaign with the corresponding id from the system that the user has access to","operationId":"findCampaign","produces":["application/json"],"parameters":[{"name":"id","in":"path","description":"Id of campaign","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Campaign response","schema":{"$ref":"#/definitions/CampaignResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Campaign not found"}}},"put":{"tags":["Campaign"],"summary":"Update existing Campaign","description":"Updates an existing campaign.","operationId":"updateCampaign","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of campaign","required":true,"type":"integer","format":"int32"},{"name":"campaign","in":"body","description":"Campaign","required":true,"schema":{"$ref":"#/definitions/CampaignUpdateRequest"}}],"responses":{"200":{"description":"campaign response","schema":{"$ref":"#/definitions/CampaignResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Campaign not found"}}},"delete":{"tags":["Campaign"],"summary":"Archive a Campaign","description":"Archives a campaign.","operationId":"archiveCampaign","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of campaign","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Archive Campaign response","schema":{"$ref":"#/definitions/ArchiveaCampaignResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Campaign not found"}}}},"/campaign":{"post":{"tags":["Campaign"],"summary":"Create new Campaign","description":"Creates a new campaign","operationId":"createCampaign","produces":["application/json"],"deprecated":true,"parameters":[{"name":"campaign","in":"body","description":"Campaign","required":true,"schema":{"$ref":"#/definitions/CampaignCreateRequest"}}],"responses":{"200":{"description":"campaign response","schema":{"$ref":"#/definitions/CampaignResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/campaign_targeting/stackadapt_segments":{"get":{"tags":["Targeting"],"summary":"Campaign StackAdapt Segment options","description":"List all stackadapt_segment options is a jstree form.","operationId":"getStackadaptSegments","produces":["application/json"]}},"/campaign_targeting/custom_segments":{"get":{"tags":["Targeting"],"summary":"Campaign Custom Segment options","description":"List all custom_segment options available for your account in the format [{identifier: \u003cid\u003e, name: \u003cname\u003e}].","operationId":"getCustomSegments","produces":["application/json"]}},"/campaign_targeting/supply_sources":{"get":{"tags":["Targeting"],"summary":"Campaign Supply Source options","description":"List all supply_sources available for your account in the format [{id: \u003cid\u003e, name: \u003cname\u003e}].","operationId":"getSupplySources","produces":["application/json"]}},"/campaign_targeting/presigned_geo_radius_url":{"get":{"tags":["Targeting"],"summary":"Campaign Geo Radius Targeting Presigned URL","description":"Get a presigned URL that you can upload (POST) a geographic radius targeting file to. We support two types of geo radius targeting. We can eiteher target by address and radius or latitude, longitude and radius. The CSV formats are as follows: \u003ccode\u003elatitude,longitude,radius\u003c/code\u003e or \u003ccode\u003eaddress,radius\u003c/code\u003e, with no header row. A file with an invalid row is rejected when the campaign is saved.","operationId":"getPresignedGeoRadiusUrl","produces":["application/json"]}},"/line_items":{"get":{"tags":["Campaign Group"],"summary":"Return all Campaign Groups","description":"Returns all Campaign Groups that the user has access to.","operationId":"findLineItems","produces":["application/json"],"parameters":[{"name":"page","in":"path","description":"Page of results. Will return first page if not provided (each page contains 30 results)","required":false,"type":"integer","format":"int32"},{"name":"advertiser_id","in":"path","description":"(optional) Id of advertiser to list underlying campaign groups","type":"integer","format":"int32"}],"responses":{"200":{"description":"Campaign Group response","schema":{"type":"object","properties":{"object":{"type":"string","description":"The type of object in the response","default":"campaign_group"},"page":{"type":"int64","description":"Page indicator","default":1},"total_line_items":{"type":"int64","description":"Total number of Campaign Groups","default":1},"data":{"type":"array","items":{"$ref":"#/definitions/CampaignGroupResponse"},"description":"Campaign Groups"}}}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/line_item/{id}":{"get":{"tags":["Campaign Group"],"summary":"Find Campaign Group by id","description":"Returns a specific Campaign Group with the corresponding id that the user has access to.","operationId":"findLineItem","produces":["application/json"],"parameters":[{"name":"id","in":"path","description":"Id of campaign group","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Campaign group response","schema":{"$ref":"#/definitions/CampaignGroupResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Campaign Group not found"}}},"put":{"tags":["Campaign Group"],"summary":"Update existing Campaign Group","description":"Updates an existing Campaign Group.","operationId":"updateLineItem","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of campaign group","required":true,"type":"integer","format":"int32"},{"name":"campaign_group","in":"body","description":"Campaign Group","required":true,"schema":{"$ref":"#/definitions/CampaignGroupRequest"}}],"responses":{"200":{"description":"Campaign Group response","schema":{"$ref":"#/definitions/CampaignGroupResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Campaign Group not found"}}},"delete":{"tags":["Campaign Group"],"summary":"Delete a Campaign Group","description":"Deletes a Campaign Group","operationId":"deleteLineItem","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of a Campaign Group","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Delete Campaign Group response","schema":{"$ref":"#/definitions/DeleteCampaignGroupResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Campaign Group not found"}}}},"/line_item":{"post":{"tags":["Campaign Group"],"summary":"Create new Campaign Group","description":"Creates a new Campaign Group.","operationId":"createLineItem","produces":["application/json"],"deprecated":true,"parameters":[{"name":"campaign_group","in":"body","description":"LineItem","required":true,"schema":{"$ref":"#/definitions/CampaignGroupRequest"}}],"responses":{"200":{"description":"line_item response","schema":{"$ref":"#/definitions/CampaignGroupResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/advertisers":{"get":{"tags":["Advertiser"],"summary":"Returns all Advertisers","description":"Returns all advertisers that the user has access to.","operationId":"findAdvertisers","produces":["application/json"],"parameters":[{"name":"page","in":"path","description":"Page of results. Will return first page if not provided (each page contains 30 results)","required":false,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Advertiser response","schema":{"type":"object","properties":{"object":{"type":"string","description":"The type of object in the response","default":"Advertiser"},"page":{"type":"int64","description":"Page indicator","default":1},"total_advertisers":{"type":"int64","description":"Total number of advertisers","default":1},"data":{"type":"array","items":{"$ref":"#/definitions/AdvertiserResponse"},"description":"Advertisers"}}}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/advertiser/{id}":{"get":{"tags":["Advertiser"],"summary":"Find Advertiser by id","description":"Returns a specific advertiser with the corresponding id that the user has access to.","operationId":"findAdvertiser","produces":["application/json"],"parameters":[{"name":"id","in":"path","description":"Id of advertiser","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"advertiser response","schema":{"$ref":"#/definitions/AdvertiserResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Advertiser not found"}}},"delete":{"tags":["Advertiser"],"summary":"Archive an Advertiser","description":"Archives an Advertiser.","operationId":"archiveAdvertiser","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of advertiser","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Archive Advertiser response","schema":{"$ref":"#/definitions/ArchiveAndRestoreAdvertiserResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Advertiser not found"}}},"put":{"tags":["Advertiser"],"summary":"Update existing Advertiser","description":"Update an existing Advertiser.","operationId":"updateAdvertiser","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of Advertiser","required":true,"type":"integer","format":"int32"},{"name":"advertiser","in":"body","description":"Advertiser","required":true,"schema":{"$ref":"#/definitions/AdvertiserRequest"}}],"responses":{"200":{"description":"advertiser response","schema":{"$ref":"#/definitions/UpdateSubAdvertiserResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Advertiser not found"}}}},"/advertiser/{id}/restore":{"put":{"tags":["Advertiser"],"summary":"Restore an Advertiser","description":"Restores an Advertiser.","operationId":"restoreAdvertiser","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of archived advertiser","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Restore Advertiser response","schema":{"$ref":"#/definitions/ArchiveAndRestoreAdvertiserResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Archived advertiser not found"}}}},"/advertiser":{"post":{"tags":["Advertiser"],"summary":"Create new Advertiser","description":"Create a new Advertiser.","operationId":"createAdvertiser","produces":["application/json"],"deprecated":true,"parameters":[{"name":"advertiser","in":"body","description":"Advertiser","required":true,"schema":{"$ref":"#/definitions/CreateAdvertiserRequest"}}],"responses":{"200":{"description":"advertiser response","schema":{"$ref":"#/definitions/AdvertiserResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/conversion_trackers":{"get":{"tags":["Conversion Tracker"],"summary":"Returns all Conversion Trackers","description":"Returns all conversion trackers that the user has access to.","operationId":"findConversionTrackers","produces":["application/json"],"parameters":[{"name":"page","in":"path","description":"Page of results. Will return first page if not provided (each page contains 30 results)","required":false,"type":"integer","format":"int32"}],"responses":{"200":{"description":"conversion tracker response","schema":{"type":"object","properties":{"object":{"type":"string","description":"The type of object in the response","default":"conversion tracker"},"page":{"type":"int64","description":"Page indicator","default":1},"total_conversion_trackers":{"type":"int64","description":"Total number of conversion trackers","default":1},"data":{"type":"array","items":{"$ref":"#/definitions/ConversionTracker"},"description":"Conversion Trackers"}}}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/conversion_tracker/{id}":{"get":{"tags":["Conversion Tracker"],"summary":"Find Conversion Tracker by id","description":"Returns a conversion tracker that the user has access to.","operationId":"findConversionTracker","produces":["application/json"],"parameters":[{"name":"id","in":"path","description":"Id of conversion_tracker","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Conversion Tracker response","schema":{"$ref":"#/definitions/ConversionTracker"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Conversion Tracker not found"}}},"put":{"tags":["Conversion Tracker"],"summary":"Update exisiting Conversion Tracker","description":"Updates an existing Conversion Tracker.","operationId":"updateConversionTracker","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of conversion_tracker","required":true,"type":"integer","format":"int32"},{"name":"tracker","in":"body","description":"ConversionTracker","required":true,"schema":{"$ref":"#/definitions/UpdateConversionTrackerRequest"}}],"responses":{"200":{"description":"Conversion Tracker response","schema":{"$ref":"#/definitions/ConversionTracker"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Conversion Tracker not found"}}},"delete":{"tags":["Conversion Tracker"],"summary":"Delete a Conversion Tracker","description":"Deletes a conversion tracker that the user has access to.","operationId":"deleteConversionTrackers","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of conversion_tracker","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Delete Conversion Tracker response","schema":{"$ref":"#/definitions/DeleteCoversionTrackerResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Conversion Tracker not found"}}}},"/conversion_tracker":{"post":{"tags":["Conversion Tracker"],"summary":"Create new Conversion Tracker","description":"Creates a new Conversion Tracker.","operationId":"createConversionTracker","produces":["application/json"],"deprecated":true,"parameters":[{"name":"tracker","in":"body","description":"ConversionTracker","required":true,"schema":{"$ref":"#/definitions/ConversionTrackerRequest"}}],"responses":{"200":{"description":"Conversion Tracker response","schema":{"$ref":"#/definitions/ConversionTracker"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/native_ads":{"get":{"tags":["Creative"],"summary":"Returns all Creatives","description":"Returns all creatives that the user has access to.","operationId":"findNativeAds","produces":["application/json"],"parameters":[{"name":"page","in":"path","description":"Page of results. Will return first page if not provided (each page contains 60 results)","required":false,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Creative response","schema":{"type":"object","properties":{"object":{"type":"string","description":"The type of object in the response","default":"native_ad"},"page":{"type":"int64","description":"Page indicator","default":1},"total_native_ads":{"type":"int64","description":"Total number of creatives","default":1},"data":{"type":"array","items":{"$ref":"#/definitions/NativeAdResponse"},"description":"Creatives"}}}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/native_ad/{id}":{"get":{"tags":["Creative"],"summary":"Find Creative by id","description":"Returns a specific creative with the corresponding id that the user has access to.","operationId":"findNativeAd","produces":["application/json"],"parameters":[{"name":"id","in":"path","description":"Id of creative","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Creative response","schema":{"$ref":"#/definitions/NativeAdResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Creative not found"}}},"put":{"tags":["Creative"],"summary":"Update existing Creative","description":"Updates an existing creative.","operationId":"updateNativeAd","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of creative","required":true,"type":"integer","format":"int32"},{"name":"native_ad","in":"body","description":"Creative","required":true,"schema":{"$ref":"#/definitions/UpdateCreativeRequest"}}],"responses":{"200":{"description":"Creative response","schema":{"$ref":"#/definitions/NativeAdResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Creative not found"}}},"delete":{"tags":["Creative"],"summary":"Delete a Creative","description":"Deletes an existing creative.","operationId":"deleteNativeAd","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of creative","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Delete Creative response","schema":{"$ref":"#/definitions/DeleteCreativeResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Creative not found"}}}},"/native_ad":{"post":{"tags":["Creative"],"summary":"Create new Creative","description":"Creates a new creative.","operationId":"addNativeAd","produces":["application/json"],"deprecated":true,"parameters":[{"name":"native_ad","in":"body","description":"Creative","required":true,"schema":{"$ref":"#/definitions/CreateCreativeRequest"}}],"responses":{"200":{"description":"Creative response","schema":{"$ref":"#/definitions/NativeAdResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/audience/{id}":{"get":{"tags":["Audience"],"summary":"Find Audience by id","description":"Returns a specific audience with the corresponding id that the user has access to.","operationId":"findAudience","produces":["application/json"],"parameters":[{"name":"id","in":"path","description":"Id of audience to return","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Audience response","schema":{"$ref":"#/definitions/Audience"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Audience not found"}}},"delete":{"tags":["Audience"],"summary":"Delete an Audience","description":"Deletes an audience","operationId":"deleteAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of an Audience to delete","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Delete Audience response","schema":{"$ref":"#/definitions/DeleteAudienceResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Audience was not found"}}}},"/audiences":{"get":{"tags":["Audience"],"summary":"Return all Audience","description":"Returns all audience that the user has access to.","operationId":"findAudiences","produces":["application/json"],"parameters":[{"name":"page","in":"path","description":"Page of results. Will return first page if not provided (each page contains 30 results)","required":false,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Audience response","schema":{"type":"object","properties":{"object":{"type":"string","description":"The type of object in the response","default":"audience"},"page":{"type":"int64","description":"Page indicator","default":1},"total_line_items":{"type":"int64","description":"Total number of audiences","default":1},"data":{"type":"array","items":{"$ref":"#/definitions/Audience"},"description":"Audience"}}}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/audience/presign":{"get":{"tags":["Audience"],"summary":"Get Audience Presigned Post Response","description":"Get presigned post response for uploading files. A presigned post response consists of a host name, a key, a file_url and required fields to upload file.\u003cbr\u003e\u003cbr\u003eNote: \u003cbr\u003e\u003col\u003e\u003cli\u003e\u003cb\u003eLocation\u003c/b\u003e: File type: CSV / Data Type: Address, Radius or Latitude, Longitude, Radius. Sample template could be found \u003ca target=\"_blank\" href=\"https://docs.google.com/spreadsheets/d/1zowEzg9LK_jvg6DrVZkjm_UZO6bdp4oHHg0CNs7nR_E/edit?usp=sharing\"\u003e here \u003c/a\u003e.\u003c/li\u003e\u003cli\u003e\u003cb\u003eIP\u003c/b\u003e: File type: CSV / Data format: 1st column contains a min of 1 record / File size: 1GB max file size. \u003ca target=\"_blank\" href=\"https://support.stackadapt.com/hc/en-us/articles/360058300613\"\u003e Learn More \u003c/a\u003e\u003c/li\u003e\u003cli\u003e\u003cb\u003eDevice\u003c/b\u003e: File type: CSV / Data format: 1st column contains a min of 1 record / File size: 1GB max file size. \u003ca target=\"_blank\" href=\"https://support.stackadapt.com/hc/en-us/articles/360058300573\"\u003e Learn More \u003c/a\u003e\u003c/li\u003e\u003c/ol\u003e\u003cbr\u003e\u003cbr\u003eNote: You are uploading data (“Audience Data”) to (a) create a custom audience segment and (b) use the custom audience segment to target ads to individuals associated with the Audience Data (collectively, “Purposes”). By uploading Audience Data you warrant and represent that you (i) have acquired the Audience Data in accordance with applicable laws including GDPR and CCPA; (ii) are entitled to use the Audience Data for the Purposes, and (iii) can and do grant a license to StackAdapt and StackAdapt’s data partner(s) to use the Audience Data for the Purposes.","operationId":"presignURL","produces":["application/json"],"responses":{"200":{"description":"Presign creation response","schema":{"$ref":"#/definitions/PresignResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/insights":{"get":{"tags":["Stats"],"summary":"Get Insight Stats","description":"Returns insight stats on user query. As of November 2, 2026, returns a maximum of two years of data; see Deprecations.","operationId":"getInsightStats","produces":["application/json"],"parameters":[{"name":"resource_type","in":"query","description":"The resource type to retrieve.","enum":["campaign","campaign_group"],"required":true,"type":"string"},{"name":"type","in":"query","description":"The type of stats to retrieve.","enum":["audiences","bid_factors","categories","creative_tactics","deals","demographics","devices","geos","retargeting_segments","supply_sources","audiences_abs"],"required":true,"type":"string"},{"name":"id","in":"query","description":"Id of resource","type":"integer","format":"int32"},{"name":"date_range_type","in":"query","description":"The date range type. Defaults to `all_time`. `all_time` is deprecated and remains accepted with its current unbounded behavior; `prev_two_years` is its replacement and uses the account timezone, from today minus two calendar years through today (both inclusive), overriding supplied start_date and end_date. Omitted-date defaults and rejection of dates before the two-year cutoff are deferred until November 2, 2026, following at least 30 days of notice; see Deprecations.","enum":["all_time","custom","prev_two_years"],"required":false,"type":"string"},{"name":"start_date","in":"query","description":"The start date in the format of \"yyyy-mm-dd\". The start date is required if `date_range_type` is `custom`.","type":"string","format":"date"},{"name":"end_date","in":"query","description":"The end date in the format of \"yyyy-mm-dd\". The end date is required if `date_range_type` is `custom`.","type":"string","format":"date"}],"responses":{"200":{"description":"Insight response","schema":{"type":"object","$ref":"#/definitions/InsightStatsResponse"}}}}},"/delivery":{"get":{"tags":["Stats"],"summary":"Get Delivery Stats","description":"Returns delivery stats on user query.","operationId":"getDeliveryStats","produces":["application/json"],"parameters":[{"name":"resource_type","in":"query","description":"The resource type to retrieve.","enum":["campaign","campaign_group","conversion_tracker","native_ad","advertiser"],"required":true,"type":"string"},{"name":"type","in":"query","description":"The type of stats to retrieve. This API does not support `domain`, please refer to Insights GQL API.","enum":["total","daily","hourly"],"required":true,"type":"string"},{"name":"id","in":"query","description":"Id of resource","type":"integer","format":"int32"},{"name":"date_range_type","in":"query","description":"The date range type. Defaults to `all_time`.","enum":["all_time","custom"],"required":true,"type":"string"},{"name":"start_date","in":"query","description":"The start date in the format of \"yyyy-mm-dd\". The start date is required if you are pulling daily or hourly stats.","type":"string","format":"date"},{"name":"end_date","in":"query","description":"The end date in the format of \"yyyy-mm-dd\". The end date is required if you are pulling daily or hourly stats.","type":"string","format":"date"},{"name":"group_by_resource","in":"query","description":"Group by resource types. Not available when \"conversion_tracker\" is the resource_type.","enum":["campaign","line_item","native_ad","advertiser"],"required":true,"type":"string"}],"responses":{"200":{"description":"Delivery response","schema":{"type":"object","$ref":"#/definitions/DeliveryStatsResponse"}}}}},"/audience/ip":{"post":{"tags":["Audience"],"summary":"Create new IP Audience","description":"Create an IP audience.","operationId":"createIPAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"ip_audience","in":"body","description":"IP Audience","required":true,"schema":{"$ref":"#/definitions/IPAudience"}}],"responses":{"200":{"description":"IP audience response","schema":{"$ref":"#/definitions/IPAudience"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/audience/ip/{id}":{"put":{"tags":["Audience"],"summary":"Update existing IP Audience","description":"Updates existing IP audience.","operationId":"updateIPAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of IP Audience","required":true,"type":"integer","format":"int64"},{"name":"ip_audience","in":"body","description":"IP Audience body","required":true,"schema":{"$ref":"#/definitions/IPAudience"}}],"responses":{"200":{"description":"Updated IP Audience","schema":{"$ref":"#/definitions/Audience"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"IP Audience not found"}}}},"/audience/device":{"post":{"tags":["Audience"],"summary":"Create new Device Audience","description":"Create a new device audience.","operationId":"createDeviceAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"device_audience","in":"body","description":"Device Audience","required":true,"schema":{"$ref":"#/definitions/DeviceAudience"}}],"responses":{"200":{"description":"Device Audience response","schema":{"$ref":"#/definitions/Audience"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/audience/device/{id}":{"put":{"tags":["Audience"],"summary":"Update existing Device Audience","description":"Update an existing device audience.","operationId":"updateDeviceAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of Device Audience","required":true,"type":"integer","format":"int64"},{"name":"device_audience","in":"body","description":"Device Audience patch","required":true,"schema":{"$ref":"#/definitions/DeviceAudience"}}],"responses":{"200":{"description":"Updated Device Audience","schema":{"$ref":"#/definitions/DeviceAudience"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Device Audience not found"}}}},"/audience/crm":{"post":{"tags":["Audience"],"summary":"Create new CRM Audience","description":"Create a new CRM audience.","operationId":"createCRMAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"crm_audience","in":"body","description":"CRM Audience","required":true,"schema":{"$ref":"#/definitions/CreateCRMAudience"}}],"responses":{"200":{"description":"CRM Audience response","schema":{"$ref":"#/definitions/Audience"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/audience/crm/{id}":{"put":{"tags":["Audience"],"summary":"Update existing CRM Audience","description":"Update an existing CRM audience.","operationId":"updateCRMAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"crm_audience","in":"body","description":"CRM Audience","required":true,"schema":{"$ref":"#/definitions/UpdateCRMAudience"}}],"responses":{"200":{"description":"CRM Audience response","schema":{"$ref":"#/definitions/Audience"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/audience/crm/presign":{"get":{"tags":["Audience"],"summary":"Get CRM Audience Presigned Post Response","description":"A presigned post response consists of a host name, a key and required fields to upload file.\u003cbr\u003e\u003cbr\u003eMinimum of 100 unique records sharing the same identifier type (at least 1000 is recommended). The minimum applies per identifier type rather than to the total number of rows, so a file holding 100 rows of type:email and 60 rows of type:first_last_phone counts as 100 records, not 160. The minimum is a Liveramp requirement and applies whenever the resulting provider is Liveramp-backed, which includes omitting \u003cb\u003eprovider\u003c/b\u003e, since that defaults to LIVERAMP_CRM. It is not enforced when \u003cb\u003eprovider\u003c/b\u003e is EXPERIAN_CRM. Minimum column(s) to be populated within template: email or first name + last name + zip code. Note that EXPERIAN_CRM resolves the email combination only, so rows without an email address will not match. Learn more \u003ca target=\"_blank\" href=\"https://support.stackadapt.com/hc/en-us/articles/360048698853-CRM-Audience-Creation-with-LiveRamp\"\u003ehere\u003c/a\u003e. \u003cbr\u003e\u003cbr\u003eThis file should also be hashed with SHA-1 with each row containing a hash of required fields. Each row should match one of the following combinations:\u003cbr\u003e\u003col\u003e\u003cli\u003e\u003cb\u003efields\u003c/b\u003e: email, \u003cb\u003etype\u003c/b\u003e: email\u003c/li\u003e\u003cli\u003e\u003cb\u003efields\u003c/b\u003e: first_name last_name email, \u003cb\u003etype\u003c/b\u003e: first_last_email\u003c/li\u003e\u003cli\u003e\u003cb\u003efields\u003c/b\u003e: first_name last_name phone, \u003cb\u003etype\u003c/b\u003e: first_last_phone\u003c/li\u003e\u003cli\u003e\u003cb\u003efields\u003c/b\u003e: first_name last_name zip, \u003cb\u003etype\u003c/b\u003e: first_last_zip\u003c/li\u003e\u003c/ol\u003e \u003cbr\u003eWe concatenate these fields by using white space and then hash the concatenated string. Hash method is provided below: \u003cbr\u003e\u003cbr\u003e\u003cbody\u003e\u003cpre\u003e\u003ccode\u003e\n                        data = Array[first_name, last_name, phone]\n                        concatenatedString = data.join(\" \").toLowerCase()\n                        hash = sha1(concatenatedString)\n                        name = \"type:first_last_phone\"\n                        return \"${hash} ${name}\"\n                        \u003c/code\u003e\u003c/pre\u003e\u003c/body\u003e\u003cbr\u003e\u003cbr\u003ePlease use the type fields provided above and a prefix \"type:\" as the name variable in the return string. You could find sample hashed file \u003ca target=\"_blank\" href=\"https://docs.google.com/spreadsheets/d/1tYxn-NtJ4VhgkWohnlUPzrRVNyVnVCre2E722OTm7lQ/edit?usp=sharing\"\u003ehere\u003c/a\u003e","operationId":"presignCRMSegment","produces":["application/json"],"parameters":[{"name":"crm_audience","in":"body","description":"CRM Audience","required":true,"schema":{"$ref":"#/definitions/PresignRequest"}}],"responses":{"200":{"description":"CRM Segment response","schema":{"$ref":"#/definitions/PresignResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/audience/location":{"post":{"tags":["Audience"],"summary":"Create new Location Audience","description":"Create a new location audience.","operationId":"createLocationAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"location_audience","in":"body","description":"Location Audience","required":true,"schema":{"$ref":"#/definitions/LocationAudience"}}],"responses":{"200":{"description":"Location audience response","schema":{"$ref":"#/definitions/Audience"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/audience/location/{id}":{"put":{"tags":["Audience"],"summary":"Update existing Location Audience","description":"Update an existing location audience.","operationId":"updateLocationAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of location audience","required":true,"type":"integer","format":"int64"},{"name":"location_audience","in":"body","description":"Location audience","required":true,"schema":{"$ref":"#/definitions/LocationAudience"}}],"responses":{"200":{"description":"Updated location audience","schema":{"$ref":"#/definitions/Audience"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Location Audience not found"}}}},"/buyer_account":{"get":{"tags":["Stats"],"summary":"Get Buyer Account Stats","description":"Returns Buyer Account stats on user query.","operationId":"getBuyerAccountStats","produces":["application/json"],"parameters":[{"name":"type","in":"query","description":"The type of stats to retrieve.","enum":["total","daily"],"required":true,"type":"string"},{"name":"date_range_type","in":"query","description":"The date range type. Defaults to `all_time`.","enum":["all_time","custom"],"required":true,"type":"string"},{"name":"start_date","in":"query","description":"The start date in the format of \"yyyy-mm-dd\". The start date is required if you are pulling daily or hourly stats.","type":"string","format":"date"},{"name":"end_date","in":"query","description":"The end date in the format of \"yyyy-mm-dd\". The end date is required if you are pulling daily or hourly stats.","type":"string","format":"date"},{"name":"timezone","in":"query","description":"The timezone of the start and end date, if applicable.","type":"string"},{"name":"group_by_resource","in":"query","description":"Group by resource types.","enum":["campaign","campaign_group","native_ad","advertiser"],"required":true,"type":"string"},{"name":"page_number","in":"query","description":"The page number to fetch","type":"number"}],"responses":{"200":{"description":"Buyer Account response","schema":{"type":"object","$ref":"#/definitions/BuyerAccountStatsResponse"}}}}},"/rt_audience/{id}":{"get":{"tags":["Retargeting Audience"],"summary":"Find Retargeting Audience by id","description":"Returns a specific retargeting audience with the corresponding id that the user has access to.","operationId":"findRTAudience","produces":["application/json"],"parameters":[{"name":"id","in":"path","description":"Id of retargeting audience to return","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Retargeting audience response","schema":{"$ref":"#/definitions/RtAudienceResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Retargeting audience was not found"}}},"delete":{"tags":["Retargeting Audience"],"summary":"Delete a Retargeting Audience","description":"Deletes a retargeting audience","operationId":"deleteRTAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of a retargeting audience to delete","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Delete retargeting audience response","schema":{"$ref":"#/definitions/RtAudienceDeleteResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Retargeting audience was not found"}}},"put":{"tags":["Retargeting Audience"],"summary":"Update Retargeting Audience","description":"Update an existing retargeting audience.","operationId":"updateRTAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"rt_audience","in":"body","description":"RT audience","required":true,"schema":{"$ref":"#/definitions/RtAudienceUpdateRequest"}}],"responses":{"200":{"description":"RT audience response","schema":{"$ref":"#/definitions/RtAudienceResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/rt_audiences":{"get":{"tags":["Retargeting Audience"],"summary":"Return all Retargeting Audiences","description":"Returns all retargeting audience that the user has access to.","operationId":"findRTAudiences","produces":["application/json"],"parameters":[{"name":"page","in":"path","description":"Page of results. Will return first page if not provided (each page contains 30 results)","required":false,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Retargeting audience response","schema":{"type":"object","properties":{"object":{"type":"string","description":"The type of object in the response","default":"Retargeting audience"},"page":{"type":"int64","description":"Page indicator","default":1},"total_rt_audiences":{"type":"int64","description":"Total number of retargeting audiences","default":1},"data":{"type":"array","items":{"$ref":"#/definitions/RtAudienceResponse"},"description":"Retargeting audience"}}}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/rt_audience":{"post":{"tags":["Retargeting Audience"],"summary":"Create new Retargeting Audience","description":"Create a new retargeting audience.","operationId":"createRTAudience","produces":["application/json"],"deprecated":true,"parameters":[{"name":"rt_audience","in":"body","description":"RT audience","required":true,"schema":{"$ref":"#/definitions/RtAudienceCreateRequest"}}],"responses":{"200":{"description":"RT audience response","schema":{"$ref":"#/definitions/RtAudienceResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/geo_locations":{"get":{"tags":["Geo Locations"],"summary":"Return all Geo Locations","description":"Returns all geo locations based on parameters.","operationId":"findGeoLocations","produces":["application/json"],"parameters":[{"name":"page","in":"path","description":"Page of results. Will return first page if not provided.","required":false,"type":"integer","format":"int32"},{"name":"search_term","in":"path","description":"Search term.","required":false,"type":"string"},{"name":"country_code","in":"path","description":"Country code.","required":false,"type":"string"},{"name":"page_size","in":"path","description":"Page size. Can be anywhere inbetween 1 to 1000.","required":false,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Geo location response","schema":{"type":"object","properties":{"object":{"type":"string","description":"The type of object in the response","default":"geo_location"},"page":{"type":"int64","description":"Page indicator","default":1},"total_geo_locations":{"type":"int64","description":"Total number of geo locations","default":1},"data":{"type":"array","items":{"$ref":"#/definitions/GeoLocationsResponse"},"description":"Geo location"}}}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/deal_groups":{"get":{"tags":["Deals"],"summary":"Return all Deal Groups","description":"Returns all deal groups based on parameters.","operationId":"findDealGroups","produces":["application/json"],"deprecated":true,"parameters":[{"name":"page","in":"path","description":"Page of results. Will return first page if not provided (each page contains 30 results)","required":false,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Deal group response","schema":{"type":"object","properties":{"object":{"type":"string","description":"The type of object in the response","default":"deal_group"},"page":{"type":"int64","description":"Page indicator","default":1},"total_deal_groups":{"type":"int64","description":"Total number of deal groups","default":234},"data":{"type":"array","items":{"$ref":"#/definitions/DealGroupResponse"},"description":"Deal group"}}}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/deal_group/{id}":{"get":{"tags":["Deals"],"summary":"Find Deal Group by id","description":"Returns a specific deal group with the corresponding id that the user has access to.","operationId":"findDealGroup","produces":["application/json"],"deprecated":true,"parameters":[{"name":"id","in":"path","description":"Id of deal group to return","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"Deal group response","schema":{"$ref":"#/definitions/DealGroupResponse"}},"400":{"description":"Invalid request","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Deal group was not found"}}}}},"definitions":{"Audience":{"required":["id","name"],"discriminator":"audience","properties":{"id":{"type":"integer","format":"int64","description":"The ID of the audience.","default":1,"readOnly":true},"identifier":{"type":"string","description":"Unique identifier for the audience.","default":"c_A1","readOnly":true},"name":{"type":"string","description":"The name of the audience.","default":"A Audience"},"created_at":{"type":"string","description":"The creation time of the audience.","readOnly":true},"advertiser_permissions":{"description":"The advertiser permission of the audience.","properties":{"advertiser_restricted":{"type":"boolean"},"permitted_advertiser_ids":{"type":"array","items":{"type":"integer","format":"int64"}}}},"expandable":{"type":"boolean","description":"Whether or not the audience is enabled for our \"look-alike\" audience expansion functionality. Currently not available on APIv2. Read more \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://support.stackadapt.com/hc/en-us/articles/360043672514\"\u003ehere\u003c/a\u003e.","default":true,"readOnly":true},"size":{"type":"integer","description":"The size of the audience.","default":true,"readOnly":true},"active":{"type":"boolean","description":"Indicate if the audience is active.","default":true,"readOnly":true},"files":{"type":"array","items":{"$ref":"#/definitions/AudienceFile"},"description":"Files related to the audience. Only available for IP and Device audience."},"geo_targets_file":{"type":"array","items":{"$ref":"#/definitions/AudienceFile"},"description":"Files related to the location audience."},"geo_targets_distance_units":{"type":"string","description":"Distance units used.","enum":["MI","KM"]},"time_window":{"type":"integer","description":"Time window for location audience.","default":10},"collection_window":{"description":"Collection window information for location audience.","properties":{"explicit_date_ranges":{"type":"array","items":{"$ref":"#/definitions/DateRange"},"description":"Date ranges for the collection window."},"recurring_weekdays":{"type":"array","items":{"type":"string","description":"Day of the week.","default":""},"description":"Recurring weekdays for the collection window."},"mode":{"type":"string","description":"Collection mode.","enum":["ONGOING","RECURRING","EXPLICIT","DISABLED"],"default":"ONGOING"},"recurring_start_time":{"type":"string","description":"Recurring start time for the collection.","default":null},"recurring_end_time":{"type":"string","description":"Recurring end time for the collection.","default":null},"timezone":{"type":"string","description":"Timezone of the collection window.","default":null}}}}},"DateRange":{"discriminator":"date_range","properties":{"start_date":{"type":"string","description":"Start date.","default":null},"end_date":{"type":"string","description":"End date.","default":null}}},"DeleteAudienceResponse":{"required":["status"],"discriminator":"delete_audience","properties":{"status":{"type":"string","description":"Status of the operation","default":"ok"}}},"IPAudience":{"required":["name","files"],"discriminator":"ip_audience","properties":{"name":{"type":"string","description":"The name of the audience.","default":"A Audience"},"advertiser_permissions":{"description":"The advertiser permission of the audience.","properties":{"advertiser_restricted":{"type":"boolean"},"permitted_advertiser_ids":{"type":"array","items":{"type":"integer","format":"int64"}}}},"files":{"type":"array","items":{"$ref":"#/definitions/CreateAudienceFile"},"description":"IP audience files."}}},"DeviceAudience":{"required":["name","files","cross_device_targeting"],"discriminator":"device_audience","properties":{"name":{"type":"string","description":"The name of the audience.","default":"A Audience"},"advertiser_permissions":{"description":"The advertiser permission of the audience.","properties":{"advertiser_restricted":{"type":"boolean"},"permitted_advertiser_ids":{"type":"array","items":{"type":"integer","format":"int64"}}}},"files":{"type":"array","items":{"$ref":"#/definitions/CreateAudienceFile"},"description":"Device audience files."},"cross_device_targeting":{"type":"boolean","description":"Enable cross device targeting.","default":false}}},"LocationAudience":{"required":["name","files","geo_targets_distance_units","time_window","collection_window"],"discriminator":"device_audience","properties":{"name":{"type":"string","description":"The name of the audience.","default":"A Audience"},"advertiser_permissions":{"description":"The advertiser permission of the audience.","properties":{"advertiser_restricted":{"type":"boolean"},"permitted_advertiser_ids":{"type":"array","items":{"type":"integer","format":"int64"}}}},"files":{"type":"array","items":{"$ref":"#/definitions/CreateAudienceFile"},"description":"Location audience files."},"time_window":{"type":"integer","description":"Time window.","default":3},"geo_targets_distance_units":{"description":"Distance units for location audience.","type":"string","enum":["MI","KM"]},"collection_window":{"description":"Collection window information for location audience.","properties":{"explicit_date_ranges":{"type":"array","items":{"$ref":"#/definitions/DateRange"},"description":"Date ranges for the collection window."},"recurring_weekdays":{"type":"array","items":{"type":"string","description":"Day of the week.","default":""},"description":"Recurring weekdays for the collection window."},"mode":{"type":"string","description":"Collection mode.","enum":["ONGOING","RECURRING","EXPLICIT","DISABLED"],"default":"ONGOING"},"recurring_start_time":{"type":"string","description":"Recurring start time for the collection.","default":null},"recurring_end_time":{"type":"string","description":"Recurring end time for the collection.","default":null},"timezone":{"type":"string","description":"Timezone of the collection window.","default":null}}}}},"CreateCRMAudience":{"required":["display_name","file_paths","region"],"discriminator":"crm_audience","properties":{"display_name":{"type":"string","description":"CRM audience Name.","default":"CRM #1"},"region":{"description":"Region of the CRM audience.","type":"string","enum":["UK","US"],"default":"UK"},"file_paths":{"description":"Full file URL retrieved from presign endpoint.","type":"array","items":{"type":"string","default":"www.stackadapt.com/file-1"}},"advertiser_permissions":{"description":"The advertiser permission of the audience.","properties":{"advertiser_restricted":{"type":"boolean"},"permitted_advertiser_ids":{"type":"array","items":{"type":"integer","format":"int64"}}}}}},"UpdateCRMAudience":{"required":["display_name","file_paths","region","new_file_paths","deleted_file_paths"],"discriminator":"crm_audience","properties":{"display_name":{"type":"string","description":"CRM audience Name.","default":"CRM #1"},"region":{"description":"Region of location audience.","type":"string","enum":["UK","US"],"default":"UK"},"new_file_paths":{"description":"All file paths for new added files.","type":"array","items":{"type":"string","default":"temp/file-a"}},"deleted_file_paths":{"description":"All permanent file paths for files that need to be deleted.","type":"array","items":{"type":"string","default":"permanent/file-b"}},"advertiser_permissions":{"description":"The advertiser permission of the audience.","properties":{"advertiser_restricted":{"type":"boolean"},"permitted_advertiser_ids":{"type":"array","items":{"type":"integer","format":"int64"}}}}}},"AudienceFile":{"required":["id","url","name"],"properties":{"id":{"type":"integer","format":"int64","description":"The ID of the audience file.","default":1,"readOnly":true},"name":{"type":"string","description":"The name of the audience file."},"url":{"type":"string","description":"The url of the audience file."},"file_path":{"type":"string","description":"The path of the CRM audience file. Only shown for CRM audience files."},"size":{"type":"integer","format":"int64","description":"The size of the CRM audience file. Only shown for CRM audience files."}}},"CreateAudienceFile":{"required":["url","name"],"properties":{"name":{"type":"string","description":"The name of the audience file. Must end with `.csv`.","default":"File A.csv"},"url":{"type":"string","description":"The url of the audience file.","default":"www.stackadapt.com/file-a"}}},"PresignRequest":{"required":["region","filename"],"properties":{"region":{"type":"string","description":"Region of the CRM. Valid options: \"US\", \"UK\".","default":"US"},"filename":{"type":"string","description":"Filename.","default":"file-a"}}},"PresignResponse":{"discriminator":"presign_response","properties":{"method":{"type":"string","description":"Method of request.","default":"post"},"url":{"type":"string","description":"URL to make request to.","default":"www.stackadapt.com"},"headers":{"type":"string","description":"Headers for the request.","default":"{}"},"file":{"description":"File information.","properties":{"url":{"type":"string","description":"URL for the file.","default":"www.stackadapt.com/file-1"}}},"fields":{"description":"Form fields for the request.","properties":{"key":{"type":"string","description":"Key (file location).","default":"file-1"},"policy":{"type":"string","description":"Policy for AWS.","default":null},"x-amz-credential":{"type":"string","description":"AWS simple storage credentials.","default":null},"x-amz-algorithm":{"type":"string","description":"AWS simple storage algorithm.","default":null},"x-amz-date":{"type":"string","description":"AWS simple storage date.","default":null},"x-amz-signature":{"type":"string","description":"AWS simple storage signature.","default":null}}}}},"InsightStats":{"properties":{"acomp_0":{"type":"integer","description":"Number of 0% audio completions.","default":12},"acomp_25":{"type":"integer","description":"Number of 25% audio completions.","default":45},"acomp_50":{"type":"integer","description":"Number of 50% audio completions.","default":64},"acomp_75":{"type":"integer","description":"Number of 75% audio completions.","default":64},"acomp_95":{"type":"integer","description":"Number of 95% audio completions.","default":64},"atos":{"type":"float","description":"The average time on site.","default":157.682},"avg_time_on_site_units":{"type":"string","description":"ATOS in readable units.","default":"5 minutes"},"campaign":{"type":"string","description":"Campaign name.","default":"Campaign A"},"line_item":{"type":"string","description":"Campaign group name.","default":"Campaign Group A"},"sub_advertiser":{"type":"string","description":"Advertiser name.","default":"Advertiser A"},"campaign_id":{"type":"integer","description":"Campaign ID.","default":16},"conv":{"type":"integer","description":"Conversions.","default":16},"conv_click":{"type":"integer","description":"Conversion clicks.","default":34},"conv_cookie":{"type":"integer","description":"Conversion cookie.","default":21},"conv_imp_derived":{"type":"integer","description":"Conversions attributed from impressions.","default":8},"conv_imp_time_avg":{"type":"float","description":"The average time to convert to impression.","default":122.682},"conv_ip":{"type":"integer","description":"Conversion IP.","default":45},"conv_rev":{"type":"float","description":"Conversion revenue.","default":250.76305299999999},"cost":{"type":"float","description":"Media cost","default":164.76305299999999},"ctr":{"type":"float","description":"Click-through rate.","default":4.901},"cvr":{"type":"float","description":"Conversion rate.","default":2.339},"ecpa":{"type":"float","description":"Effective cost per action.","default":10.298},"ecpc":{"type":"float","description":"Effective cost per click.","default":0.241},"ecpcl":{"type":"float","description":"Effective cost per completed listen.","default":0.241},"ecpe":{"type":"float","description":"Effective cost per engagement.","default":0.015},"ecpm":{"type":"float","description":"Effective cost per mille.","default":11.807},"ecpv":{"type":"float","description":"Effective cost per view.","default":0.283},"engage_rate":{"type":"float","description":"Engagement rate.","default":0.283},"imp":{"type":"integer","description":"Impressions","default":13955},"ltr":{"type":"float","description":"Listen through rate.","default":0.42},"merged_segments":{"type":"string","description":"Merged segments.","default":"Segment A"},"page_start":{"type":"integer","description":"Number of time page was loaded.","default":13},"page_time":{"type":"integer","description":"Total time spent on the page.","default":23},"page_time_15s":{"type":"integer","description":"Number of times 15 seconds was spent on the page.","default":52},"revenue":{"type":"float","description":"Revenue","default":250.76305299999999},"roas":{"type":"float","description":"Return on ad spend","default":38.377},"s_conv":{"type":"integer","description":"Secondary conversions.","default":7},"time_on_site":{"type":"integer","description":"Total time spent on the site.","default":192},"total_time_units":{"type":"string","description":"Total time in readable units.","default":"3 minutes 2 seconds"},"vcomp_0":{"type":"integer","description":"Number of 0% video completions.","default":12},"vcomp_25":{"type":"integer","description":"Number of 25% video completions.","default":45},"vcomp_50":{"type":"integer","description":"Number of 50% video completions.","default":64},"vcomp_75":{"type":"integer","description":"Number of 75% video completions.","default":64},"vcomp_95":{"type":"integer","description":"Number of 95% video completions.","default":64},"vcomp_rate":{"type":"float","description":"Video completion rate.","default":0},"view_percent":{"type":"float","description":"View percentage.","default":0},"tactic_bid_id":{"type":"string","description":"Tactical bid id.","default":"Bid Factor #1"},"categories":{"type":"string","description":"Category.","default":"News"},"tactic_native_ad_id":{"type":"string","description":"Tactical native ad id.","default":"Creative Tactic # 1"},"programmatic_deal_group_id":{"type":"string","description":"Programmatic deal group id.","default":"CTV","deprecated":true},"demographics_segment":{"type":"string","description":"Demographic segment.","default":"Age \u003e 25-34"},"devicetype":{"type":"string","description":"Device type.","default":"Laptop"},"country":{"type":"string","description":"Country.","default":"United States"},"region":{"type":"string","description":"Region.","default":"Utah"},"retargeting_segment":{"type":"string","description":"Retargeting segment.","default":"Segment - 1"},"supply_source":{"type":"string","description":"Supply source.","default":"Source A"},"campaign_custom_fields":{"type":"array","items":{"type":"string","default":"field_a"},"description":"List of custom fields."}}},"InsightStatsResponse":{"discriminator":"insight","properties":{"total_stats":{"type":"object","description":"Delivery stats response","$ref":"#/definitions/InsightStats"}}},"DeliveryStats":{"properties":{"atos":{"type":"float","description":"The average time on site.","default":157.682},"atos_units":{"type":"string","description":"ATOS in readable units.","default":"6 minutes"},"campaign":{"type":"string","description":"Campaign name.","default":"Campaign A"},"campaign_custom_fields":{"type":"array","items":{"type":"string","default":"field_a"},"description":"List of custom fields."},"campaign_id":{"type":"integer","description":"Campaign ID.","default":16},"click":{"type":"integer","description":"Clicks","default":684},"conv":{"type":"integer","description":"Number of clicks.","default":124},"conv_click":{"type":"integer","description":"Conversion clicks.","default":34},"conv_click_time_avg":{"type":"float","description":"The average time to convert to click.","default":122.682},"conv_cookie":{"type":"integer","description":"Conversion cookie.","default":21},"conv_imp_derived":{"type":"integer","description":"Conversions attributed from impressions.","default":8},"conv_imp_time_avg":{"type":"float","description":"The average time to convert to impression.","default":122.682},"conv_rev":{"type":"float","description":"Conversion revenue.","default":2.6},"cost":{"type":"float","description":"Media cost","default":164.76305299999999},"ctr":{"type":"float","description":"Click-through rate.","default":4.901},"cvr":{"type":"float","description":"Conversion rate.","default":2.339},"ecpa":{"type":"float","description":"Effective cost per action.","default":10.298},"ecpc":{"type":"float","description":"Effective cost per click.","default":0.241},"ecpcl":{"type":"float","description":"Effective cost per completed listen.","default":0.241},"ecpe":{"type":"float","description":"Effective cost per engagement.","default":0.015},"ecpm":{"type":"float","description":"Effective cost per mille.","default":11.807},"ecpv":{"type":"float","description":"Effective cost per view.","default":0.283},"imp":{"type":"integer","description":"Impressions","default":13955},"ltr":{"type":"float","description":"Listen through rate.","default":0.42},"page_time":{"type":"integer","description":"Total time spent on the page.","default":23},"page_time_units":{"type":"string","description":"Page time in readable units","default":"8 hours"},"profit":{"type":"float","description":"Profit.","default":2564.21},"revenue":{"type":"float","description":"Revenue.","default":250.76305299999999},"s_conv":{"type":"integer","description":"Secondary conversions.","default":7},"tp_cpm_cost":{"type":"float","description":"Third-party CPM cost","default":15.023},"tp_cpc_cost":{"type":"float","description":"Third-party CPC cost","default":11.569},"uniq_conv":{"type":"integer","description":"Unique conversions.","default":7},"uniq_imp":{"type":"integer","description":"Unique impressions.","default":12},"unique_imp_inverse_rate":{"type":"float","description":"Frequency","default":1.5333},"view_percent":{"type":"float","description":"View percentage.","default":0},"app_name":{"type":"string","description":"App name.","default":"App B"},"banned":{"type":"boolean","description":"If it is banned.","default":false},"ios_id":{"type":"integer","description":"iOS ID.","default":12},"is_android":{"type":"boolean","description":"If the device was an android.","default":false},"is_ios":{"type":"boolean","description":"If the device was an ios.","default":false},"page_time_15s":{"type":"integer","description":"Number of times 15 seconds was spent on the page.","default":52},"seller":{"type":"string","description":"Seller information.","default":"n/a"},"source":{"type":"string","description":"Source information of the ad.","default":"Ad 1"},"superbanned":{"type":"boolean","description":"If it is super banned.","default":false},"conv_ip":{"type":"integer","description":"Conversion IP.","default":45},"conversion_tracker_id":{"type":"integer","description":"Conversion Tracker ID.","default":1},"conversion_tracker":{"type":"string","description":"Conversion Tracker name.","default":"Conversion Tracker 1"},"native_ad_id":{"type":"integer","description":"Creative (native ad) ID.","default":1},"native_ad":{"type":"string","description":"Creative (native ad) name.","default":"Creative 1"},"native_ad_type":{"type":"string","description":"Creative (native ad) type.","default":"display"},"vcomp_0":{"type":"integer","description":"Number of 0% video completions.","default":12},"vcomp_25":{"type":"integer","description":"Number of 25% video completions.","default":45},"vcomp_50":{"type":"integer","description":"Number of 50% video completions.","default":64},"vcomp_75":{"type":"integer","description":"Number of 75% video completions.","default":64},"vcomp_95":{"type":"integer","description":"Number of 95% video completions.","default":64},"vcomp_rate":{"type":"float","description":"Video completion rate.","default":0},"advertiser_id":{"type":"integer","description":"Advertiser ID.","default":1},"advertiser":{"type":"string","description":"Advertiser name.","default":"Advertiser 1"},"date":{"type":"string","description":"Date and time.","default":""},"click_url":{"type":"string","description":"URL when the advertisement is clicked.","default":"www.stackadapt.com"},"campaign_type":{"type":"string","description":"Campaign type.","default":"display"},"channel":{"type":"string","description":"Channel type.","default":"display"},"start_date":{"type":"string","format":"date","description":"The date when the campaign will begin.","default":"2016-05-27"},"end_date":{"type":"string","format":"date","description":"The date when the campaign will end.","default":"2016-06-27"},"heading":{"type":"string","description":"The heading of the ad.","default":"API Headline: Welcome to StackAdapt's API"},"line_item":{"type":"string","description":"Campaign group name.","default":"Campaign Group A"},"line_item_id":{"type":"integer","description":"Campaign group ID.","default":1},"nativead":{"type":"string","description":"Creative (native ad) name.","default":"Image 1"},"sub_advertiser":{"type":"string","description":"Advertiser name.","default":"Advertiser A"},"sub_advertiser_id":{"type":"integer","description":"Advertiser ID.","default":1},"tagline":{"type":"string","description":"The tagline of the ad.","default":"Welcome to StackAdapt's API. Start using it by playing around in the sandbox"},"rcpc":{"type":"float","description":"Revenue cost per click.","default":0},"rcpcl":{"type":"float","description":"Revenue cost per completed listen.","default":0.241},"rcpe":{"type":"float","description":"Revenue cost per engagement.","default":0.015},"rcpm":{"type":"float","description":"Revenue cost per mille.","default":11.807},"creatives":{"type":"object","description":"Creatives","$ref":"#/definitions/DeliveryStatsCreatives"}}},"DeliveryStatsCreatives":{"discriminator":"delivery_creatives","properties":{"img_url":{"type":"string","description":"Image URL."},"size":{"type":"string","description":"Size of the ad."}}},"DeliveryStatsResponse":{"discriminator":"insight","properties":{"total_stats":{"type":"object","description":"Delivery stats response","$ref":"#/definitions/DeliveryStats"}}},"BuyerAccountStats":{"properties":{"atos":{"type":"float","description":"The average time on site","default":157.682},"click":{"type":"integer","description":"Clicks","default":684},"conv":{"type":"integer","description":"Conversions","default":16},"conv_imp_derived":{"type":"integer","description":"Conversions attributed from impressions","default":8},"conv_rev":{"type":"float","description":"Conversion revenue","default":250.76305299999999},"cost":{"type":"float","description":"Media cost","default":164.76305299999999},"ctr":{"type":"float","description":"Click-through rate","default":4.901},"cvr":{"type":"float","description":"Conversion rate","default":2.339},"date":{"type":"string","description":"Date","default":"Total"},"ecpa":{"type":"float","description":"Effective cost per action","default":10.298},"ecpc":{"type":"float","description":"Effective cost per click","default":0.241},"ecpe":{"type":"float","description":"Effective cost per engagement","default":0.015},"ecpm":{"type":"float","description":"Effective cost per mille","default":11.807},"ecpv":{"type":"float","description":"Effective cost per view","default":0.283},"imp":{"type":"integer","description":"Impressions","default":13955},"page_time":{"type":"integer","description":"Total time","default":3121794},"page_time_15s":{"type":"integer","description":"Engagements","default":11258},"roas":{"type":"float","description":"Return on ad spend","default":38.377},"s_conv":{"type":"integer","description":"Secondary conversions","default":7},"unique_conv":{"type":"integer","description":"Unique conversions","default":10},"tp_cpm_cost":{"type":"float","description":"Third-party CPM cost","default":15.023},"tp_cpc_cost":{"type":"float","description":"Third-party CPC cost","default":11.569},"unique_imp":{"type":"integer","description":"Unique impressions","default":7809},"unique_imp_inverse_rate":{"type":"float","description":"Frequency","default":1.5333},"view_percent":{"type":"float","description":"Viewability","default":84.099}}},"BuyerAccountStatsResponse":{"discriminator":"stats","properties":{"total_stats":{"type":"object","description":"BuyerAccount stats in response","$ref":"#/definitions/BuyerAccountStats"}}},"RtAudienceResponse":{"discriminator":"rt_audience","properties":{"id":{"type":"integer","format":"int64","description":"The ID of the retargeting audience.","default":1},"name":{"type":"string","description":"Name of the retargeting audience.","default":"RT Audience"},"description":{"type":"string","description":"Description of the retargeting audience.","default":"My RT Audience"},"required_frequency":{"type":"integer","format":"int64","description":"The number of times the pixel needs to fire for the user to be added to the RT pool. Required frequency should be a whole number equal or greater than one.","default":1},"action_type":{"type":"string","description":"Action type for the retargeting audience.","enum":["RETARGETING","NEGATIVE"],"default":"RETARGETING"},"post_time":{"type":"integer","format":"int64","description":"Expiry time for retargeting audience. Should be in ms, i.e 1 second = 1000.","default":1000},"advertiser_restricted":{"type":"boolean","description":"If the retargeting audience is advertiser restricted.","default":true},"advertisers":{"type":"array","items":{"type":"integer","format":"int64","default":123},"description":"List of advertiser ids that are restricted."}}},"RtAudienceDeleteResponse":{"discriminator":"rt_audience_delete","properties":{"message":{"type":"string","description":"Status of the operation.","default":"success"}}},"RtAudienceCreateRequest":{"required":["name","advertiser_restricted","required_frequency","post_time"],"discriminator":"rt_audience_create","properties":{"name":{"type":"string","description":"Name of the retargeting audience.","default":"RT Audience"},"description":{"type":"string","description":"Description of the retargeting audience.","default":"My RT Audience"},"advertiser_restricted":{"type":"boolean","description":"Restrict advertiser for retargeting audience.","default":true},"required_frequency":{"type":"integer","format":"int64","description":"The number of times the pixel needs to fire for the user to be added to the RT pool. Required frequency should be a whole number equal or greater than one.","default":1},"post_time":{"type":"integer","format":"int64","description":"Expiry time for retargeting audience. Should be in ms, i.e 1 second = 1000.","default":1000},"advertisers":{"type":"array","items":{"type":"integer","format":"int64","default":123},"description":"List of advertiser ids that are restricted."}}},"RtAudienceUpdateRequest":{"discriminator":"rt_audience_update","properties":{"name":{"type":"string","description":"Name of the retargeting audience.","default":"RT Audience"},"description":{"type":"string","description":"Description of the retargeting audience.","default":"My RT Audience"},"advertiser_restricted":{"type":"boolean","description":"Restrict advertiser for retargeting audience.","default":true},"required_frequency":{"type":"integer","format":"int64","description":"The number of times the pixel needs to fire for the user to be added to the RT pool. Required frequency should be a whole number equal or greater than one.","default":1},"post_time":{"type":"integer","format":"int64","description":"Expiry time for retargeting audience. Should be in ms, i.e 1 second = 1000.","default":1000},"advertisers":{"type":"array","items":{"type":"integer","format":"int64","default":123},"description":"List of advertiser ids that are restricted."}}},"GeoLocationsResponse":{"discriminator":"geo_locations","properties":{"dma":{"type":"integer","format":"int64","description":"Designated marketing area.","default":1},"display_name":{"type":"string","description":"Display name for the location.","default":"Valhalla, New York, United States"},"name":{"type":"string","description":"Name of the location.","default":"Valhalla"},"region_code":{"type":"string","description":"Region code.","default":"NY"},"country_code":{"type":"string","description":"Country code.","default":"US"},"type":{"type":"string","description":"Type of location.","default":"us_county"},"formatted":{"type":"string","description":"Formatted location for APIv2.","default":"Valhalla \u003e NY \u003e US"}}},"DealGroupResponse":{"discriminator":"deal_group","deprecated":true,"properties":{"name":{"type":"string","description":"Name of the deal group.","default":"Display Deal Package"},"id":{"type":"integer","format":"int64","description":"Id of the deal group.","default":1},"description":{"type":"string","description":"Description of the deal group.","default":"This package is for display ads."},"supported_channel_types":{"type":"array","items":{"type":"string","default":"Native"},"description":"List of eligible channel types."}}},"LineItemCreate":{"properties":{"id":{"type":"integer","format":"int64","default":1022,"description":"The id of an existing campaign group to link to this campaign. Mutually exclusive with name."},"name":{"type":"string","default":"My New Campaign Group","description":"The name of the campaign group you want to create and link to this campaign. Mutually exclusive with id."}}},"AdvertiserCreate":{"properties":{"id":{"type":"integer","format":"int64","default":2044,"description":"The id of an existing advertiser to link to this campaign. Mutually exclusive with name."},"name":{"type":"string","default":"My New Advertiser","description":"The name of the advertiser you want to create and link to this campaign. Mutually exclusive with id."},"line_item":{"$ref":"#/definitions/LineItemCreate"}}},"CampaignResponse":{"required":["id","advertiser_id","line_item_id","name","goal","budget","bid_type","bid_amount_total","start_date"],"discriminator":"campaign","properties":{"id":{"type":"integer","format":"int64","description":"The ID of the campaign.","default":55},"advertiser_id":{"type":"integer","format":"int64","description":"The ID of the campaign's advertiser.","default":12},"line_item_id":{"type":"integer","format":"int64","description":"The ID of the campaign's line item. This value cannot be modified after it has been set.","default":22},"name":{"type":"string","description":"The name of the campaign.","default":"API Test Campaign"},"goal":{"type":"string","description":"The goal of the campaign. Note: use \"engagement\" for awareness or engagement campaigns","enum":["engagement","conversion"],"default":"engagement"},"budget":{"type":"number","format":"float","description":"The budget of the campaign.","default":10000.0},"type":{"type":"string","description":"The type of the campaign.","default":"native"},"bid_type":{"type":"string","description":"Type of bid model: cpm (Cost Per Thousand Impressions), cpc (Cost Per Click), cpe (Cost Per Engagement) bid model.","enum":["cpm","cpc","cpe","cpcv"],"default":"cpm"},"bid_amount_total":{"type":"number","format":"float","description":"The bid amount of the campaign.","default":5.0},"optimize_type":{"type":"string","description":"The type of optimization used for the campaign: ctr (CTR floor), cpc (CPC goal).","enum":["ctr","cpc","cpe"],"default":"cpc"},"optimize_value":{"type":"number","format":"float","description":"The value of the optimization. Example: The value is 0.2 for a $0.2 CPC goal, or a 0.2% CTR floor.","default":1.5},"daily_cap":{"type":"number","format":"float","description":"The maximum budget to be spent in a single day. This value is only used if pace_evenly is NULL or false.","default":null},"pace_evenly":{"type":"boolean","description":"Whether or not to pace the campaign budget evenly over the course of the campaign. This value is only used if a valid end_date is specified.","default":true},"state":{"type":"string","description":"The state of the campaign.","enum":["active","paused"],"default":"active"},"status":{"$ref":"#/definitions/CampaignStatus","description":"Campaign status."},"start_date":{"type":"string","format":"date","description":"The date when the campaign will begin.","default":"2016-05-27"},"end_date":{"type":"string","format":"date","description":"The date when the campaign will end.","default":"2016-06-27"},"engagement_tracking_type":{"type":"integer","format":"int64","description":"Type of engagement tracking for post click engagement. (0 = None, 1 = IFrame, 2 = Use Stackadapt Pixel)","enum":[0,1,2],"default":0},"category_options":{"type":"array","items":{"type":"string","default":"IAB1"},"description":"The list of IAB categories to be included in the campaign. \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://docs.google.com/document/d/1tz-S6a4GDR9yq7eei0yoAzKkzrLBqQ0pelNSqAksMQY/edit#bookmark=kix.4hlozfae2aqc\"\u003eClick Here\u003c/a\u003e for full list of IB categories. Leave empty to choose all."},"custom_segments_list":{"type":"array","items":{"type":"string","default":"\u003cidentifier\u003e"},"description":"The list of Custom Segments identifiers attached to a campaign."},"custom_segments_ids":{"type":"array","items":{"type":"integer","format":"int64","default":12},"description":"The list of Custom Segments ids attached to a campaign."},"demo_and_interests_list":{"type":"array","items":{"type":"string","default":"\u003cidentifier\u003e"},"description":"The list of Demographic and Interest identifiers attached to a campaign."},"demo_and_interests_ids":{"type":"array","items":{"type":"integer","format":"int64","default":12},"description":"The list of Demographic and Interest ids attached to a campaign."},"third_party_segments":{"type":"array","items":{"type":"string","default":"\u003cidentifier\u003e"},"description":"The list of Third-Party Segment identifiers to attach to a campaign"},"country_options":{"type":"array","items":{"type":"string","default":"US"},"description":"The list of ISO 3166-1 alpha-2 country codes to be included in the campaign.","enum":["US","CA","..."]},"us_state_options":{"type":"array","items":{"type":"string","default":"NY"},"description":"The list of ISO 3166-2 US state codes to be included in the campaign.","enum":["CA","NY","..."]},"canada_province_options":{"type":"array","items":{"type":"string","default":"ON"},"description":"The list of ISO 3166-2 Canadian province codes to be included in the campaign.","enum":["ON","BC","..."]},"uk_county_options":{"type":"array","items":{"type":"string","default":"Z5"},"description":"The list of ISO 3166-2 UK county codes to be included in the campaign.","enum":["Z5","P4","..."]},"other_state_options":{"type":"array","items":{"type":"string","default":"au:02"},"description":"The list of states (aside from those in US, UK, or Canada) to be included in the campaign. Pairs in format [country code]:[state code].","enum":["au:02"]},"city_options":{"type":"string","description":"The list of city ID objects to be included in the campaign. For more information \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://docs.google.com/document/d/1tz-S6a4GDR9yq7eei0yoAzKkzrLBqQ0pelNSqAksMQY/edit#bookmark=kix.s0oqrtowdcic\"\u003eClick Here\u003c/a\u003e.","default":"Sugar Land \u003e TX \u003e US:618@ Missouri City \u003e TX \u003e US:618@ Houston \u003e TX \u003e US:618@ Austin \u003e TX \u003e US:635"},"domain_action":{"type":"string","description":"Action to be taken on the \"domain_options\" list.","default":"exclude","enum":["include","exclude"]},"domain_options":{"type":"array","items":{"type":"string","default":"www.american-express.com"},"description":"The list of domains or subdomains to be included or excluded in the campaign. \"domain_action\" must also be set. Example: [\"ford.com\", \"www.american express.com\"]"},"device_type_options":{"type":"array","items":{"type":"string","default":"phone"},"description":"The list of device types to be included in the campaign.","enum":["desktop","tablet","phone"]},"supply_type_options":{"type":"array","items":{"type":"string","default":"web"},"description":"The list of mobile supply types to be included in the campaign.","enum":["web","app"]},"supply_source_options":{"type":"array","items":{"type":"string","default":""},"description":"The list of supply source id's to be included in the campaign. Leave empty to select all (Recommended). See the supply_sources endpoint for a list of supply_source_options"},"freq_cap_limit":{"type":"integer","format":"int64","description":"The user frequency cap value, which is the maximum amount of impressions that a unique user can see.","default":7},"freq_cap_time":{"type":"integer","format":"int64","description":"The length of time in milliseconds when the user frequency cap counter restarts.","default":86400000},"language_options":{"type":"array","items":{"type":"string","default":"en"},"description":"A list of language(s) that are targeted. The campaign will only target sites or users whose language is included in the list."},"use_dma":{"type":"boolean","description":"Enable campaign to target city by Designated Market Area (DMA)."},"conversion_trackers":{"type":"array","items":{"$ref":"#/definitions/ConversionTracker","default":null}},"allow_iframe_engagement":{"type":"boolean","description":"Allow engagement tracking by placing add within an iframe","default":true},"is_deal_id_strict":{"type":"boolean","description":"Run only on the deal groups attached to the campaign.","default":true},"deal_group_ids":{"type":"array","items":{"type":"integer","format":"int64","default":12},"description":"The list of deal group ids attached to a campaign.","deprecated":true},"all_native_ads":{"type":"array","items":{"$ref":"#/definitions/NativeAdResponse","default":null}}}},"CampaignCreateRequest":{"required":["name","budget","bid_type","bid_amount_total","all_native_ads"],"discriminator":"campaign","properties":{"name":{"type":"string","description":"The name of the campaign.","default":"API Test Campaign"},"goal":{"type":"string","description":"The goal of the campaign. Note: use \"engagement\" for awareness or engagement campaigns","enum":["engagement","conversion"],"default":"engagement"},"type":{"type":"string","description":"The campaign type. Currently, only native and display is supported through API creation","enum":["native","display"],"default":"native"},"optimize_type":{"type":"string","description":"The type of optimization used for the campaign: ctr (CTR floor), cpc (CPC goal).","enum":["ctr","cpc","cpe"],"default":"cpc"},"optimize_value":{"type":"number","format":"float","description":"The value of the optimization. Example: The value is 0.2 for a $0.2 CPC goal, or a 0.2% CTR floor.","default":1.5},"domain_action":{"type":"string","description":"Action to be taken on the \"domain_options\" list.","default":"exclude","enum":["include","exclude"]},"user_cpa":{"type":"number","format":"float","description":"User cost per action. Also known as `flights CPA target`.","default":1.5},"state":{"type":"string","description":"The state of the campaign.","enum":["active","paused"],"default":"active"},"bid_type":{"type":"string","description":"Type of bid model: cpm (Cost Per Thousand Impressions), cpc (Cost Per Click), cpe (Cost Per Engagement) bid model.","enum":["cpm","cpc","cpe"],"default":"cpm"},"budget":{"type":"number","format":"float","description":"The budget of the campaign.","default":10000.0},"is_draft":{"type":"boolean","description":"If the campaign is draft.","default":true},"daily_cap":{"type":"number","format":"float","description":"The maximum budget to be spent in a single day. This value is only used if pace_evenly is NULL or false.","default":null},"pace_evenly":{"type":"boolean","description":"Whether or not to pace the campaign budget evenly over the course of the campaign. This value is only used if a valid end_date is specified.","default":true},"start_date":{"type":"string","format":"date","description":"The date when the campaign will begin.","default":"2016-05-27"},"end_date":{"type":"string","format":"date","description":"The date when the campaign will end.","default":"2016-06-27"},"start_hour":{"type":"integer","format":"int64","description":"The campaign will start spending at this hour. The start_hour will be set to 0 if not defined or defined outside of range 0 to 23.","default":0,"minimum":0,"maximum":23},"end_hour":{"type":"integer","format":"int64","description":"The campaign will finish spending at this hour. The end_hour will be set to 0 if not defined or defined outside of range 0 to 23","default":0,"minimum":0,"maximum":23},"bid_amount_total":{"type":"number","format":"float","description":"The bid amount of the campaign.","default":5.0},"freq_cap_limit":{"type":"integer","format":"int64","description":"The user frequency cap value, which is the maximum amount of impressions that a unique user can see.","default":7},"freq_cap_time":{"type":"integer","format":"int64","description":"The length of time in milliseconds when the user frequency cap counter restarts.","default":86400000},"city_options":{"type":"string","description":"The list of city ID objects to be included in the campaign. For more information \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://docs.google.com/document/d/1tz-S6a4GDR9yq7eei0yoAzKkzrLBqQ0pelNSqAksMQY/edit#bookmark=kix.s0oqrtowdcic\"\u003eClick Here\u003c/a\u003e.","default":"Sugar Land \u003e TX \u003e US:618@ Missouri City \u003e TX \u003e US:618@ Houston \u003e TX \u003e US:618@ Austin \u003e TX \u003e US:635"},"ip_options":{"type":"string","default":"99.98.98.000,99.17.13.000","description":"String of IPs separated by commas."},"is_deal_id_strict":{"type":"boolean","description":"Run only on the deal groups attached to the campaign.","default":true},"allow_iframe_engagement":{"type":"boolean","description":"Allow engagement tracking by placing add within an iframe","default":true},"use_dma":{"type":"boolean","description":"Enable campaign to target city by Designated Market Area (DMA)."},"engagement_tracking_type":{"type":"integer","format":"int64","description":"Type of engagement tracking for post click engagement. (0 = None, 1 = IFrame, 2 = Use Stackadapt Pixel)","enum":[0,1,2],"default":0},"category_options":{"type":"array","items":{"type":"string","default":"IAB1"},"description":"The list of IAB categories to be included in the campaign. \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://docs.google.com/document/d/1tz-S6a4GDR9yq7eei0yoAzKkzrLBqQ0pelNSqAksMQY/edit#bookmark=kix.4hlozfae2aqc\"\u003eClick Here\u003c/a\u003e for full list of IB categories. Leave empty to choose all."},"country_options":{"type":"array","items":{"type":"string","default":"US"},"description":"The list of ISO 3166-1 alpha-2 country codes to be included in the campaign.","enum":["US","CA","..."]},"device_os_family_options":{"type":"array","items":{"type":"string","default":"iOS"},"description":"A list of device OS that are targeted."},"device_os_options":{"type":"array","items":{"type":"string","default":"Windows 8"},"description":"A list of specific device OS that are targeted."},"browser_options":{"type":"array","items":{"type":"string","default":"chrome"},"description":"A list of specific browswers that are targeted."},"supply_type_options":{"type":"array","items":{"type":"string","default":"web"},"description":"The list of mobile supply types to be included in the campaign.","enum":["web","app"]},"supply_source_options":{"type":"array","items":{"type":"string","default":""},"description":"List of supply source id's. See the supply_sources endpoint for a list of supply_source_options"},"us_state_options":{"type":"array","items":{"type":"string","default":"NY"},"description":"The list of ISO 3166-2 US state codes to be included in the campaign.","enum":["CA","NY","..."]},"canada_province_options":{"type":"array","items":{"type":"string","default":"ON"},"description":"The list of ISO 3166-2 Canadian province codes to be included in the campaign.","enum":["ON","BC","..."]},"uk_county_options":{"type":"array","items":{"type":"string","default":"Z5"},"description":"The list of ISO 3166-2 UK county codes to be included in the campaign.","enum":["Z5","P4","..."]},"other_state_options":{"type":"array","items":{"type":"string","default":"au:02"},"description":"The list of states (aside from those in US, UK, or Canada) to be included in the campaign. Pairs in format [country code]:[state code].","enum":["au:02"]},"device_type_options":{"type":"array","items":{"type":"string","default":"phone"},"description":"The list of device types to be included in the campaign.","enum":["desktop","tablet","phone"]},"language_options":{"type":"array","items":{"type":"string","default":"en"},"description":"A list of language(s) that are targeted. The campaign will only target sites or users whose language is included in the list."},"custom_segments_list":{"type":"array","items":{"type":"string","default":"\u003cidentifier\u003e"},"description":"The list of Custom Segments identifiers to attach to a campaign."},"demo_segment_ids":{"type":"array","items":{"type":"integer","format":"int64","default":11398},"description":"The list of Demographic Segments identifiers to attach to a campaign. For more information on the demographic segments offered \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://docs.google.com/document/d/1tz-S6a4GDR9yq7eei0yoAzKkzrLBqQ0pelNSqAksMQY/edit#bookmark=id.d91lv8j3bt9z\"\u003eClick Here\u003c/a\u003e."},"interest_segment_ids":{"type":"array","items":{"type":"integer","format":"int64","default":11398},"description":"The list of Interest and Intent Segments identifiers to attach to a campaign. For more information on the interests and intent segments offered \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://docs.google.com/spreadsheets/d/10B585OpPo8FMnwj75ULTtZMUpZzcojaiEqSMtuOLkNs/edit#gid=0\"\u003eClick Here\u003c/a\u003e."},"behavioral_options":{"type":"array","items":{"type":"string","default":""},"description":"A list of behaviors that are targeted."},"domain_options":{"type":"array","items":{"type":"string","default":"www.american-express.com"},"description":"The list of domains or subdomains to be included or excluded in the campaign. \"domain_action\" must also be set. Example: [\"ford.com\", \"www.american express.com\"]"},"conversion_trackers":{"type":"array","items":{"$ref":"#/definitions/ConversionTracker","default":null}},"sub_advertiser":{"$ref":"#/definitions/AdvertiserCreate"},"all_native_ads":{"type":"array","items":{"$ref":"#/definitions/CreateCreativeRequest"},"description":"Creative model"},"geo_radius_targeting":{"$ref":"#/definitions/GeoRadiusTargeting","description":"Geo radius targeting. You can target based on latitude, longitude and a given radius."},"positive_rt_audiences":{"type":"array","items":{"type":"integer","format":"int64","default":1},"description":"A list of positive retargeting audiences attached to the campaign."},"negative_rt_audiences":{"type":"array","items":{"type":"integer","format":"int64","default":1},"description":"A list of negative retargeting audiences attached to the campaign. Used to exclude customers you have already reached."},"deal_group_ids":{"type":"array","items":{"type":"integer","format":"int64","default":12},"description":"A list of deal group ids to attach to a campaign.","deprecated":true}}},"CampaignUpdateRequest":{"required":[],"discriminator":"campaign","properties":{"id":{"type":"integer","description":"ID of the campaign.","default":1},"goal":{"type":"string","description":"The goal of the campaign. Note: use \"engagement\" for awareness or engagement campaigns","enum":["engagement","conversion"],"default":"engagement"},"optimize_type":{"type":"string","description":"The type of optimization used for the campaign: ctr (CTR floor), cpc (CPC goal).","enum":["ctr","cpc","cpe"],"default":"cpc"},"optimize_value":{"type":"number","format":"float","description":"The value of the optimization. Example: The value is 0.2 for a $0.2 CPC goal, or a 0.2% CTR floor.","default":1.5},"domain_action":{"type":"string","description":"Action to be taken on the \"domain_options\" list.","default":"exclude","enum":["include","exclude"]},"user_cpa":{"type":"number","format":"float","description":"User cost per action. Also known as `flights CPA target`.","default":1.5},"name":{"type":"string","description":"The name of the campaign.","default":"API Test Campaign"},"state":{"type":"string","description":"The state of the campaign.","enum":["active","paused"],"default":"active"},"bid_type":{"type":"string","description":"Type of bid model: cpm (Cost Per Thousand Impressions), cpc (Cost Per Click), cpe (Cost Per Engagement) bid model.","enum":["cpm","cpc","cpe"],"default":"cpm"},"budget":{"type":"number","format":"float","description":"The budget of the campaign.","default":10000.0},"is_draft":{"type":"boolean","description":"If the campaign is draft.","default":true},"daily_cap":{"type":"number","format":"float","description":"The maximum budget to be spent in a single day. This value is only used if pace_evenly is NULL or false.","default":null},"pace_evenly":{"type":"boolean","description":"Whether or not to pace the campaign budget evenly over the course of the campaign. This value is only used if a valid end_date is specified.","default":true},"start_date":{"type":"string","format":"date","description":"The date when the campaign will begin.","default":"2016-05-27"},"end_date":{"type":"string","format":"date","description":"The date when the campaign will end.","default":"2016-06-27"},"start_hour":{"type":"integer","format":"int64","description":"The campaign will start spending at this hour. The start_hour will be set to 0 if not defined or defined outside of range 0 to 23.","default":0,"minimum":0,"maximum":23},"end_hour":{"type":"integer","format":"int64","description":"The campaign will finish spending at this hour. The end_hour will be set to 0 if not defined or defined outside of range 0 to 23","default":0,"minimum":0,"maximum":23},"bid_amount_total":{"type":"number","format":"float","description":"The bid amount of the campaign.","default":5.0},"freq_cap_limit":{"type":"integer","format":"int64","description":"The user frequency cap value, which is the maximum amount of impressions that a unique user can see.","default":7},"freq_cap_time":{"type":"integer","format":"int64","description":"The length of time in milliseconds when the user frequency cap counter restarts.","default":86400000},"city_options":{"type":"string","description":"The list of city ID objects to be included in the campaign. For more information \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://docs.google.com/document/d/1tz-S6a4GDR9yq7eei0yoAzKkzrLBqQ0pelNSqAksMQY/edit#bookmark=kix.s0oqrtowdcic\"\u003eClick Here\u003c/a\u003e.","default":"Sugar Land \u003e TX \u003e US:618@ Missouri City \u003e TX \u003e US:618@ Houston \u003e TX \u003e US:618@ Austin \u003e TX \u003e US:635"},"ip_options":{"type":"string","default":"99.98.98.000,99.17.13.000","description":"String of IPs separated by commas."},"allow_iframe_engagement":{"type":"boolean","description":"Allow engagement tracking by placing add within an iframe","default":true},"is_deal_id_strict":{"type":"boolean","description":"Run only on the deal groups attached to the campaign.","default":true},"use_dma":{"type":"boolean","description":"Enable campaign to target city by Designated Market Area (DMA)."},"engagement_tracking_type":{"type":"integer","format":"int64","description":"Type of engagement tracking for post click engagement. (0 = None, 1 = IFrame, 2 = Use Stackadapt Pixel)","enum":[0,1,2],"default":0},"category_options":{"type":"array","items":{"type":"string","default":"IAB1"},"description":"The list of IAB categories to be included in the campaign. \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://docs.google.com/document/d/1tz-S6a4GDR9yq7eei0yoAzKkzrLBqQ0pelNSqAksMQY/edit#bookmark=kix.4hlozfae2aqc\"\u003eClick Here\u003c/a\u003e for full list of IB categories. Leave empty to choose all."},"country_options":{"type":"array","items":{"type":"string","default":"US"},"description":"The list of ISO 3166-1 alpha-2 country codes to be included in the campaign.","enum":["US","CA","..."]},"device_os_family_options":{"type":"array","items":{"type":"string","default":"iOS"},"description":"A list of device OS that are targeted."},"device_os_options":{"type":"array","items":{"type":"string","default":"Windows 8"},"description":"A list of specific device OS that are targeted."},"browser_options":{"type":"array","items":{"type":"string","default":"chrome"},"description":"A list of specific browswers that are targeted."},"supply_type_options":{"type":"array","items":{"type":"string","default":"web"},"description":"The list of mobile supply types to be included in the campaign.","enum":["web","app"]},"supply_source_options":{"type":"array","items":{"type":"string","default":""},"description":"List of supply source id's. See the supply_sources endpoint for a list of supply_source_options"},"us_state_options":{"type":"array","items":{"type":"string","default":"NY"},"description":"The list of ISO 3166-2 US state codes to be included in the campaign.","enum":["CA","NY","..."]},"canada_province_options":{"type":"array","items":{"type":"string","default":"ON"},"description":"The list of ISO 3166-2 Canadian province codes to be included in the campaign.","enum":["ON","BC","..."]},"uk_county_options":{"type":"array","items":{"type":"string","default":"Z5"},"description":"The list of ISO 3166-2 UK county codes to be included in the campaign.","enum":["Z5","P4","..."]},"other_state_options":{"type":"array","items":{"type":"string","default":"au:02"},"description":"The list of states (aside from those in US, UK, or Canada) to be included in the campaign. Pairs in format [country code]:[state code].","enum":["au:02"]},"device_type_options":{"type":"array","items":{"type":"string","default":"phone"},"description":"The list of device types to be included in the campaign.","enum":["desktop","tablet","phone"]},"language_options":{"type":"array","items":{"type":"string","default":"en"},"description":"A list of language(s) that are targeted. The campaign will only target sites or users whose language is included in the list."},"custom_segments_list":{"type":"array","items":{"type":"string","default":"\u003cidentifier\u003e"},"description":"The list of Custom Segments identifiers to attach to a campaign. DISCLAIMER: If you are updating one of the parameters in this list (custom_segments_list, demo_segments_ids, interest_segment_ids), include the existing values of the parameters in the request as making changes to anything in the list will cause anything that is not in the request to be detached to the campaign."},"demo_segment_ids":{"type":"array","items":{"type":"integer","format":"int64","default":11398},"description":"The list of Demographic Segments identifiers to attach to a campaign. DISCLAIMER: If you are updating one of the parameters in this list (custom_segments_list, demo_segments_ids, interest_segment_ids), include the existing values of the parameters in the request as making changes to anything in the list will cause anything that is not in the request to be detached to the campaign. For more information on the demographic segments offered \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://docs.google.com/document/d/1tz-S6a4GDR9yq7eei0yoAzKkzrLBqQ0pelNSqAksMQY/edit#bookmark=id.d91lv8j3bt9z\"\u003eClick Here\u003c/a\u003e."},"interest_segment_ids":{"type":"array","items":{"type":"integer","format":"int64","default":11398},"description":"The list of Interest and Intent Segments identifiers to attach to a campaign. DISCLAIMER: If you are updating one of the parameters in this list (custom_segments_list, demo_segments_ids, interest_segment_ids), include the existing values of the parameters in the request as making changes to anything in the list will cause anything that is not in the request to be detached to the campaign. For more information on the interest and intent segments offered \u003ca class=\"campaign-link\" target=\"_blank\" href=\"https://docs.google.com/spreadsheets/d/10B585OpPo8FMnwj75ULTtZMUpZzcojaiEqSMtuOLkNs/edit#gid=0\"\u003eClick Here\u003c/a\u003e."},"behavioral_options":{"type":"array","items":{"type":"string","default":""},"description":"A list of behaviors that are targeted."},"domain_options":{"type":"array","items":{"type":"string","default":"www.american-express.com"},"description":"The list of domains or subdomains to be included or excluded in the campaign. \"domain_action\" must also be set. Example: [\"ford.com\", \"www.american express.com\"]"},"conversion_trackers":{"type":"array","items":{"$ref":"#/definitions/ConversionTracker","default":null}},"sub_advertiser":{"$ref":"#/definitions/AdvertiserCreate"},"all_native_ads":{"type":"array","items":{"$ref":"#/definitions/CreateCreativeRequest"},"description":"Creative model"},"geo_radius_targeting":{"$ref":"#/definitions/GeoRadiusTargeting","description":"Geo radius targeting. You can target based on latitude, longitude and a given radius."},"positive_rt_audiences":{"type":"array","items":{"type":"integer","format":"int64","default":1},"description":"A list of positive retargeting audiences attached to the campaign. Ensure all of them are present (old and new) since only the items in this request will be attached."},"negative_rt_audiences":{"type":"array","items":{"type":"integer","format":"int64","default":1},"description":"A list of negative retargeting audiences attached to the campaign. Used to exclude customers you have already reached. Ensure all of them are present (old and new) since only the items in this request will be attached."},"deal_group_ids":{"type":"array","items":{"type":"integer","format":"int64","default":12},"description":"A list of deal group ids to attach to a campaign.","deprecated":true}}},"GeoRadiusTargetingResponse":{"properties":{"file_name":{"type":"string","description":"The name of the file. Must end with .csv","default":"filename.csv"},"distance_unit":{"type":"string","description":"The unit of distance for the radius.","enum":["MI","KM"],"default":"MI"},"include_web_inventory":{"type":"boolean","description":"Include the web inventory.","default":false}}},"GeoRadiusTargeting":{"properties":{"file_name":{"type":"string","description":"The name of the file. Must end with .csv","default":"filename.csv"},"file_url":{"type":"string","description":"The URL for the file. It is the combination of the url and key from presigned URL.","default":"https://www.stackadapt-filestorage.com/filea"},"distance_unit":{"type":"string","description":"The unit of distance for the radius.","enum":["MI","KM"],"default":"MI"},"include_web_inventory":{"type":"boolean","description":"Include the web inventory.","default":false}}},"SubAdvertiser":{"properties":{"id":{"type":"integer","format":"int64","description":"The ID of the campaign's advertiser.","default":20},"name":{"type":"string","description":"The name of the advertiser","default":"advertiser"},"insertion_order":{"$ref":"#/definitions/LineItem"}}},"CampaignStatus":{"properties":{"code":{"type":"string","description":"Campaign status","default":"active"},"description":{"type":"string","description":"Description of the campaign status","default":"Campaign is live and at least one creative approved"}}},"ArchiveaCampaignResponse":{"required":["status"],"discriminator":"archive_campaign","properties":{"status":{"type":"string","description":"Status of the operation","default":"ok"}}},"ConversionTracker":{"required":["id","name","conv_type","post_time"],"discriminator":"conversion tracker","properties":{"id":{"type":"integer","format":"int64","description":"The ID of the conversion_tracker.","default":102},"name":{"type":"string","description":"The name of the conversion_tracker.","default":"API Tracker"},"description":{"type":"string","description":"Some description of the conversion_tracker.","default":"This is a tracker"},"user_id":{"type":"string","description":"User who owns the conversion_tracker.","default":30},"conv_type":{"type":"string","description":"Specifies whether the conversion is matched by an impression or a click.","enum":["imp","click"],"default":"imp"},"post_time":{"type":"integer","format":"int64","description":"Time till tracker expires for each user. Max: 2592000000 (30 days)","default":2592000000},"count_type":{"type":"string","description":"Specifies whether the conversion can be counted multiple times, or only once, by the same user.","enum":["once","multiple"],"default":"once"}}},"ConversionTrackerRequest":{"required":["name","conv_type","post_time","count_type"],"discriminator":"conversion tracker","properties":{"name":{"type":"string","description":"The name of the conversion_tracker.","default":"API Tracker"},"description":{"type":"string","description":"Some description of the conversion_tracker.","default":"This is a tracker"},"conv_type":{"type":"string","description":"Specifies whether the conversion is matched by an impression or a click.","enum":["imp","click"],"default":"imp"},"post_time":{"type":"integer","format":"int64","description":"Time till tracker expires for each user. Max: 2592000000 (30 days)","default":2592000000},"count_type":{"type":"string","description":"Specifies whether the conversion can be counted multiple times, or only once, by the same user.","enum":["once","multiple"],"default":"once"}}},"UpdateConversionTrackerRequest":{"required":["id","name","conv_type","post_time","count_type"],"discriminator":"conversion tracker","properties":{"id":{"type":"integer","format":"int64","description":"The ID of the conversion_tracker.","default":102},"name":{"type":"string","description":"The name of the conversion_tracker.","default":"API Tracker"},"description":{"type":"string","description":"Some description of the conversion_tracker.","default":"This is a tracker"},"conv_type":{"type":"string","description":"Specifies whether the conversion is matched by an impression or a click.","enum":["imp","click"],"default":"imp"},"post_time":{"type":"integer","format":"int64","description":"Time till tracker expires for each user. Max: 2592000000 (30 days)","default":2592000000},"count_type":{"type":"string","description":"Specifies whether the conversion can be counted multiple times, or only once, by the same user.","enum":["once","multiple"],"default":"once"}}},"DeleteCoversionTrackerResponse":{"required":["status"],"discriminator":"delete_conversion_tracker","properties":{"status":{"type":"string","description":"Status of the operation","default":"ok"}}},"CreativeRequest":{"properties":{"id":{"type":"integer","format":"int64","description":"The ID of the creative.","default":17},"url":{"type":"string","description":"The source URL of the creative to get","default":"www.imgsrc.com/img.jpg"},"data":{"type":"string","description":"The base64 data representation of the creative","default":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAAC..."}}},"CreativeResponse":{"required":["id","url"],"properties":{"id":{"type":"integer","format":"int64","description":"The ID of the creative.","default":17},"file_name":{"type":"string","description":"The file name of the creative.","default":"ImageFile"},"url":{"type":"string","description":"The URL of where the creative is being stored.","default":"www.imgsrc.com/img.jpg"},"width":{"type":"integer","format":"int64","description":"The width of the creative.","default":300},"height":{"type":"integer","format":"int64","description":"The height of the creative.","default":300}}},"NativeAdResponse":{"required":["id","input_data","click_url","name","creatives","brandname","channel"],"discriminator":"native_ad","properties":{"id":{"type":"integer","format":"int64","description":"The ID of the native ad.","default":22},"name":{"type":"string","description":"The name of the native ad.","default":"API New Creative Ad"},"audit_status":{"type":"string","description":"The audit status of the audit.","enum":["pending","passed","failed"],"default":"pending"},"state":{"type":"string","description":"The state of the native ad.","enum":["active","paused"],"default":"active"},"status":{"$ref":"#/definitions/CreativeStatus","description":"Native ad status."},"created_at":{"type":"string","format":"date","description":"The date when the native ad was created.","default":"2016-05-27"},"updated_at":{"type":"string","format":"date","description":"The date when the native ad was last updated.","default":"2016-05-27"},"click_url":{"type":"string","description":"The click URL of the creative. Not used for App Install Campaigns, where the click url is on the campaign object.","default":"www.stackadapt.com"},"imp_tracker_urls":{"type":"array","items":{"type":"string","default":"http://tracker_url.com"},"description":"List of URLs for impression tracking."},"vast_trackers":{"type":"array","items":{"$ref":"#/definitions/VastTrackerResponse"},"description":"List of VAST trackers; only for video/CTV ads."},"brandname":{"type":"string","description":"Brand name associated with the creative.","default":"My Brand"},"cta_text":{"type":"string","description":"Call-to-Action Text. Only used on some exchanges. This field is optional.","default":""},"api_frameworks":{"type":"array","items":{"type":"string","default":""},"description":"List of supported api frameworks."},"channel":{"type":"string","description":"Campaign type","enum":["native","display","video","ctv"],"default":"native"},"input_data":{"$ref":"#/definitions/InputData","description":""},"creatives":{"type":"array","items":{"$ref":"#/definitions/CreativeResponse"},"description":""},"icon":{"$ref":"#/definitions/CreativeResponse","description":""}}},"VastTrackerResponse":{"required":["event_type","url"],"properties":{"event_type":{"type":"string","description":"The event to track","enum":["start","firstQuartile","midpoint","thirdQuartile","complete"],"default":"start"},"url":{"type":"string","description":"URL to track this event","default":"http://example.com"}}},"InputData":{"required":["heading","tagline"],"properties":{"heading":{"type":"string","description":"The heading of the ad.","default":"API Headline: Welcome to StackAdapt's API"},"tagline":{"type":"string","description":"The tagline of the ad.","default":"Welcome to StackAdapt's API. Start using it by playing around in the sandbox"},"vast_xml":{"type":"string","description":"VAST information in XML format.","default":""},"landing_url":{"type":"string","description":"URL to redirect after interaction.","default":"http://stackadapt.com"},"display_js_creative":{"type":"array","items":{"$ref":"#/definitions/DisplayJSCreative"},"description":"Display JS information."},"video_creatives":{"type":"array","items":{"$ref":"#/definitions/AudioAndVideoCreatives"},"description":""},"audio_creatives":{"type":"array","items":{"$ref":"#/definitions/AudioAndVideoCreatives"},"description":""}}},"AudioAndVideoCreatives":{"required":["s3_url","duration","width","height","file_type","bitrate"],"properties":{"s3_url":{"type":"string","description":"The S3 URL of the video/audio creative.","default":""},"width":{"type":"integer","format":"int64","description":"The width of the video/audio creative.","default":160},"height":{"type":"integer","format":"int64","description":"The height of the video/audio creative.","default":600},"file_type":{"type":"string","description":"Video/Audio file type.","default":"video/webm"},"duration":{"type":"float","description":"Duration of the video/audio creative.","default":30},"bitrate":{"type":"integer","format":"int64","description":"Bitrate of the video/audio creative.","default":380}}},"DisplayJSCreative":{"properties":{"js_code":{"type":"string","description":"JS code for the ad.","default":""},"width":{"type":"integer","format":"int64","description":"The width of the container that the ad will be displayed in. Check the UI for valid options.","default":160},"height":{"type":"integer","format":"int64","description":"The height of the container that the ad will be displayed in. Check the UI for valid options.","default":600},"img_url":{"type":"string","description":"URL for the image.","default":"http://stackadapt.com/img/logo.png"},"is_expandable":{"type":"boolean","description":"Indicates whether your ad enlarges on the screen when hovering over it for some time.","default":""},"js_code_macro":{"type":"string","description":"Macro code in JS.","default":""}}},"DeleteCreativeResponse":{"required":["status"],"discriminator":"delete_creative","properties":{"status":{"type":"string","description":"Status of the operation","default":"ok"}}},"CreateCreativeRequest":{"required":["input_data","click_url","name","creatives","brandname"],"discriminator":"native_ad","properties":{"click_url":{"type":"string","description":"The click URL of the creative. Not used for App Install Campaigns, where the click url is on the campaign object.","default":"www.stackadapt.com"},"name":{"type":"string","description":"Name of the creative.","default":"My creative"},"state":{"type":"string","description":"The state of the creative.","enum":["active","paused"],"default":"active"},"type":{"type":"string","description":"The type of the creative.","default":"native"},"proposed_brandname":{"type":"string","description":"Brand name associated with the creative.","default":"My Brand"},"cta_text":{"type":"string","description":"Call-to-Action Text. Only used on some exchanges. This field is optional.","default":""},"imp_tracker_urls":{"type":"array","items":{"type":"string","default":"http://tracker_url.com"},"description":"List of URLs for impression tracking."},"input_data":{"$ref":"#/definitions/InputDataRequest","description":""},"creatives_attributes":{"type":"array","items":{"$ref":"#/definitions/CreativeAttribute"},"description":""},"icon_attributes":{"$ref":"#/definitions/CreativeAttribute","description":""}}},"UpdateCreativeRequest":{"required":["id","input_data","click_url","name","creatives","brandname"],"discriminator":"native_ad","properties":{"id":{"type":"integer","format":"int64","description":"Id of the creative.","default":1},"click_url":{"type":"string","description":"The click URL of the creative. Not used for App Install Campaigns, where the click url is on the campaign object.","default":"www.stackadapt.com"},"name":{"type":"string","description":"Name of the creative.","default":"My creative"},"state":{"type":"string","description":"The state of the creative.","enum":["active","paused"],"default":"active"},"type":{"type":"string","description":"The type of the creative.","default":"native"},"proposed_brandname":{"type":"string","description":"Brand name associated with the creative.","default":"My Brand"},"cta_text":{"type":"string","description":"Call-to-Action Text. Only used on some exchanges. This field is optional.","default":""},"imp_tracker_urls":{"type":"array","items":{"type":"string","default":"http://tracker_url.com"},"description":"List of URLs for impression tracking."},"input_data":{"$ref":"#/definitions/UpdateInputDataRequest","description":""},"creatives_attributes":{"type":"array","items":{"$ref":"#/definitions/CreativeAttribute"},"description":""},"icon_attributes":{"$ref":"#/definitions/CreativeAttribute","description":""}}},"InputDataRequest":{"required":["heading","tagline"],"properties":{"heading":{"type":"string","description":"The heading of the ad.","default":"API Headline: Welcome to StackAdapt's API"},"tagline":{"type":"string","description":"The tagline of the ad.","default":"Welcome to StackAdapt's API. Start using it by playing around in the sandbox"},"width":{"type":"integer","format":"int64","description":"The width of the container that the ad will be displayed in. Check the UI for valid options.","default":160},"height":{"type":"integer","format":"int64","description":"The height of the container that the ad will be displayed in. Check the UI for valid options.","default":600},"js_code":{"type":"string","description":"Javascript code.","default":""},"is_expandable":{"type":"boolean","description":"Indicates whether your ad enlarges on the screen when hovering over it for some time.","default":""},"img_url":{"type":"string","description":"URL for the image (creative).","default":""},"display_js_creative":{"type":"array","items":{"$ref":"#/definitions/RequestDisplayJSCreative"},"description":"Display JS information."}}},"UpdateInputDataRequest":{"required":["heading","tagline"],"properties":{"heading":{"type":"string","description":"The heading of the ad.","default":"API Headline: Welcome to StackAdapt's API"},"tagline":{"type":"string","description":"The tagline of the ad.","default":"Welcome to StackAdapt's API. Start using it by playing around in the sandbox"},"width":{"type":"integer","format":"int64","description":"The width of the container that the ad will be displayed in. Check the UI for valid options.","default":160},"height":{"type":"integer","format":"int64","description":"The height of the container that the ad will be displayed in. Check the UI for valid options.","default":600},"js_code":{"type":"string","description":"Javascript code.","default":""},"is_expandable":{"type":"boolean","description":"Indicates whether your ad enlarges on the screen when hovering over it for some time.","default":""},"img_url":{"type":"string","description":"URL for the image (creative).","default":""},"display_js_creative":{"type":"array","items":{"$ref":"#/definitions/RequestDisplayJSCreative"},"description":"Display JS information."}}},"CreativeAttribute":{"properties":{"id":{"type":"integer","format":"int64","description":"If you want to attach an existing creative, use this field. Otherwise, leave it blank.","default":1},"url":{"type":"string","description":"URL for the image for the creative.","default":"http://www.stackadapt.com/img"},"data":{"type":"string","description":"Data regarding the image for the creative.","default":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAAC.."}}},"RequestDisplayJSCreative":{"properties":{"js_code":{"type":"string","description":"JS code for the ad.","default":""},"width":{"type":"integer","format":"int64","description":"The width of the container that the ad will be displayed in. Check the UI for valid options.","default":160},"height":{"type":"integer","format":"int64","description":"The height of the container that the ad will be displayed in. Check the UI for valid options.","default":600},"img_url":{"type":"string","description":"URL for the image.","default":"http://stackadapt.com/img/logo.png"},"is_expandable":{"type":"boolean","description":"Indicates whether your ad enlarges on the screen when hovering over it for some time.","default":""}}},"CreativeStatus":{"properties":{"code":{"type":"string","description":"Creative status","default":"active"},"description":{"type":"string","description":"Description of the creative status","default":"Creative is live"}}},"CampaignGroupRequest":{"required":["name","sub_advertiser"],"discriminator":"campaign_group","properties":{"name":{"type":"string","description":"The name of the line item.","default":"API Test LineItem"},"state":{"type":"string","description":"The state of the line item.","enum":["active","paused","null"],"default":"active"},"budget":{"type":"number","format":"float","description":"The budget of the line item.","default":10000.0},"start_date":{"type":"string","format":"date","description":"The timestamp in UTC when the line item will begin.","default":"2019-05-27T00:00:00.000Z"},"end_date":{"type":"string","format":"date","description":"The timestamp in UTC when the line item will end.","default":"2019-07-27T00:00:00.000Z"},"daily_cap":{"type":"number","format":"float","description":"The maximum budget (revenue type) to be spent in a single day. This value is only used if pace_evenly is NULL or false.","default":null},"revenue_type":{"type":"string","description":"With budget type set to revenue, choose a type of revenue tracking.","enum":["margin"],"default":"margin"},"revenue_value":{"type":"number","format":"float","description":"The value of the revenue type. For example, 10 with a revenue type 'margin' would have revenue computed with a 10% margin.","default":10.0},"revenue_track":{"type":"boolean","description":"Revenue track.","default":true},"pace_evenly":{"type":"boolean","description":"Whether or not to pace the campaign budget evenly over the course of the line item (Campaign Group). This value is only used if a valid end_date is specified.","default":true},"budget_type":{"type":"string","description":"Type of tracking model: cost (Tracked by cost), click (Tracked by clicks, budget field should be # of clicks), imp (Tracked by impressions, budget field should be # of impressions) bid model.","enum":["cost","click","imp","revenue"],"default":"cost"},"black_list_options":{"type":"string","default":"www.american-express.com, www.google.com","description":"The list of domains or subdomains to be excluded in the campaign. \"domain_action\" must also be set. Example: \"www.american-express.com, www.google.com\""},"purchase_order_number":{"type":"string","description":"PO numbers can be used to align line_items with your own accounting systems","default":null},"sub_advertiser":{"$ref":"#/definitions/Advertiser","description":"The object accepts a 'id' field in which you can specify an existing advertiser ID."}}},"CampaignGroupResponse":{"required":["id","name"],"discriminator":"line_item","properties":{"id":{"type":"integer","format":"int64","description":"The ID of the line item.","default":55},"name":{"type":"string","description":"The name of the line item.","default":"API Test LineItem"},"state":{"type":"string","description":"The state of the line item.","enum":["active","paused","null"],"default":"active"},"status":{"$ref":"#/definitions/CGStatus","description":"Campaign group status."},"daily_cap":{"type":"number","format":"float","description":"The maximum budget (revenue type) to be spent in a single day. This value is only used if pace_evenly is NULL or false.","default":null},"pace_evenly":{"type":"boolean","description":"Whether or not to pace the campaign budget evenly over the course of the line item (Campaign Group). This value is only used if a valid end_date is specified.","default":true},"black_list_options":{"type":"string","default":"www.american-express.com, www.google.com","description":"The list of domains or subdomains to be excluded in the campaign. \"domain_action\" must also be set. Example: \"www.american-express.com, www.google.com\""},"revenue_type":{"type":"string","description":"With budget type set to revenue, choose a type of revenue tracking.","enum":["margin"],"default":"margin"},"revenue_value":{"type":"number","format":"float","description":"The value of the revenue type. For example, 10 with a revenue type 'margin' would have revenue computed with a 10% margin.","default":10.0},"purchase_order_number":{"type":"string","description":"PO numbers can be used to align line_items with your own accounting systems","default":null},"all_campaign_ids":{"type":"array","description":"Ids of all attached campaigns","items":{"type":"integer","format":"int64","default":1}},"advertiser_id":{"type":"integer","format":"int64","description":"The ID of the line item's advertiser.","default":12},"start_date":{"type":"string","format":"date","description":"The timestamp in UTC when the line item will begin.","default":"2019-05-27T00:00:00.000Z"},"end_date":{"type":"string","format":"date","description":"The timestamp in UTC when the line item will end.","default":"2019-07-27T00:00:00.000Z"},"budget":{"type":"number","format":"float","description":"The budget of the line item.","default":10000.0}}},"CGStatus":{"properties":{"code":{"type":"string","description":"Campaign group status","default":"active"},"description":{"type":"string","description":"Description of the campaign group status","default":"Campaign group is live"}}},"DeleteCampaignGroupResponse":{"required":["status"],"discriminator":"delete_campaign_group","properties":{"status":{"type":"string","description":"Status of the operation","default":"ok"}}},"Advertiser":{"required":["id"],"properties":{"id":{"type":"integer","description":"The id of an existing advertiser","default":55}}},"AdvertiserResponse":{"required":["id"],"discriminator":"sub_advertiser","properties":{"id":{"type":"integer","format":"int64","description":"The ID of the advertiser.","default":1},"name":{"type":"string","description":"Name of the advertiser","default":"Name"},"description":{"type":"string","description":"The description of the advertiser","default":""},"all_line_item_ids":{"type":"array","description":"Ids of all attached campaign groups","items":{"type":"integer","format":"int64","default":1}}}},"AdvertiserRequest":{"required":["id","name"],"discriminator":"advertiser","properties":{"id":{"type":"integer","format":"int64","description":"The ID of the advertiser.","default":55},"name":{"type":"string","description":"The name of the advertiser.","default":"API Test Advertiser"}}},"CreateAdvertiserRequest":{"required":["name"],"discriminator":"advertiser","properties":{"name":{"type":"string","description":"The name of the advertiser.","default":"API Test Advertiser"}}},"ArchiveAndRestoreAdvertiserResponse":{"required":["status"],"discriminator":"archive_advertiser","properties":{"status":{"type":"string","description":"Status of the operation","default":"ok"}}},"UpdateSubAdvertiserResponse":{"required":["id","name"],"discriminator":"update_advertiser","properties":{"id":{"type":"integer","format":"int64","description":"The ID of the advertiser.","default":1},"name":{"type":"string","description":"Name of the advertiser","default":"Name"},"description":{"type":"string","description":"The description of the advertiser","default":""},"all_line_item_ids":{"type":"array","description":"Ids of all attached campaign groups","items":{"type":"intger","format":"int64","default":1}}}},"ErrorModel":{"required":["object_type"],"properties":{"object_type":{"type":"array","items":{"$ref":"#/definitions/ErrorObjectModel"}}}},"ErrorObjectModel":{"required":["message"],"properties":{"message":{"type":"string"}}}}}