Skip to content

Commit

Permalink
Add context.library.name to Segment (ampproject#5467)
Browse files Browse the repository at this point in the history
  • Loading branch information
yields authored and mkhatib committed Oct 11, 2016
1 parent dd3ec4e commit 247b83e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
6 changes: 3 additions & 3 deletions extensions/amp-analytics/0.1/test/vendor-requests.json
Expand Up @@ -128,9 +128,9 @@
},
"segment": {
"host": "https://api.segment.io/v1/pixel",
"base": "?writeKey=$writeKey&anonymousId=_client_id_&context.locale=_browser_language_&context.page.path=_canonical_path_&context.page.url=_canonical_url_&context.page.referrer=_document_referrer_&context.page.title=_title_&context.screen.width=_screen_width_&context.screen.height=_screen_height_",
"page": "https://api.segment.io/v1/pixel/page?writeKey=$writeKey&anonymousId=_client_id_&context.locale=_browser_language_&context.page.path=_canonical_path_&context.page.url=_canonical_url_&context.page.referrer=_document_referrer_&context.page.title=_title_&context.screen.width=_screen_width_&context.screen.height=_screen_height_&name=$name",
"track": "https://api.segment.io/v1/pixel/track?writeKey=$writeKey&anonymousId=_client_id_&context.locale=_browser_language_&context.page.path=_canonical_path_&context.page.url=_canonical_url_&context.page.referrer=_document_referrer_&context.page.title=_title_&context.screen.width=_screen_width_&context.screen.height=_screen_height_&event=$event"
"base": "?writeKey=$writeKey&context.library.name=amp&anonymousId=_client_id_&context.locale=_browser_language_&context.page.path=_canonical_path_&context.page.url=_canonical_url_&context.page.referrer=_document_referrer_&context.page.title=_title_&context.screen.width=_screen_width_&context.screen.height=_screen_height_",
"page": "https://api.segment.io/v1/pixel/page?writeKey=$writeKey&context.library.name=amp&anonymousId=_client_id_&context.locale=_browser_language_&context.page.path=_canonical_path_&context.page.url=_canonical_url_&context.page.referrer=_document_referrer_&context.page.title=_title_&context.screen.width=_screen_width_&context.screen.height=_screen_height_&name=$name",
"track": "https://api.segment.io/v1/pixel/track?writeKey=$writeKey&context.library.name=amp&anonymousId=_client_id_&context.locale=_browser_language_&context.page.path=_canonical_path_&context.page.url=_canonical_url_&context.page.referrer=_document_referrer_&context.page.title=_title_&context.screen.width=_screen_width_&context.screen.height=_screen_height_&event=$event"
},
"snowplow": {
"aaVersion": "amp-0.1",
Expand Down
1 change: 1 addition & 0 deletions extensions/amp-analytics/0.1/vendors.js
Expand Up @@ -788,6 +788,7 @@ export const ANALYTICS_CONFIG = /** @type {!JSONType} */ ({
'requests': {
'host': 'https://api.segment.io/v1/pixel',
'base': '?writeKey=${writeKey}' +
'&context.library.name=amp' +
'&anonymousId=${anonymousId}' +
'&context.locale=${browserLanguage}' +
'&context.page.path=${canonicalPath}' +
Expand Down

0 comments on commit 247b83e

Please sign in to comment.