새 실적 최대화 캠페인을 처음부터 생성하려면 다음을 최소한 만들어야 합니다.
캠페인 및 예산은 모든 종류의 캠페인 유형을 만드는 데 유용하며 확장 소재 관련 작업은 특히 실적 최대화 캠페인을 만드는 데 유용합니다.
이 가이드에서는 변형에 사용할 JavaScript 객체만 제공하므로 변형 전략을 숙지해야 합니다.
예산
예산은 공유할 수 없으며 계정에서 고유한 이름을 지정해야 합니다. CampaignBudgetOperation
를 사용합니다.
const budgetOperation = {
"campaignBudgetOperation": {
"create": {
"resourceName": `customers/${customerId}/campaignBudgets/${getNextTempId()}`,
"name": "Performance Max campaign budget",
"amountMicros": "50000000",
"deliveryMethod": "STANDARD",
"explicitlyShared": false
}
}
}
operations.push(budgetOperation);
캠페인
캠페인은 이전에 생성된 예산을 참조해야 하므로 임시 ID로 자체 리소스 이름을 지정하는 것 외에도 이전 단계에서 설정한 정확한 리소스 이름이 필요합니다. 이 요청에서 이전에 생성된 예산을 고유하게 식별할 수 있도록 캠페인을 만들기 위해
CampaignOperation
를 사용합니다.
const campaignOperation = {
"campaignOperation": {
"create": {
"resourceName": `customers/${customerId}/campaigns/${getNextTempId()}`,
"name": "Performance Max campaign",
"status": "PAUSED",
"advertisingChannelType": "PERFORMANCE_MAX",
"campaignBudget": budgetOperation.campaignBudgetOperation.create.resourceName,
"biddingStrategyType": "MAXIMIZE_CONVERSION_VALUE",
"startDate": "20240314",
"endDate": "20250313",
"urlExpansionOptOut": false,
"maximizeConversionValue": {
"targetRoas": 3.5
}
}
}
}
operations.push(campaignOperation);
애셋 그룹
이 캠페인의 애셋 그룹에는 캠페인 참조가 필요하며 나중에 확장 소재를 캠페인에 연결할 때 참조해야 합니다. AssetGroupOperation
을 사용합니다.
const assetGroupOperation = {
"assetGroupOperation": {
"create": {
"resourceName": `customers/${customerId}/assetGroups/${getNextTempId()}`,
"campaign": campaignOperation.campaignOperation.create.resourceName,
"name": "Performance Max asset group",
"finalUrls": [
"http://www.example.com"
],
"finalMobileUrls": [
"http://www.example.com"
],
"status": "PAUSED"
}
}
}
operations.push(assetGroupOperation);
애셋 그룹 링크
이제 애셋 그룹과 확장 소재 (이전 단계에서)가 있으므로 실적 최대화 캠페인에서 사용할 확장 소재를 알 수 있도록 애셋 그룹과 확장 소재를 연결해야 합니다. 애셋 그룹을 처음 만드는 것과 동일한 요청에서 이 작업을 해야 합니다. 이렇게 하려면 AssetGroupAssetOperation
를 사용합니다.
올바른 애셋 리소스 이름을 제공하고 fieldType
를 연결하는 애셋의 적절한 값으로 수정해야 합니다. 유효한 필드 유형의 전체 목록을 확인하세요.
실적 최대화 캠페인의 최소 요건을 충족하려면 이러한 작업을 여러 번 수행해야 합니다.
operations.push({
"assetGroupAssetOperation": {
"create": {
"assetGroup": assetGroupOperation.assetGroupOperation.create.resourceName,
// assetResourceName here is a placeholder; you will need to determine
// the correct resource name to use depending on which asset you want
// to add to the asset group.
"asset": assetResourceName,
"fieldType": "HEADLINE"
}
}
});