API Reference
Update an ad group
/open_api/v1.3/adgroup/update/https://tiktok-ads.mimicr.dev · provider: https://business-api.tiktok.comUse this endpoint to update an ad group. The update mode is full replacement, not incremental update: in Mimicr, omitted targeting fields (location_ids, zipcode_ids, languages, age_groups, gender, interest_*, audience_ids, excluded_audience_ids, operating_systems, dayparting) reset to their defaults, so a body without location_ids fails with Missing required field(s): location_ids. and a reset is reported in the header X-Mimicr-Warning. Send the whole ad group, as on create. The homologation toggle adgroupUpdateAsPatch makes omitted fields keep their values.
placement_type, placements, optimization_goal, billing_event, promotion_type, budget_mode and campaign_id cannot change. A new budget must be at least 105% of the current spend.
Authorization
Bearer token in the Authorization: Bearer <token> header. See Authentication.
Headers
Authorized access token, sent in this header (not Authorization: Bearer). Marketing API tokens never expire.
Body
application/jsonAd group ID.
Advertiser ID.
Ad group name, maximum character allowed is 512 and it cannot contain emoji.
Whether to disable comments on ads in the ad group.
Whether to disable sharing of ads in the ad group to third-party platforms.
IDs of the locations that you want to target. You can set location_ids or zipcode_ids or both. Location ids from TikTok's Location IDs list (Brazil is 3469034). A country together with one of its states is refused as overlapping.
Zip code IDs or postal code IDs that you want to use to target locations. You need to set location_ids or zipcode_ids or both.
Codes of the languages that you want to target. For the list of languages codes supported, see Enumeration - Language Code.
Gender that you want to target. Enum: GENDER_FEMALE,GENDER_MALE,GENDER_UNLIMITED
Age groups you want to target.
AGE_13_17Spending power that you want to target.
ALLHIGHHousehold income that you want to target. Enum values: TOP5(Top 5% of ZIP codes), TOP10(Top 10% of ZIP codes), TOP10_25(Top 10% -25% of ZIP codes), TOP25_50(Top 25% - 50% of ZIP codes).
TOP5TOP10TOP10_25TOP25_50An list of audience IDs. You can get audience IDs by using the /dmp/custom_audience/list/ endpoint.
A list of audience IDs to be excluded. You can get audience IDs by using the /dmp/custom_audience/list/ endpoint.
IDs of general interest categories that you want to use to target audiences.
IDs of additional interest categories that you want to use to target audience.
A list of targeting behavioral category objects.
Device operating systems that you want to target.
ANDROIDIOSDevice connection types that you want to target. For enum values, see Enumeration - Connection Type.
Targeting device price range. 10000 means 1000+. The numbers must be in multiples of 50. Important: The upper limit you set will be added by 50 and the resulting new number will be used as the actual upper limit for device targeting. The actual upper limit is shown in the ad group settings in TikTok Ads Manager.
Advertising budget. It cannot be updated when Campaign Budget Optimization (budget_optimize_on) is on. For how to configure budget settings, see Budget.
The schedule type can be either SCHEDULE_START_END or SCHEDULE_FROM_NOW.
Required when you pass in schedule_type. Schedule start time (UTC+0), in the format of "YYYY-MM-DD HH:MM:SS". Mimicr rejects a start more than 12 hours in the past.
Required when schedule_type is SCHEDULE_START_END. Schedule end time (UTC+0), in the format of "YYYY-MM-DD HH:MM:SS".
Ad delivery arrangement, in the format of a string that consists of 48 x 7 characters. Each character is mapped to a 30-minute timeframe from Monday to Sunday. Each character can be set to either 0 or 1. 1 represents delivery in the 30-minute timeframe, and 0 stands for non-delivery in the 30-minute timeframe. In Mimicr the slots follow the advertiser time zone.
Frequency, together with frequency_schedule, controls how often people see your ad (only available for REACH ads).
Frequency schedule, together with frequency, controls how often people see your ad (only available for REACH ads). See frequency fields for more.
Valid only when bid_type is BID_TYPE_CUSTOM and billing_event is CPC, CPM, or CPV. Bid price. The average cost per result that you want to achieve (for Cost Cap bidding strategy).
Valid only when bid_type is BID_TYPE_CUSTOM and billing_event is OCPM. Where you can set a target cost per conversion for oCPM (Optimized Cost per Mille).
You can choose between PACING_MODE_SMOOTH and PACING_MODE_FAST. For PACING_MODE_SMOOTH, the budget is allocated evenly within the scheduled time. PACING_MODE_FAST would consume budget and produce results as soon as possible. In Mimicr it is enforced as documented (Missing required field(s): pacing.) unless the homologation toggle lenientRequiredFields is on, which defaults it to PACING_MODE_SMOOTH.
Responses
200Response envelope {code, message, request_id, data}. code 0 (message "OK") is success. Validation and business errors also come with HTTP 200 and a non-zero code: check code, not the HTTP status.
Return code. 0 means success; see the return codes appendix for the others.
Return message: OK on success, otherwise the error description.
The log ID of the request, which uniquely identifies it (also sent in the X-Tt-Logid header).
Returned data.
Show child attributes
Advertiser ID.
Campaign ID.
The name of the campaign that the ad group belongs to.
Ad group ID.
Ad group name.
The time at which the ad group was created, in the format of "YYYY-MM-DD HH:MM:SS".
The time at which the ad group was modified, in the format of "YYYY-MM-DD HH:MM:SS".
Promotion type (Optimization location). You can decide where you'd like to promote your products using this field. For value definitions, see Enumeration - Promotion Type.
The promotion type for Lead Generation objective.
INSTANT_PAGEEXTERNAL_WEBSITEUNSETPixel ID. Only applicable for landing pages.
Conversion event for the ad group. See Conversion events for more.
The placement strategy that decides where your ads will be shown. Enum values: PLACEMENT_TYPE_AUTOMATIC (Automatic placement), PLACEMENT_TYPE_NORMAL (Select placement).
PLACEMENT_TYPE_AUTOMATICPLACEMENT_TYPE_NORMALThe apps where you want to deliver your ads. For enum values, see Enumeration - Placement.
Whether to disable comments on ads in the ad group.
Whether to disable downloading videos from ads in the ad group.
Whether to disable sharing of ads in the ad group to third-party platforms.
Whether to enable automated targeting. Enum values: True, False.
IDs of the targeted locations. Use Get locations to get available locations. Location ids from TikTok's Location IDs list (Brazil is 3469034). A country together with one of its states is refused as overlapping.
Zip code IDs or postal code IDs of the targeted locations.
Codes of the languages that you want to target. For the list of languages codes supported, see Enumeration - Language Code.
Gender that you want to target. Enum values: GENDER_FEMALE,GENDER_MALE,GENDER_UNLIMITED
GENDER_FEMALEGENDER_MALEGENDER_UNLIMITEDAge groups you want to target. For enum values, see Enumeration - Age Group.
Spending power that you want to target. Enum values: ALL, HIGH. If it is set to HIGH, you can target high spending users who typically spend more on purchases on TikTok ads than average users.
ALLHIGHA list of audience IDs.
A list of excluded audience ID.
IDs of general interest keywords that you want to use to target audiences.
IDs of additional interest keywords that you want to use to target audiences.
Device operating systems that you want to target. Only one value is allowed. Enum: ANDROID, IOS
Whether the campaign will be counted against the iOS 14 dedicated campaign quota. Enum: OCCUPIED, UNOCCUPIED. For non-R&F campaigns, when ios14_targeting is IOS14_PLUS, this field is automatically set to OCCUPIED.
NO_BRAND_SAFETYEXPANDED_INVENTORYSTANDARD_INVENTORYLIMITED_INVENTORYTHIRD_PARTYInventory filtering (filtering security videos, hides unsafe videos), valid only for the PLACEMENT_TIKTOK placement. Optional values are: true to filter, false not to filter.
Budget mode. If Campaign Budget Optimization is enabled, BUDGET_MODE_INFINITE will be returned. For more information about budget modes, see Budget.
Ad budget. Returns 0.0 when Campaign Budget Optimization (budget_optimize_on) is on.
Scheduled ad budget for next day. A value not equal to 0 means the scheduled budget is set and the value represents the budget; a value equals to 0 means the scheduled budget is not set.
The schedule type can be either SCHEDULE_START_END or SCHEDULE_FROM_NOW. If you choose SCHEDULE_START_END, you need to specify a start time and an end time. If you choose SCHEDULE_FROM_NOW, you only need to specify a start time.
Ad delivery start time (UTC+0). Format should be YYYY-MM-DD HH:MM:SS Mimicr rejects a start more than 12 hours in the past.
Ad delivery end time (UTC+0). Format should be YYYY-MM-DD HH:MM:SS
Ad delivery arrangement, in the format of a string that consists of 48 x 7 characters. Each character is mapped to a 30-minute timeframe from Monday to Sunday. Each character can be set to either 0 or 1. 1 represents delivery in the 30-minute timeframe, and 0 stands for non-delivery in the 30-minute timeframe. In Mimicr the slots follow the advertiser time zone.
The measurable results that you'd like to drive your ads with. For enum values, see Enumeration - Optimization Goal.
Frequency, together with frequency_schedule, controls how often people see your ad (only available for REACH ads). For example, frequency = 2 frequency_schedule = 3 means "show ads no more than twice every 3 day".
Frequency schedule, together with frequency, controls how often people see your ad (only available for REACH ads). See frequency fields for more.
Bidding strategy that determines how the system manages your cost per result, spends your budget, and how it delivers ads. See Enumeration - Bidding Strategy.
Bid price. The average cost per result that you want to achieve (for Cost Cap bidding strategy).
Where you can set a target cost per conversion for oCPM(Optimized Cost per Mille).
Bidding strategy for in-app events. For enum values and their descriptions, see Enumeration - Deep-level Bidding Strategy.
How you calculate and measure Cost per View.
Click-through window for the ad group. This attribution window is the time between when a person clicks your ad and then takes an action.
OFFONE_DAYSEVEN_DAYSFOURTEEN_DAYSTWENTY_EIGHT_DAYSView-through window for the ad group. This attribution window is the time between when a person views your ad and then takes an action.
OFFONE_DAYSEVEN_DAYSBilling event. To learn about the enum values, see Enumerations - Billing Event.
You can choose between PACING_MODE_SMOOTH and PACING_MODE_FAST. For PACING_MODE_SMOOTH, the budget is allocated evenly within the scheduled time. PACING_MODE_FAST would consume budget and produce results as soon as possible. In Mimicr it is enforced as documented (Missing required field(s): pacing.) unless the homologation toggle lenientRequiredFields is on, which defaults it to PACING_MODE_SMOOTH.
Operation status.
ENABLEDISABLEFROZENAd group status See Enumeration - Ad group status for optional.
The strategy that your creatives will be delivered. Enum values: CUSTOM(custom), DYNAMIC(Automated Creative Optimization) (Deprecated), and SMART_CREATIVE(Smart Creative).
CUSTOMDYNAMICSMART_CREATIVEWhether the campaign is a new structure.
Whether to skip the learning stage.
Pagination information.
Show child attributes
Current page number. Default value: 1. Value range: ≥ 1.
Paging Size.
Total number of results.
Total pages of results.
501The route or feature is documented by TikTok but outside Mimicr's integration core: code 40014 with HTTP 501.
Return code. 0 means success; see the return codes appendix for the others.
Return message: OK on success, otherwise the error description.
The log ID of the request, which uniquely identifies it (also sent in the X-Tt-Logid header).