API Reference
Reporting

Run a synchronous report

GET/open_api/v1.3/report/integrated/get/
Base URL: https://tiktok-ads.mimicr.dev · provider: https://business-api.tiktok.com

Use this endpoint to run a synchronous report. Mimicr simulates BASIC reports at the AUCTION_ADVERTISER, AUCTION_CAMPAIGN, AUCTION_ADGROUP and AUCTION_AD levels, and AUDIENCE reports by gender and age.

  • dimensions takes at most one ID dimension and one time dimension (stat_time_day or stat_time_hour).
  • With stat_time_day the range is at most 30 days (365 otherwise; one day for stat_time_hour).
  • Metric values are strings. Days follow the advertiser time zone.
  • Deleted objects are left out (campaign_status, adgroup_status and ad_status default to STATUS_NOT_DELETE): add {"field_name":"ad_status","filter_type":"IN","filter_value":"[\"STATUS_ALL\"]"} to keep them.

Authorization

Bearer token in the Authorization: Bearer <token> header. See Authentication.

Headers

Access-Tokenstringrequired

Authorized access token, sent in this header (not Authorization: Bearer). Marketing API tokens never expire.

Query parameters

advertiser_idstring

You need to pass in either advertiser_id/advertiser_ids or bc_id.

advertiser_idsstring[]

When report_type is set to BASIC or AUDIENCE, you need to pass in either advertiser_id or advertiser_ids. If you pass in both advertiser_id and advertiser_ids, advertiser_id will be ignored. Valid when report_type is BASIC or AUDIENCE.

service_typestring

Not supported when report_type is BC.

AUCTIONRESERVATION
report_typestringrequired

Report type.

BASICAUDIENCEPLAYABLE_MATERIALCATALOGBCTT_SHOPAUCTION
data_levelstring

Not supported when report_type is BC. Required when report_type is BASIC,AUDIENCE or CATALOG.

AUCTION_ADAUCTION_ADGROUPAUCTION_CAMPAIGNAUCTION_ADVERTISERRESERVATION_ADRESERVATION_ADGROUPRESERVATION_CAMPAIGNRESERVATION_ADVERTISER
dimensionsstring[]required

Grouping conditions. For example: ["campaign_id", "stat_time_day"] indicates that both campaign_id and stat_time_day (days) are grouped.

metricsstring[]

Metrics to query.

enable_total_metricsboolean

Whether to enable the total added-up data for your requested metrics. When enable_total_metrics is enabled, we will provide the aggregate data for all pages as you query different pages. Under this condition, you only need to specify this field when requesting data for the first page.

start_datestring

This field is required when query_lifetime is false or not specified.

end_datestring

This field is required when query_lifetime is false or not specified.

query_lifetimeboolean

Supported when report_type is BASIC or PLAYABLE_MATERIAL.

order_fieldstring

Sorting field.

order_typestring

Sorting order.

ASCDESC
filteringobject[]

Filters, as a JSON array of {field_name, filter_type, filter_value}; filter_value is a JSON array string for IN. Mimicr applies campaign_ids, adgroup_ids, ad_ids, campaign_status, adgroup_status, ad_status (default STATUS_NOT_DELETE; STATUS_ALL keeps deleted objects), objective_type, optimization_goal, promotion_type, billing_event and campaign_name (MATCH).

query_modestring

Not supported when report_type is BC.

REGULARCHUNK
pagenumber

Current page number. Default value: 1. Value range: ≥ 1.

page_sizenumber

Pagination size.

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.
codenumber

Return code. 0 means success; see the return codes appendix for the others.

messagestring

Return message: OK on success, otherwise the error description.

request_idstring

The log ID of the request, which uniquely identifies it (also sent in the X-Tt-Logid header).

dataobject

Returned data.

Show child attributes
total_metricsobject

The total added-up data for your requested metrics. Returned when you enable enable_total_metrics in the request.

Show child attributes
spendstring

The total added-up data for spend.

impressionsstring

The total added-up data for impressions.

listobject[]

Data list.

Show child attributes
dimensionsobject

All requested dimension data.

Show child attributes
ad_idstring

Returned when dimensions contains ad_id. Ad ID.

stat_time_daystring

Returned when dimensions contains stat_time_day. The time (days) when the reporting occurred.

metricsobject

All requested metric data.

Show child attributes
spendstring

Total spend.

impressionsstring

Number of impression.

page_infoobject

Pagination information.

Show child attributes
pagenumber

Current page number. Default value: 1. Value range: ≥ 1.

page_sizenumber

Page size.

total_numbernumber

Total number of results.

total_pagenumber

Total pages of results.

501The route or feature is documented by TikTok but outside Mimicr's integration core: code 40014 with HTTP 501.
codeinteger

Return code. 0 means success; see the return codes appendix for the others.

messagestring

Return message: OK on success, otherwise the error description.

request_idstring

The log ID of the request, which uniquely identifies it (also sent in the X-Tt-Logid header).