Contents

Query Ad Groups

Query ad groups using filters, sorting, and pagination.

URL

POST https://api.ads.apple.com/v1/adgroups/query

Header Parameters

NameTypeDescription
X-Ap-Context Requiredstring

Response Codes

StatusReasonTypeDescription
200OK
Content-Type: application/json
AdGroupQueryResponse
400Bad Request
Content-Type: application/json
ErrorResponse
401Unauthorized
Content-Type: application/json
ErrorResponse
403Forbidden
Content-Type: application/json
ErrorResponse
404Not Found
Content-Type: application/json
ErrorResponse
429Too Many Requests
Content-Type: application/json
ErrorResponse
500Internal Server Error
Content-Type: application/json
ErrorResponse

Discussion

This endpoint queries ad groups using a standard QueryRequest body. Filter by campaignId to scope results to a specific campaign. An empty request body returns all non-deleted ad groups across all campaigns in the ad account with default pagination.

Each result in the response includes the full targeting and bidStrategy nested objects, making this the primary endpoint for auditing ad group configuration at scale.

See QueryFilterOperator for the full set of supported comparison operators.

Filterable Fields

Field

Type

Operators

Sortable

Description

id

integer

EQUALS, IN

Yes (default)

The unique identifier for the ad group.

campaignId

integer

EQUALS

Yes

The campaign this ad group belongs to.

name

string

EQUALS, STARTS_WITH

Yes

The advertiser-given name of the ad group.

status

string (enum)

EQUALS, IN

Yes

Advertiser-configurable status. See Adgroupstatus.

startTime

string (ISO 8601)

LESS_THAN, GREATER_THAN

Yes

Ad group schedule start time.

endTime

string (ISO 8601)

LESS_THAN, GREATER_THAN

Yes

Ad group schedule end time.

deleted

boolean

EQUALS

Yes

Whether the ad group has been deleted.

The request body is a QueryRequest composed of QueryFilter conditions and QuerySort directives (QuerySortOrder), controlled by QueryPagination.

Payload Examples

See Also