attribution-reporting-api icon indicating copy to clipboard operation
attribution-reporting-api copied to clipboard

Question about multiple attribution source support

Open gyuchaog opened this issue 2 years ago • 2 comments

Hi, I am looking for solutions to support multiple attribution sources at the event level. For example, we have a.com and b.com both can support the measurement for click/impression/conversions. When an ad gets served, we'd like both a.com and b.com both get registered and get their own report. By reading your doc, I got the following understanding and questions. Please let me know if there is any issue.

1. Impression Impression should be an event source. I suppose we can have 2 1*1 pixels to register both attribution sources. Please correct me if I am wrong. Here is the example:

<img src="https://advertiser.example/pixel" 
     attributionsrc="https://a.com/attribution_source1?param1=value1" />
<img src="https://advertiser.example/pixel" 
     attributionsrc="https://b.com/attribution_source2?param2=value2" />

Beyond this, any other solutions? eg. we send these 2 pings("https://a.com/attribution_source1?param1=value1", "https://b.com/attribution_source2?param2=value2") by ourselves. Will it work? Or can we have the 2 urls inside the same img tag?

2. click Click is a navigation source. What I learnt from the doc is we have to build the redirect chain to combine the registration. eg:

<a href="https://advertiser.example/landing"
   attributionsrc="https://a.com/attribution_source1?param1=value1">
   click me
</a>

and "https://a.com/attribution_source1?param1=value1" should redirect to "https://b.com/attribution_source2?param2=value2". Both responses should have "ttribution-Reporting-Register-Source" header. Is it correct? Since the second url didn't use attributionsrc property. Also, is there a way to register 2 attributionsrc without relying on the first url being redirected into the second one like the impression one?

3. conversion I felt publishers need to register 2 conversions like this:

<img src="https://ad-tech.example/conversionpixel" 
     attributionsrc=”https://a.com/attribution_trigger1?purchase=13” />
<img src="https://ad-tech.example/conversionpixel" 
     attributionsrc=”https://b.com/attribution_trigger2?purchase=13” />

Is it correct? Does the redirection chain work here? eg. ”https://a.com/attribution_trigger1?purchase=13” redirects to ”https://b.com/attribution_trigger2?purchase=13” and both has the "Attribution-Reporting-Register-Event-Trigger" header?

gyuchaog avatar Apr 21 '22 20:04 gyuchaog

Impression should be an event source. I suppose we can have 2 1*1 pixels to register both attribution sources. Please correct me if I am wrong. Here is the example: ... Beyond this, any other solutions? eg. we send these 2 pings("https://a.com/attribution_source1?param1=value1", "https://b.com/attribution_source2?param2=value2") by ourselves. Will it work? Or can we have the 2 urls inside the same img tag?

Yes, you can provide two separate tags for two different reports. You cannot provide 2 urls inside the same tag. Although I would be interested to hear if there is a use-case where this makes the API meaningfully easier to use.

Otherwise you can:

  • Perform a redirect to the other reporter from the ifrst img tag attributionsrc
  • If you have javascript access, you can invoke window.attributionReporting.registerSource() with each of the URLs.
  1. click Click is a navigation source. What I learnt from the doc is we have to build the redirect chain to combine the registration. eg: ... and "https://a.com/attribution_source1?param1=value1" should redirect to "https://b.com/attribution_source2?param2=value2". Both responses should have "ttribution-Reporting-Register-Source" header. Is it correct? Since the second url didn't use attributionsrc property. Also, is there a way to register 2 attributionsrc without relying on the first url being redirected into the second one like the impression one?

Yes that is correct. Currently it is not possible to register 2 attributionsrc without redirects for a click. Again I would be interested to hear if this is a use-case we should consider. Fundamentally, I don't see an issue with having two separate parallel pings instead of a redirect chain (this would help prevent outages for parties which are further along in the chain).

  1. conversion I felt publishers need to register 2 conversions like this: ... Is it correct? Does the redirection chain work here? eg. ”https://a.com/attribution_trigger1?purchase=13” redirects to ”https://b.com/attribution_trigger2?purchase=13” and both has the "Attribution-Reporting-Register-Event-Trigger" header?

I will note that the attributionsrc is optional on the conversion side (see the paragraph starting "As a stop-gap" here). We allow you to register triggers directly on existing "src" requests without modifying the element.

Yes, redirect chain will work in this case (regardless of whether attributionsrc is used).

johnivdel avatar Apr 26 '22 16:04 johnivdel

Thanks for your response. Our products do have 2 measurement systems(Let's say a.com and b.com) and they are working in parallel. We need to register click/impression/conversion for both of them. And our customers will get reports from both systems. Trying to see the suggestion from the chrome side for our implementation.

Impressions: From all those 3 suggestions, is there a preference from the Chrome side?

Click: Click is a problem for us. a.com & b.com both have their own redirect chain for clicks. Assume it's hard to ask a.com & b.com to change the redirect chain for Chrome registration. We have a hard time combining those 2 chains into one and get all of them registered. Will it be possible to support the parallel pings instead? Or is there a better suggestion?

Conversion: We are thinking about using the redirect chain. Without using the conversionsrc, I assume the example(https://a.com/attribution_trigger1?purchase=13 redirects to https://b.com/attribution_trigger2?purchase=13 and both has the "Attribution-Reporting-Register-Event-Trigger" header) can register the trigger for both a.com and b.com right?

gyuchaog avatar Apr 27 '22 03:04 gyuchaog