建立自訂應用程式促銷活動Create a custom app promotion campaign

除了為將在 Windows 應用程式中執行的 應用程式建立 ad 活動 之外,您也可以使用其他通道來推廣您的應用程式。In addition to creating an ad campaign for your app that will run in Windows apps, you can also promote your app using other channels. 例如,您可以使用第三方 app 行銷提供者促銷您的 app,或可以在社交媒體網站上張貼 app 的連結。For example, you can promote your app using a third-party app marketing provider, or you might post links to your app on social media sites. 這些活動稱為自訂行銷活動These activities are called custom campaigns.

如果為您的應用程式執行自訂行銷活動,可以追蹤每個行銷活動相關的效能,方法是為每個自訂行銷活動建立不同的 URL,其中每個 URL 包含不同的行銷活動識別碼If you run custom campaigns for your app, you can track the relative performance of each campaign by creating a different URL for each custom campaign, where each URL contains a different campaign ID. 當執行 Windows 10 的客戶按一下包含活動識別碼的 URL 時,Microsoft 會將點擊與對應的自訂活動建立關聯,並讓您在 合作夥伴中心中提供這項資料。When a customer running Windows 10 clicks a URL that contains a campaign ID, Microsoft associates the click with the corresponding custom campaign and makes this data available to you in Partner Center.

重要

這項資料只能追蹤 Windows 10 客戶。This data is only tracked for customers on Windows 10. 使用其他作業系統的客戶仍可以透過連結連到您的 app 清單,但不包含有關這些客戶的活動相關資料。Customers using other operating systems can still follow the link to your app's listing, but data about those customers' activities will not be included.

與自訂行銷活動關聯的資料類型主要有兩個:應用程式 Store 清單的 「頁面檢視次數」,以及 「轉換」There are two main types of data associated with custom campaigns: page views for your app's Store listing, and conversions. 「轉換」即是指客戶從包含自訂行銷活動識別碼的 URL,檢視您應用程式的市集清單頁面,並且取得您的應用程式。A conversion is an app acquisition that results from a customer viewing your app's Store listing page from a URL that includes a custom campaign ID. 如需轉換的詳細資訊,請參閱本主題中的了解應用程式下載數如何符合轉換的資格For more details about conversions, see Understanding how app acquisitions qualify as conversions in this topic.

您可以使用下列方式擷取 App 的自訂行銷活動成效資料:You can retrieve custom campaign performance data for your app in the following ways:

  • 您可以從應用程式網頁檢視中查看應用程式或附加元件的網頁檢視和轉換的相關資料,以及 [收購報表] 中的「活動識別碼」和「行銷活動總計」圖表的轉換。You can view data about page views and conversions for your app or add-on from the App page views and conversions by campaign ID and Total campaign conversions charts in the Acquisitions report.
  • 如果您的 App 是通用 Windows 平台 (UWP) app,您可以使用 Windows SDK 中的 API,以程式設計方式擷取導致轉換的自訂行銷活動識別碼。If your app is a Universal Windows Platform (UWP) app, you can use APIs in the Windows SDK to programmatically retrieve the custom campaign ID that resulted in a conversion.

自訂行銷活動案例的範例Example custom campaign scenario

請考慮已經完成建置新遊戲並想要對為其現有的遊戲玩家促銷的遊戲開發人員。Consider a game developer who has finished building a new game and would like to promote it to players of her existing games. 她在她的 Facebook 頁面上張貼新遊戲發行的通知,包含遊戲的 Store 清單。She posts the announcement of the new game release on her Facebook page, including a link to the game's Store listing. 她的許多玩家也在 Twitter 上關注她,所以她也推文公告遊戲的 Store 清單。Many of her players also follow her on Twitter, so she also tweets an announcement with the link to the game's Store listing.

為了追蹤每個這些促銷活動管道的成功度,開發人員會為遊戲的 Store 清單建立兩個 URL 變數:To track the success of each of these promotion channels, the developer creates two variants of the URL to the game's Store listing:

  • 她將張貼到其 Facebook 頁面的 URL 包含自訂的活動識別碼 my-facebook-campaignThe URL she will post to her Facebook page includes the custom campaign ID my-facebook-campaign

  • 她將張貼到 Twitter 的 URL 包含自訂的活動識別碼 my-twitter-campaignThe URL she will post to Twitter includes the custom campaign ID my-twitter-campaign

當她的 Facebook 和 Twitter 追隨者按一下 URL 時,Microsoft 會追蹤與對應的自訂行銷活動關聯的每個點按。As her Facebook and Twitter followers click the URLs, Microsoft tracks each click and associates it with the corresponding custom campaign. 後續符合資格的遊戲下載數和任何附加元件購買會與自訂行銷活動產生關聯,並且回報為轉換。Subsequent qualifying acquisitions of the game and any add-on purchases are associated with the custom campaign and reported as conversions.

了解下載數如何符合轉換的資格Understanding how acquisitions qualify as conversions

自訂行銷活動 「轉換」 即是指客戶透過按下您藉由自訂行銷活動促銷的 URL,並且取得您的應用程式。A custom campaign conversion is an acquisition that results from a customer clicking a URL that is promoted via a custom campaign. 有幾個不同的案例,可讓您在「收購」報表中以「活動識別碼」和「行銷活動」轉換圖表進行轉換,以及以程式設計方式取得活動識別碼以進行轉換。There are different scenarios for qualifying as a conversion for the App page views and conversions by campaign ID and Total campaign conversions charts in the Acquisitions report and for qualifying as a conversion for programmatically retrieving the campaign ID.

在收購報告中限定轉換Qualifying conversions in the Acquisitions report

對於開發人員中心儀表板上的下載數報告應用程式頁面檢視數與轉換數 (依行銷活動識別碼)行銷活動轉換總計圖表,下列案例符合轉換的資格:The following scenarios qualify as a conversion for the App page views and conversions by campaign ID and Total campaign conversions charts in the Acquisitions report:

  • 客戶 (具備或不具備已辨識的 Microsoft 帳戶) 按一下包含自訂行銷活動識別碼的 App URL,並重新導向至 App 的市集清單頁面。A customer with or without a recognized Microsoft account clicks an app URL that contains a custom campaign ID and is redirected to the Store listing for the app. 然後,同一個客戶在首次按下包含自訂行銷活動識別碼的 Microsoft Store URL 的 24 小時內取得應用程式。Then, that same customer acquires the app within 24 hours after they first clicked the Microsoft Store URL with the custom campaign ID.

  • 若客戶取得應用程式的裝置不同於他們用來按下包含自訂行銷活動識別碼之 URL 的裝置,只有在當該客戶登入時與按一下 URL 時使用相同的 Microsoft 帳戶,才會計算轉換。If the customer acquires the app on a different device than the one on which they clicked the URL with the custom campaign ID, the conversion will only be counted if the customer is signed in with the same Microsoft account as when they clicked the URL.

注意

針對已計入為透過自訂行銷活動轉換的 App 下載數,該客戶在該 App 中任何附加元件的購買,也都會計為透過同一個自訂行銷活動進行的轉換。For app acquisitions that are counted as conversions for a custom campaign, any add-on purchases in that app are also counted as conversions for the same custom campaign.

以程式設計方式擷取行銷活動識別碼時的合格轉換Qualifying conversions when programmatically retrieving the campaign ID

若要在以程式設計方式擷取與 App 相關聯的行銷活動識別碼時符合轉換的資格,必須符合下列條件:To qualify as a conversion when programmatically retrieving the campaign ID associated with the app, the following conditions must be met:

  • 在執行 Windows 10 1607 版或更新版本的裝置上:客戶 (不論是否登入到已辨識的 Microsoft 帳戶) 按一下包含自訂行銷活動識別碼的 URL,並已重新導向至 App 的市集清單頁面。On a device running Windows 10, version 1607, or later: A customer (whether signed in to a recognized Microsoft account or not) clicks a URL that contains a custom campaign ID and is redirected to the Store listing page for the app. 客戶因為按一下 URL 而檢視市集清單時取得 App。The customer acquires the app while viewing the Store listing as a result of clicking the URL.

  • 在執行 Windows 10 1511 版或更早版本的裝置上:客戶 (必須使用已辨識的 Microsoft 帳戶登入) 按一下包含自訂行銷活動識別碼的 URL,並已重新導向至該 App 的市集清單頁面。On a device running Windows 10, version 1511, or earlier: A customer (who must be signed in with a recognized Microsoft account) clicks a URL that contains a custom campaign ID and is redirected to the Store listing page for the app. 客戶因為按一下 URL 而檢視市集清單時取得 App。The customer acquires the app while viewing the Store listing as a result of clicking the URL. 在這些版本的 Windows 10 中,使用者必須使用已辨識的 Microsoft 帳戶登入,才能在以程式設計方式擷取行銷活動識別碼時讓下載符合轉換資格。On these versions of Windows 10, the user must be signed in with a recognized Microsoft account in order for the acquisition to qualify as a conversion when programmatically retrieving the campaign ID.

注意

若客戶離開市集清單頁面,但在 24 小時之內返回該頁面 (在同一部裝置上,或在使用相同的 Microsoft 帳戶登入時,使用不同的裝置),並且取得 App,這符合下載數報告應用程式頁面檢視數與轉換數 (依行銷活動識別碼)行銷活動轉換總計圖表的轉換資格。If the customer leaves the Store listing page, but returns to the page with 24 hours (either on the same device, or on a different device when signed in with the same a Microsoft account) and acquires the app, this will qualify as a conversion in the App page views and conversions by campaign ID and Total campaign conversions charts in the Acquisitions report. 但是,如果您以程式設計方式取得活動識別碼,這 將不會 限定為轉換。However, this will not qualify as a conversion if you programmatically retrieve the campaign ID.

內嵌自訂行銷活動識別碼到您應用程式的 Microsoft Store 頁面 URLEmbed a custom campaign ID to your app's Microsoft Store page URL

若要使用自訂行銷活動識別碼為您的應用程式建立 Microsoft Store 頁面 URL:To create a Microsoft Store page URL for your app with a custom campaign ID:

  1. 為您的自訂行銷活動建立識別碼字串。Create an ID string for your custom campaign. 此字串可以包含最多 100 個字元,但建議您定義容易識別的簡短行銷活動識別碼。This string can contain up to 100 characters, although we recommend that you define short campaign IDs that are easily identifiable.

注意

當其他開發人員檢視自己的 App 下載數報告時,可能會看到此行銷活動識別碼字串。The campaign ID string may be visible to other developers when they view the Acquisitions report for their apps. 當客戶按下您的自訂行銷活動識別碼進入到市集之中,並在同一個工作階段中購買了另一位開發人員的應用程式,因此將該轉換歸至您的行銷活動識別碼時,可能會發生這種狀況。This can occur when a customer clicks your custom campaign ID to enter the Store and purchases another developer’s app within the same session, thus attributing that conversion to your campaign ID. 該開發人員會看到他們自己的應用程式當中,有多少轉換是來自於初次按下您的行銷活動識別碼,包括行銷活動識別碼名稱,但是他們不會看到有多少使用者是透過您的行銷活動識別碼而購買到您應用程式 (或任何其他開發人員的應用程式) 的相關資料。That developer will see how many conversions of their own app resulted from an initial click on your campaign ID, including the name of the campaign ID, but they will not see any data about how many users purchased your own apps (or apps from any other developers) after clicking your campaign ID.

  1. 以 HTML 或通訊協定格式取得應用程式的 Store 清單。Get the link for your app's Store listing in HTML or protocol format.

    • 若要任何作業系統的客戶使用瀏覽器瀏覽到您應用程式的 web 架構市集清單,請使用 HTML URL。Use the HTML URL if you want customers to navigate to your app's web-based Store listing in a browser on any operating system. 在 Windows 裝置上,市集應用程式也將啟動並顯示您的應用程式清單。On Windows devices, the Store app will also launch and display your app's listing. 此 URL 的格式為 https://www.microsoft.com/store/apps/*your app ID*This URL has the format https://www.microsoft.com/store/apps/*your app ID*. 例如,Skype 的 HTML URL 為 https://www.microsoft.com/store/apps/9wzdncrfj364For example, the HTML URL for Skype is https://www.microsoft.com/store/apps/9wzdncrfj364. 您可以在 App 身分識別頁面上找到這個 URL。You can find this URL on your App identity page.

    • 若您想要從已安裝 UWP app 的裝置或電腦上執行的其他 Windows 應用程式進行促銷,或者您知道客戶使用支援 Microsoft Store 的裝置時,請使用通訊協定格式。Use the protocol format if you are promoting your app from within other Windows apps that are running on a device or computer with the UWP app installed, or when you know that your customers are on a device which supports the Microsoft Store. 此連結會直接移至您的應用程式市集清單,而不會開啟瀏覽器。This link will go directly to your app's Store listing without opening a browser. 此 URL 的格式為 ms-windows-store://pdp/?PRODUCTID=*your app id*This URL has the format ms-windows-store://pdp/?PRODUCTID=*your app id*. 例如,Skype 的通訊協定 URL 為 ms-windows-store://pdp/?PRODUCTID=9wzdncrfj364For example, the protocol URL for Skype is ms-windows-store://pdp/?PRODUCTID=9wzdncrfj364.

  2. 附加以下字串到您的 app 的 URL 的結尾:Append the following string to the end of the URL for your app:

    • 若為 HTML 格式 URL,請附加 ?cid=*my custom campaign ID*For an HTML format URL, append ?cid=*my custom campaign ID*. 例如,如果 Skype 導入了具有「 自訂 _ 活動」值的活動識別碼,則新的 URL (包括活動識別碼)將會是: https://www.microsoft.com/store/apps/skype/9wzdncrfj364?cid=custom\_campaignFor example, if Skype introduces a campaign ID with the value custom_campaign, the new URL including the campaign ID would be: https://www.microsoft.com/store/apps/skype/9wzdncrfj364?cid=custom\_campaign.

    • 若為通訊協定格式 URL,請附加 &cid=*my custom campaign ID*For a protocol format URL, append &cid=*my custom campaign ID*. 例如,如果 Skype 導入了具有「 自訂 _ 活動」值的活動識別碼,則新的通訊協定 URL (包括活動識別碼)將會是: ms-windows-store://pdp/?PRODUCTID=9wzdncrfj364&cid=custom\_campaignFor example, if Skype introduces a campaign ID with the value custom_campaign, the new protocol URL including the campaign ID would be: ms-windows-store://pdp/?PRODUCTID=9wzdncrfj364&cid=custom\_campaign.

以程式設計方式擷取 app 的自訂行銷活動識別碼Programmatically retrieve the custom campaign ID for an app

如果您的 App 是 UWP app,您可以使用 Windows SDK 中的 API 以程式設計方式擷取與 App 取得相關聯的自訂行銷活動識別碼。If your app is a UWP app, you can programmatically retrieve the custom campaign ID associated with an app's acquisition by using APIs in the Windows SDK. 這些 API 使許多分析和創造營收案例得以實現。These APIs make many analytics and monetization scenarios possible. 例如,您可以了解目前的使用者在透過您的 Facebook 行銷活動發現您的 app 後是否取得它,然後據此自訂 app 經驗。For example, you can find out if the current user acquired your app after discovering it through your Facebook campaign, and then customize the app experience accordingly. 或者,如果您使用第三方 App 行銷提供者,您可以將資料傳回至提供者。Alternatively, if you are using a third-party app marketing provider, you can send data back to the provider.

只有在客戶按一下包含行銷活動識別碼的 URL,檢視應用程式的 Microsoft Store 頁面,接著取得您的應用程式但未離開 Store 清單頁面時,這些 API 才會傳回行銷活動識別碼字串。These APIs will return a campaign ID string only if the customer clicked your URL with the embedded campaign ID, viewed the Microsoft Store page for your app, and then acquires your app without leaving the Store listing page. 如果使用者離開頁面,但稍後又返回並取得 App,那麼使用這些 API 時就不符合轉換資格If the user leaves the page and then later returns and acquires the app, this will not qualify as a conversion when using these APIs.

您要使用的 API 會有所不同,取決於 App 針對的 Windows 10 目標版本:There are different APIs for you to use depending on the version of Windows 10 that your app targets:

  • Windows 10 1607 版或更新版本︰使用 Windows.Services.Store 命名空間中的 StoreContextWindows 10, version 1607, or later: Use the StoreContext class in the Windows.Services.Store namespace. 使用此 API 時,您可以擷取任何合格下載的自訂行銷活動識別碼,不論使用者是否使用已辨識的 Microsoft 帳戶登入。When using this API, you can retrieve custom campaign IDs for any qualified acquisitions, whether or not the user is signed in with a recognized Microsoft account.

  • Windows 10 1511 版或更早版本︰使用 Windows.ApplicationModel.Store命名空間中的 CurrentAppWindows 10, version 1511, or earlier: Use the CurrentApp class in the Windows.ApplicationModel.Store namespace. 使用此 API 時,您只能在使用者使用已辨識的 Microsoft 帳戶登入情況下擷取合格下載的自訂行銷活動識別碼。When using this API, you can only retrieve custom campaign IDs for qualified acquisitions where the user is signed in with a recognized Microsoft account.

注意

雖然 Windows.ApplicationModel.Store 命名空間適用於所有 Windows 10 版本,如果您的 App 以 Windows 10 1607 版或更新版本為目標,還是建議您使用 Windows.Services.Store 命名空間中的 API。Although the Windows.ApplicationModel.Store namespace is available in all versions of Windows 10, we recommend that you use the APIs in the Windows.Services.Store namespace if your app targets Windows 10, version 1607, or later. 如需有關這些命名空間之間差異的詳細資訊,請參閱 App 內購買和試用版For more information about the differences between these namespaces, see In-app purchases and trials. 下列程式碼範例說明如何建構程式碼,在相同專案中使用這兩個 API。The following code example shows how to structure your code to use both APIs in the same project.

程式碼範例Code example

下列程式碼範例說明如何擷取自訂行銷活動識別碼。The following code example shows how to retrieve the custom campaign ID. 這個範例透過版本調適型程式碼使用 Windows.Services.StoreWindows.ApplicationModel.Store 命名空間中的這兩組 API。This example uses both sets of APIs in the Windows.Services.Store and Windows.ApplicationModel.Store namespaces by using version adaptive code. 您的程式碼可以依照此程序,在任何版本的 Windows 10 上執行。By following this process, your code can run on any version of Windows 10. 若要使用此代碼,專案的目標作業系統版本必須是 Windows 10 Anniversary Edition (10.0 版;組建 14394) 或更新版本,雖然最小作業系統版本可以是較早的版本。To use this code, the target OS version of your project must be Windows 10 Anniversary Edition (10.0; Build 14394) or later, although the minimum OS version can be an earlier version.

// This example assumes the code file has using statements for
// System.Linq, System.Threading.Tasks, Windows.Data.Json,
// and Windows.Services.Store.
public async Task<string> GetCampaignId()
{
    // Use APIs in the Windows.Services.Store namespace if they are available
    // (the app is running on a device with Windows 10, version 1607, or later).
    if (Windows.Foundation.Metadata.ApiInformation.IsTypePresent(
         "Windows.Services.Store.StoreContext"))
    {
        StoreContext context = StoreContext.GetDefault();

        // Try to get the campaign ID for users with a recognized Microsoft account.
        StoreProductResult result = await context.GetStoreProductForCurrentAppAsync();
        if (result.Product != null)
        {
            StoreSku sku = result.Product.Skus.FirstOrDefault(s => s.IsInUserCollection);

            if (sku != null)
            {
                return sku.CollectionData.CampaignId;
            }
        }

        // Try to get the campaign ID from the license data for users without a
        // recognized Microsoft account.
        StoreAppLicense license = await context.GetAppLicenseAsync();
        JsonObject json = JsonObject.Parse(license.ExtendedJsonData);
        if (json.ContainsKey("customPolicyField1"))
        {
            return json["customPolicyField1"].GetString();
        }

        // No campaign ID was found.
        return String.Empty;
    }
    // Fall back to using APIs in the Windows.ApplicationModel.Store namespace instead
    // (the app is running on a device with Windows 10, version 1577, or earlier).
    else
    {
#if DEBUG
        return await Windows.ApplicationModel.Store.CurrentAppSimulator.GetAppPurchaseCampaignIdAsync();
#else
        return await Windows.ApplicationModel.Store.CurrentApp.GetAppPurchaseCampaignIdAsync() ;
#endif
    }
}

此程式碼會執行以下動作:This code does the following:

  1. 首先,檢查 Windows.Services.Store 命名空間中的 StoreContext 類別是否適用於目前的裝置 (這表示裝置正在執行 Windows 10 1607 版或更新版本)。First, it checks to see if the StoreContext class in the Windows.Services.Store namespace is available on the current device (this means the device is running Windows 10, version 1607, or later). 如果是這樣,請繼續使用此類別。If so, the code proceeds to use this class.

  2. 接下來,在目前的使用者擁有已辨識的 Microsoft 帳戶情況下嘗試取得自訂行銷活動識別碼。Next, it attempts to get the custom campaign ID for the case where the current user has a recognized Microsoft account. 為此,程式碼會取得表示目前 App SKU 的 StoreSku 物件,然後存取 CampaignId 屬性以擷取行銷活動識別碼 (如果有的話)。To do this, the code gets a StoreSku object that represents the current app SKU, and then it accesses the CampaignId property to retrieve the campaign ID, if one is available.

  3. 程式碼接著在目前使用者沒有已辨識的 Microsoft 帳戶情況下嘗試擷取行銷活動識別碼。The code then attempts to retrieve the campaign ID for the case where the current user does not have a recognized Microsoft account. 在此情況下,行銷活動識別碼是內嵌在 App 授權中。In this case, the campaign ID is embedded in the app license. 程式碼會使用 GetAppLicenseAsync 方法擷取授權,然後對名稱為 customPolicyField1 的索引鍵值進行授權的 JSON 內容剖析。The code retrieves the license by using the GetAppLicenseAsync method and then parses the JSON contents of the license for the value of a key named customPolicyField1. 這個值包含行銷活動識別碼。This value contains the campaign ID.

  4. 如果 Windows.Services.Store 命名空間中的 StoreContext 類別無法使用,程式碼就會回復為使用 Windows.ApplicationModel.Store 命名空間中的 GetAppPurchaseCampaignIdAsync 方法,以擷取自訂行銷活動識別碼 (這個命名空間適用於所有 Windows 10 版本,包括 1511 版和更早版本)。If the StoreContext class in the Windows.Services.Store namespace is not available, the code then falls back to using the GetAppPurchaseCampaignIdAsync method in the Windows.ApplicationModel.Store namespace to retrieve the custom campaign ID (this namespace is available in all versions of Windows 10, including version 1511 and earlier). 請注意,使用此方法時,您只能在使用者擁有已辨識的 Microsoft 帳戶情況下擷取合格下載的自訂行銷活動識別碼。Note that when using this method, you can only retrieve custom campaign IDs for qualified acquisitions where the user has a recognized Microsoft account.

在 Proxy 檔案中為 Windows.ApplicationModel.Store 命名空間指定行銷活動識別碼Specify the campaign ID in the proxy file for the Windows.ApplicationModel.Store namespace

Windows.ApplicationModel.Store 命名空間包含 CurrentAppSimulator,這是為了在提交 App 至市集之前測試程式碼而模擬市集作業的特殊類別。The Windows.ApplicationModel.Store namespace includes CurrentAppSimulator, a special class that simulates Store operations for testing your code before you submit your app to the Store. 此類別會從名為 Windows.StoreProxy.xml 的本機檔案擷取資料。This class retrieves data from a local file named Windows.StoreProxy.xml file. 上一個程式碼範例說明如何在專案的偵錯及非偵錯程式碼中同時使用 CurrentAppCurrentAppSimulatorThe previous code example shows how to include use both CurrentApp and CurrentAppSimulator in debug and non-debug code in your project. 若要在偵錯環境中測試此程式碼,請將 AppPurchaseCampaignId 項目新增至開發電腦上的 WindowsStoreProxy.xml 檔案,如下列範例所示。To test this code in a debug environment, add an AppPurchaseCampaignId element to the WindowsStoreProxy.xml file on your development computer, as shown in the following example. 執行 app 時,GetAppPurchaseCampaignIdAsync 方法永遠傳回這個值。When you run the app, the GetAppPurchaseCampaignIdAsync method will always return this value.

<CurrentApp>
    ...
    <AppPurchaseCampaignId>your custom campaign ID</AppPurchaseCampaignId>
</CurrentApp>

Windows.Services.Store 命名空間不提供您可在測試期間用來模擬授權資訊的類別。The Windows.Services.Store namespace does not provide a class that you can use to simulate license info during testing. 您必須改為將 App 發行至市集,並將該 App 下載到您的開發裝置,才能使用它的授權進行測試。Instead, you must publish an app to the Store and download that app to your development device to use its license for testing. 如需詳細資訊,請參閱 App 內購買和試用版For more information, see In-app purchases and trials.

測試您的自訂行銷活動Test your custom campaign

促銷自訂行銷活動 URL 之前,建議您執行下列動作來測試自訂行銷活動:Before you promote a custom campaign URL, we recommend that you test your custom campaign by doing the following:

  1. 在您要用於測試的裝置上登入 Microsoft 帳戶。Sign in to a Microsoft account on the device you are using for testing.

  2. 按一下您的自訂行銷活動 URL。Click your custom campaign URL. 請確定您被引導至您的應用程式頁面,然後關閉 UWP app 或瀏覽器頁面。Make sure you are taken to your app page, and then close the UWP app or the browser page.

  3. 按一下 URL 數次,在每次瀏覽到您的應用程式頁面後關閉 UWP app 或瀏覽器頁面。Click the URL several more times, closing the UWP app or the browser page after each visit to your app's page. 在造訪您的應用程式 頁面時, 取得您的應用程式以產生轉換。During one of the visits to your app's page, acquire your app to generate a conversion. 計算您點選 URL 的總次數。Count the total number of times you clicked the URL.

  4. 確認預期的網頁檢視和轉換是否出現在應用程式網頁檢視中,以及在 [採購] 報表中依活動識別碼和行銷活動轉換圖的轉換,並測試您的應用程式程式碼,以確認它是否可以使用上述 api 來成功抓取活動識別碼。Confirm whether the expected page views and conversions appear in the App page views and conversions by campaign ID and Total campaign conversions charts in the Acquisitions report, and test your app's code to confirm whether it can successfully retrieve the campaign ID using the APIs described above.