Skip to content

Commit 2b870c1

Browse files
ncloudiojbytesized
authored andcommitted
Bug 1688698 - Add 'source' to TopSites schemas in Contextual Services (mozilla-services#657)
1 parent 0b02bf2 commit 2b870c1

File tree

6 files changed

+29
-0
lines changed

6 files changed

+29
-0
lines changed

schemas/contextual-services/topsites-click/topsites-click.1.schema.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,14 @@
4646
"description": "The reporting URL of the ad, normally pointing to the ad partner's reporting endpoint. It's URL encoded",
4747
"type": "string"
4848
},
49+
"source": {
50+
"description": "The browser location where the click was triggered",
51+
"enum": [
52+
"newtab",
53+
"urlbar"
54+
],
55+
"type": "string"
56+
},
4957
"tile_id": {
5058
"description": "A unique identifier for the sponsored tile",
5159
"type": "integer"

schemas/contextual-services/topsites-impression/topsites-impression.1.schema.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,14 @@
4646
"description": "The reporting URL of the ad, normally pointing to the ad partner's reporting endpoint. It's URL encoded",
4747
"type": "string"
4848
},
49+
"source": {
50+
"description": "The browser location where the impression was displayed",
51+
"enum": [
52+
"newtab",
53+
"urlbar"
54+
],
55+
"type": "string"
56+
},
4957
"tile_id": {
5058
"description": "A unique identifier for the sponsored tile",
5159
"type": "integer"

templates/contextual-services/topsites-click/topsites-click.1.schema.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
"description": "A unique identifier for the sponsored tile",
1414
"type": "integer"
1515
},
16+
"source": {
17+
"type": "string",
18+
"enum": [ "newtab", "urlbar" ],
19+
"description": "The browser location where the click was triggered"
20+
},
1621
"position": {
1722
"description": "The placement of the tile (1-based)",
1823
"type": "integer"

templates/contextual-services/topsites-impression/topsites-impression.1.schema.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
"description": "A unique identifier for the sponsored tile",
1414
"type": "integer"
1515
},
16+
"source": {
17+
"type": "string",
18+
"enum": [ "newtab", "urlbar" ],
19+
"description": "The browser location where the impression was displayed"
20+
},
1621
"position": {
1722
"description": "The placement of the tile (1-based)",
1823
"type": "integer"

validation/contextual-services/topsites-click.1.event.pass.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
{
22
"context_id": "{94642acb-4996-034b-916c-147da723cc41}",
33
"tile_id": 42,
4+
"source": "urlbar",
5+
"position": 1,
46
"advertiser": "test-advertiser",
57
"reporting_url": "https://test.reporting.net/ctp?version=16.0.0&key=1598991514900100001.1&ci=15 98991514792.12747&ctag=1598291839300100006&aespFlag=altinst",
68
"locale": "en-US",

validation/contextual-services/topsites-impression.1.event.pass.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
"context_id": "{94642acb-4996-034b-916c-147da723cc41}",
33
"advertiser": "test-advertiser",
44
"tile_id": 42,
5+
"source": "newtab",
56
"position": 1,
67
"reporting_url": "https://test.reporting.net/static?id=7RHzfOIWHG7kJnEYgGeuJm7vJ%3DEkiFXwxYIZjF8XgClWfC 8%2B7R4dHQ8zjmENj%3DNwxwz%2FJmdw7R4dHQfz4Z2ZfplnHG3Z5FwqgCfX4ZLafC2mfBINI9HuiF2 z4Z2ZfplnHmcux%3DcvImauiF2zfQlWfpDX7R3%2Bx%3DDuiF2zfLyy",
78
"locale": "en-US",

0 commit comments

Comments
 (0)