모바일 앱 맞춤 타겟

사람들의 행동을 기반으로 앱에서 여러분의 기준에 맞는 타겟을 빌드합니다. 이 기능을 사용하면 다음과 같은 타겟을 빌드할 수 있습니다.

  • "최근 10일 이내에 레벨 8을 통과한 사람"
  • "최근 8일 이내에 앱을 사용했지만 아무것도 구매하지 않은 사람"
  • "장바구니에 담았지만 구매하지 않은 사람"

이 솔루션은 Facebook SDK, 앱 이벤트 API 또는 Mobile Measurement Partner를 통해 로그 기록이 있고 이름이 지정된 이벤트를 사용합니다. 예를 들어 로그 기록이 있는 이벤트는 "설치함", "장바구니에 추가함", "구매함" 또는 "레벨 달성함" 등이 있습니다.

제한 사항

  • 참여 맞춤 타겟의 subtype은 동영상에 대해서만 지원됩니다.
  • 포함 타게팅을 위한 모바일 앱 맞춤 타겟은 더 이상 iOS 14.5 SKAdNetwork 캠페인의 POST /{ad-account-id}/adsets 엔드포인트에 지원되지 않습니다.
  • 새로운 iOS 14.5 앱 설치 캠페인에서는 이제 앱 연결 타게팅을 사용할 수 없습니다.

타겟 만들기

광고 계정에서 모바일 앱의 맞춤 타겟을 만들려면 광고 관리자에서 맞춤 타겟 서비스 약관에 동의해야 합니다. 약관에 서명하려면 다음 조건을 충족해야 합니다.

  • 광고 계정의 관리자, 개발자 또는 인사이트 사용자여야 합니다.
  • 광고 계정이 설정에서 광고 계정으로 등록되어 있어야 합니다.

타겟을 만드는 방법은 다음과 같습니다.

curl -X POST \ -F 'name="My Test Website Custom Audience"' \ -F 'rule={ "inclusions": { "operator": "or", "rules": [ { "event_sources": [ { "id": "<APP_ID>", "type": "app" } ], "retention_seconds": 8400, "filter": { "operator": "and", "filters": [ { "field": "event", "operator": "eq", "value": "fb_mobile_purchase" } ] } } ] } }' \ -F 'prefill=1' \ -F 'access_token=<ACCESS_TOKEN>' \ https://graph.facebook.com/v19.0/act_<AD_ACCOUNT_ID>/customaudiences
'use strict'; const bizSdk = require('facebook-nodejs-business-sdk'); const AdAccount = bizSdk.AdAccount; const CustomAudience = bizSdk.CustomAudience; const access_token = '<ACCESS_TOKEN>'; const app_secret = '<APP_SECRET>'; const app_id = '<APP_ID>'; const id = '<AD_ACCOUNT_ID>'; const api = bizSdk.FacebookAdsApi.init(access_token); const showDebugingInfo = true; // Setting this to true shows more debugging info. if (showDebugingInfo) { api.setDebug(true); } const logApiCallResult = (apiCallName, data) => { console.log(apiCallName); if (showDebugingInfo) { console.log('Data:' + JSON.stringify(data)); } }; let fields, params; fields = [ ]; params = { 'name' : 'My Test Website Custom Audience', 'rule' : {'inclusions':{'operator':'or','rules':[{'event_sources':[{'id':'<appID>','type':'app'}],'retention_seconds':8400,'filter':{'operator':'and','filters':[{'field':'event','operator':'eq','value':'fb_mobile_purchase'}]}}]}}, 'prefill' : '1', }; const customaudiences = (new AdAccount(id)).createCustomAudience( fields, params ); logApiCallResult('customaudiences api call complete.', customaudiences);
require __DIR__ . '/vendor/autoload.php'; use FacebookAds\Object\AdAccount; use FacebookAds\Object\CustomAudience; use FacebookAds\Api; use FacebookAds\Logger\CurlLogger; $access_token = '<ACCESS_TOKEN>'; $app_secret = '<APP_SECRET>'; $app_id = '<APP_ID>'; $id = '<AD_ACCOUNT_ID>'; $api = Api::init($app_id, $app_secret, $access_token); $api->setLogger(new CurlLogger()); $fields = array( ); $params = array( 'name' => 'My Test Website Custom Audience', 'rule' => array('inclusions' => array('operator' => 'or','rules' => array(array('event_sources' => array(array('id' => '<appID>','type' => 'app')),'retention_seconds' => 8400,'filter' => array('operator' => 'and','filters' => array(array('field' => 'event','operator' => 'eq','value' => 'fb_mobile_purchase'))))))), 'prefill' => '1', ); echo json_encode((new AdAccount($id))->createCustomAudience( $fields, $params )->exportAllData(), JSON_PRETTY_PRINT);
from facebook_business.adobjects.adaccount import AdAccount from facebook_business.adobjects.customaudience import CustomAudience from facebook_business.api import FacebookAdsApi access_token = '<ACCESS_TOKEN>' app_secret = '<APP_SECRET>' app_id = '<APP_ID>' id = '<AD_ACCOUNT_ID>' FacebookAdsApi.init(access_token=access_token) fields = [ ] params = { 'name': 'My Test Website Custom Audience', 'rule': {'inclusions':{'operator':'or','rules':[{'event_sources':[{'id':'<appID>','type':'app'}],'retention_seconds':8400,'filter':{'operator':'and','filters':[{'field':'event','operator':'eq','value':'fb_mobile_purchase'}]}}]}}, 'prefill': '1', } print AdAccount(id).create_custom_audience( fields=fields, params=params, )
import com.facebook.ads.sdk.*; import java.io.File; import java.util.Arrays; public class SAMPLE_CODE_EXAMPLE { public static void main (String args[]) throws APIException { String access_token = \"<ACCESS_TOKEN>\"; String app_secret = \"<APP_SECRET>\"; String app_id = \"<APP_ID>\"; String id = \"<AD_ACCOUNT_ID>\"; APIContext context = new APIContext(access_token).enableDebug(true); new AdAccount(id, context).createCustomAudience() .setName(\"My Test Website Custom Audience\") .setRule(\"{\\"inclusions\\":{\\"operator\\":\\"or\\",\\"rules\\":[{\\"event_sources\\":[{\\"id\\":\\"<appID>\\",\\"type\\":\\"app\\"}],\\"retention_seconds\\":8400,\\"filter\\":{\\"operator\\":\\"and\\",\\"filters\\":[{\\"field\\":\\"event\\",\\"operator\\":\\"eq\\",\\"value\\":\\"fb_mobile_purchase\\"}]}}]}}\") .setPrefill(true) .execute(); } }
require 'facebook_ads' access_token = '<ACCESS_TOKEN>' app_secret = '<APP_SECRET>' app_id = '<APP_ID>' id = '<AD_ACCOUNT_ID>' FacebookAds.configure do |config| config.access_token = access_token config.app_secret = app_secret end ad_account = FacebookAds::AdAccount.get(id) customaudiences = ad_account.customaudiences.create({ name: 'My Test Website Custom Audience', rule: {'inclusions':{'operator':'or','rules':[{'event_sources':[{'id':'<appID>','type':'app'}],'retention_seconds':8400,'filter':{'operator':'and','filters':[{'field':'event','operator':'eq','value':'fb_mobile_purchase'}]}}]}}, prefill: '1', })

성공 시 타겟 id가 반환됩니다. 다음은 가장 관련이 깊은 매개변수입니다.

이름 설명

name

유형: 문자열

필수 항목.

맞춤 타겟 이름

description

유형: 문자열

선택 사항.

맞춤 타겟 설명

rule

유형: JSON 개체

선택 사항.

타겟을 정의하는 규칙. 타겟 규칙을 참조하세요.

각 광고 계정은 모바일 앱의 맞춤 타겟에서 최대 200명까지 맞춤 타겟을 만들 수 있습니다. 다음으로 POST 요청을 보냅니다.

https://graph.facebook.com/<API_VERSION>/act_<AD_ACCOUNT_ID>/customaudiences

다음 필드를 사용하세요.

이름 설명

name

유형: 문자열

필수 항목.

맞춤 타겟 이름

retention_days

유형: 정수

필수 항목.

누군가가 이 타겟에 포함된 기간. 최솟값은 1입니다. 최댓값은 180입니다.


retention_days가 14일이고, 타겟 멤버가 13일차에 기준에 맞는 앱 이벤트를 트리거했을 경우 Facebook은 타겟에 머물 수 있는 기간을 14일 더 연장합니다. 마지막으로 트리거한 매칭 이벤트 시점부터 타겟에 N일 머문 사람을 나타냅니다.

rule

유형: JSON 개체

필수 항목.

타겟을 정의하는 규칙. 타겟 규칙 참조

타겟 규칙

맞춤 타겟에 추가할 대상을 결정하기 위해 앱 이벤트를 기반으로 규칙을 정의합니다. 규칙은 키-값 쌍이 있는 JSON 개체이고 여러 앱 이벤트를 참조할 수 있습니다. 특정 이벤트와 매개변수에 기반한 규칙과 집계를 정의할 수 있습니다. 자세한 내용은 타겟 규칙을 참조하세요. 기타 참고 자료는 다음과 같습니다.

  • 포함 및 제외 규칙 구문: event_sources에서 id를 앱 ID로 설정하고 typeapp으로 설정합니다.
  • 필터 규칙:
    • 필터로 이벤트를 지정할 경우 'event'field로 사용합니다. 앱이 전송한 앱 이벤트와 일치하는 매개변수(예: "_appVersion", "_value" 등).
    • field 속성이 "event"로 설정되면 값은 이벤트 이름으로 설정되어야 합니다. 앱 이벤트 API를 사용하여 픽셀이 보고한 앱 이벤트와 매개변수를 확인합니다.
  • 집계 함수: 모바일 앱 맞춤 타겟에 사용할 수 있는 집계 함수는 "count","sum", "avg", "min""max"입니다.

모바일 앱 맞춤 타겟 규칙의 예

표준 이벤트의 예

최근 30일 이내에 앱 ID 55064006에 대한 모든 모바일 앱 구매자:

{
    "inclusions: {
        "operator": "or",
        "rules": [    
            {
                "event_sources": [
                    {
                        "id": 55064006, 
                        "type": "app"
                    }
                ],
                "retention_seconds: 2592000,
                "filter": {
                    "operator": "and",
                    "filters": [
                        {
                            "field": "event",
                            "operator": "=",
                            "value": "fb_mobile_purchase"
                        }
                    ]
                }
            }
        ]
    }
}

매개변수가 포함된 맞춤 설정 이벤트 예시

최근 30일 이내에 앱 ID 55064006에 대한 맞춤 “timeOnPanel” 이벤트를 다시 전달한 모든 사용자:

{
    "inclusions: {
        "operator": "or",
        "rules": [    
            {
                "event_sources": [
                    {
                        "id": 55064006, 
                        "type": "app"
                    }
                ],
                "retention_seconds: 2592000,
                "filter": {
                    "operator": "and",
                    "filters": [
                        {
                            "field": "event",
                            "operator": "=",
                            "value": "timeOnPanel"
                        }
                    ]
                }
            }
        ]
    }
}

맞춤 “timeOnPanel” 이벤트를 다시 전달한 모든 사용자. 이 경우 이벤트 값이 30보다 크고 색상은 “red” 또는 “blue”이며 좋아하는 디저트는 “banana”입니다.

{
    "inclusions: {
        "operator": "or",
        "rules": [    
            {
                "event_sources": [
                    {
                        "id": 55064006, 
                        "type": "app",
                    }
                ],
                "retention_seconds: 2592000,
                "filter": {
                    "operator": "and",
                    "filters": [
                        {
                            "field": "event",
                            "operator": "=",
                            "value": "timeOnPanel",
                        },
                        {
                            "field": "_value",
                            "operator": ">",
                            "value": 30,
                        },
                        {
                            "field": "color",
                            "operator": "is_any",
                            "value": ["red", "blue"],
                        },
                        {
                            "field": "favoriteDessert",
                            "operator": "contains",
                            "value": "banana",
                        }
                    ]
                }
            }
        ]
    }
}

집계 예시

최근 30일간의 구매를 기반으로 한 상위 20%의 구매자:

{
    "inclusions: {
        "operator": "or",
        "rules": [    
            {
                "event_sources": [
                    {
                        "id": 55064006, 
                        "type": "app"
                    }
                ],
                "retention_seconds: 2592000,
                "filter": {
                    "operator": "and",
                    "filters": [
                        {
                            "field": "event",
                            "operator": "=",
                            "value": "fb_mobile_purchase"
                        }
                    ]
                }
                "aggregation": {
                    "type": "count",
                    "method": "percentile",
                    "operator": "in_range",
                    "from": 75,  
                    "to": 100,
                }
            }
        ]
    }
}

제외 예시

장바구니에 추가하였지만 구매하지 않은 사람을 포함한 예시:

{
    "inclusions: {
        "operator": "or",
        "rules": [    
            {
                "event_sources": [
                    {
                        "id": 55064006, 
                        "type": "app"
                    }
                ],
                "retention_seconds: 2592000,
                "filter": {
                    "operator": "and",
                    "filters": [
                        {
                            "field": "event",
                            "operator": "=",
                            "value": "add_to_cart"
                        }
                    ]
                }
            }
        ]
    },
    "exclusions": {
        "operator": "or",
        "rules": [    
            {
                "event_sources": [
                    {
                        "id": 55064006, 
                        "type": "app"
                    }
                ],
                "retention_seconds: 2592000,
                "filter": {
                    "operator": "and",
                    "filters": [
                        {
                            "field": "event",
                            "operator": "=",
                            "value": "fb_mobile_purchase"
                        }
                    ]
                }
            }
        ]
    }
}

앱 이벤트 API

앱에서 어떤 앱 이벤트와 매개변수를 Facebook에 보고했는지 쿼리합니다. 맞춤 타겟 생성에 이러한 이벤트와 매개변수를 직접 사용할 수 있습니다. 관리자, 개발자 또는 광고주 역할로 app_id에 연결된 액세스 토큰이 필요합니다.

다음과 같이 GET 요청을 보냅니다.

https://graph.facebook.com/<API_VERSION>/<APP_ID>/app_event_types

응답은 다음과 같은 필드를 가진 JSON 사전의 data 배열을 포함한 JSON입니다.

이름 설명

event_name

유형: 문자열

규칙에서 사용하는 앱 이벤트 유형

display_name

유형: 문자열

사람이 읽을 수 있는 이벤트 유형의 이름

description

유형: 문자열

표준 이벤트에 대한 자세한 설명

parameters

유형: 배열

{"parameter_name": "fb_currency","display_name": "Currency","description": "Currency for event"} 이벤트 매개변수를 설명하는 JSON 사전 배열


parameter_name: 문자열, 규칙에서 사용하는 앱 매개변수 유형


display_name: 문자열, 사람이 읽을 수 있는 이벤트 유형 이름


description: 문자열, 표준 매개변수인 경우 매개변수에 대한 자세한 설명


타겟 관리