Skip to content

Ad attribution

PurrCRM can tell your ad networks what people do in your app after an ad brings them in, such as a purchase. It can also keep Apple’s install postbacks, and record which Apple Ads campaign brought someone in.

Only owners and admins can set up ad networks.

An event is only sent to an ad network when the person allowed tracking. Your developers add two props to the events you want sent:

PropValue
ad_trackingallowed, when the person allows tracking. On iOS, that means they said yes to App Tracking Transparency.
advertising_idThe device’s advertising ID. Google Ads needs it: events without one are not sent to Google.

The contact’s email, phone, ID and advertising ID are sent hashed, never as they are.

  1. Go to Settings › your app › Developers › Ad networks.

  2. Press Set up beside the network.

  3. Fill in its details:

    NetworkWhat to fill in
    MetaThe Dataset ID from Meta’s Events Manager, and an Access token: in the dataset’s settings, under Conversions API, generate one.
    Google AdsThe Link ID, in Google Ads under Linked accounts › Third-party app analytics, and your Google Ads API Developer token.
    TikTokThe TikTok App ID and an Access token, both from TikTok’s Events Manager.
  4. Under Events to send, choose which of your events go, and what each is called there. For example, Your event order_paid as The network’s event Purchase. Press Add an event for each one.

  5. Press Save.

To try it first, Meta and TikTok have a Test event code. While it is set, what PurrCRM sends shows only in the network’s test events tool. Remove the code when you’re happy.

Each network then shows how many events were sent, and when the last one went. If the network refuses them, it says Failing, with the reason.

To pause a network, press Edit, untick On, and press Save. To stop for good, press Remove: nothing more is sent, and its token is deleted.

Apple covers two things: SKAdNetwork install postbacks, and Apple Ads attribution.

  1. Go to Settings › your app › Developers › Ad networks.
  2. Press Set up beside Apple (SKAdNetwork and Apple Ads).
  3. In App Store ID, enter the digits in your app’s App Store address.
  4. If your app isn’t sold in the United States, enter a country it is sold in under App Store country, such as gb.
  5. Press Save.

Postbacks are only kept once PurrCRM knows the app is yours. It checks that the website on your App Store page is on a sending domain you verified for this app.

Until then, Apple shows Not proven, and says what is missing. To fix it:

  1. Make sure your App Store page names your website, in App Store Connect.
  2. Verify a sending domain on that website’s domain (An email from your own domain).
  3. Go back to Ad networks, press Edit beside Apple, and press Save again.

Once Apple is set up, the SKAdNetwork postbacks card appears.

  1. Copy the Report endpoint.
  2. Give it to your developers. In your app’s Info.plist, they set NSAdvertisingAttributionReportEndpoint to that address.

Apple then sends copies of your app’s install postbacks there. They show in the card, with the ad network, campaign and value. Postbacks name no person: they are about campaigns.

A postback that Apple didn’t sign is dropped, and counted on the Apple row.

When someone installs your app from an Apple Ads campaign, your developers can send PurrCRM the attribution token their app gets from Apple, from your backend (Send a person’s Apple Ads attribution token). It must be sent within a day of the install. PurrCRM asks Apple which campaign it was, and records the event Brought in by Apple Ads on the contact.

You can start a workflow with it: choose the trigger an Apple Ads campaign brings them in.