AI-generated Key Takeaways
-
This document details how to generate tags for a placement using an HTTP POST request.
-
The request requires a user profile ID as a path parameter and can optionally specify placement IDs, a required campaign ID, and tag formats via query parameters.
-
The request body must be empty.
-
The successful response body contains a list of PlacementTag objects, each including a placement ID and an array of TagData objects with details like format and tag strings.
-
This operation requires the
https://www.googleapis.com/auth/dfatraffickingOAuth scope for authorization.
- HTTP request
- Path parameters
- Query parameters
- Request body
- Response body
- Authorization scopes
- PlacementTag
- TagData
- Try it!
Generates tags for a placement.
HTTP request
POST https://dfareporting.googleapis.com/dfareporting/v5/userprofiles/{profileId}/placements/generatetags
The URL uses gRPC Transcoding syntax.
Path parameters
| Parameters | |
|---|---|
profileId |
User profile ID associated with this request. |
Query parameters
| Parameters | |
|---|---|
body |
Empty body |
placementIds[] |
Generate tags for these placements. |
campaignId |
Generate placements belonging to this campaign. This is a required field. |
tagFormats[] |
Tag formats to generate for these placements.
can only be generated for 1x1 placements. |
Request body
The request body must be empty.
Response body
Placement GenerateTags Response
If successful, the response body contains data with the following structure:
| JSON representation |
|---|
{
"placementTags": [
{
object ( |
| Fields | |
|---|---|
placementTags[] |
Set of generated tags for the specified placements. |
kind |
Identifies what kind of resource this is. Value: the fixed string
. |
Authorization scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/dfatrafficking
PlacementTag
Placement Tag
| JSON representation |
|---|
{
"placementId": string,
"tagDatas": [
{
object ( |
| Fields | |
|---|---|
placementId |
Placement ID |
tagDatas[] |
Tags generated for this placement. |
TagData
Placement Tag Data
| JSON representation |
|---|
{
"format": enum ( |
| Fields | |
|---|---|
format |
TagData tag format of this tag. |
impressionTag |
Tag string for serving an ad. |
clickTag |
Tag string to record a click. |
adId |
Ad associated with this placement tag. Applicable only when
is
. |
creativeId |
Creative associated with this placement tag. Applicable only when
is
. |