{"action":"created","comment":{"url":"https://api.github.com/repos/ampproject/amphtml/pulls/comments/87241172","pull_request_review_id":7861087,"id":87241172,"diff_hunk":"@@ -0,0 +1,137 @@\n+<!---\n+Copyright 2015 The AMP HTML Authors. All Rights Reserved.\n+\n+Licensed under the Apache License, Version 2.0 (the \"License\");\n+you may not use this file except in compliance with the License.\n+You may obtain a copy of the License at\n+\n+      http://www.apache.org/licenses/LICENSE-2.0\n+\n+Unless required by applicable law or agreed to in writing, software\n+distributed under the License is distributed on an \"AS-IS\" BASIS,\n+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+See the License for the specific language governing permissions and\n+limitations under the License.\n+-->\n+\n+# Imagead\n+\n+Imagead does not represent a specific network. Rather, it provides a way for \n+a site to display simple image ads on a self-service basis. You must provide\n+your own ad server to deliver the ads in json format as shown below.\n+\n+## Examples\n+\n+### Single ad\n+\n+```html\n+<amp-ad width=300 height=250\n+    type=\"adimage\"\n+    data-slot=\"1\"\n+    data-url=\"https://mysite/my-ad-server\"\n+>\n+</amp-ad>\n+<!-- The ad server will be called with the URL https://mysite/my-ad-server?s=1 -->\n+```\n+\n+### Two ads with different slots\n+\n+```html\n+<amp-ad width=300 height=250\n+    type=\"adimage\"\n+    data-slot=\"1\"\n+    data-url=\"https://mysite/my-ad-server\"\n+>\n+</amp-ad>\n+<amp-ad width=400 height=300\n+    type=\"adimage\"\n+    data-slot=\"2\"\n+    data-url=\"https://mysite/my-ad-server\"\n+>\n+</amp-ad>\n+<!-- The ad server will be called with the URL https://mysite/my-ad-server?s=1,2 -->\n+```\n+\n+### Ads from different ad servers\n+```html\n+<amp-ad width=300 height=250\n+    type=\"adimage\"\n+    data-slot=\"slot-name-a\"\n+    data-url=\"https://mysite/my-ad-server\"\n+>\n+</amp-ad>\n+<amp-ad width=400 height=300\n+    type=\"adimage\"\n+    data-slot=\"slot-name-b\"\n+    data-url=\"https://mysite/my-ad-server\"\n+>\n+</amp-ad>\n+<amp-ad width=300 height=250\n+    type=\"adimage\"\n+    data-slot=\"123\"\n+    data-url=\"https://my-other-site/my-other-ad-server\"\n+>\n+</amp-ad>\n+<!-- Two ad server calls will be made: -->\n+<!-- The first:  https://mysite/my-ad-server?s=slot-name-a,slot-name-b -->\n+<!-- The second: https://my-other-site/my-other-ad-server?s=123 -->\n+```\n+\n+\n+\n+## Supported parameters\n+\n+### data-url (mandatory)\n+\n+This must be starting with `https://`, and it must be the address of an ad\n+server returning json in the format defined below.\n+\n+### data-slot (mandatory)\n+\n+On the assumption that most pages have multiple ad slots, this is passed to the\n+ad server to tell it which slot is being fetched. It is generally a number, but it \n+can be some arbitrary string as long as it does not contain the characters \"?\" and \"&\".\n+\n+### data-target (optional)\n+\n+Can be one of `_blank` or `_self` to indicate where the target URL should open when\n+the ad is clicked on.\n+\n+## Ad server\n+\n+The ad server will be called once for each value of `data-url` on the page: for the vast \n+majority of applications, all your ads will be from a single server so it will be\n+called only once.\n+\n+A parameter like `?s=1,2` will be appended to the URL specified by `data-url` in order","path":"ads/imagead.md","position":131,"original_position":106,"commit_id":"01db1440fd6534afe2dde5ae7f83e3e97f6e4ffc","original_commit_id":"682b65b9a2c3db1dca0aa7923a907b44450d0143","user":{"login":"lannka","id":8496897,"avatar_url":"https://avatars.githubusercontent.com/u/8496897?v=3","gravatar_id":"","url":"https://api.github.com/users/lannka","html_url":"https://github.com/lannka","followers_url":"https://api.github.com/users/lannka/followers","following_url":"https://api.github.com/users/lannka/following{/other_user}","gists_url":"https://api.github.com/users/lannka/gists{/gist_id}","starred_url":"https://api.github.com/users/lannka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lannka/subscriptions","organizations_url":"https://api.github.com/users/lannka/orgs","repos_url":"https://api.github.com/users/lannka/repos","events_url":"https://api.github.com/users/lannka/events{/privacy}","received_events_url":"https://api.github.com/users/lannka/received_events","type":"User","site_admin":false},"body":"Thinking twice, appending extra URL params is harmless. Pub can still use their own URL format if they want, they just need to ignore `s=1,2`. \r\n\r\nMy only ask is then to change `s` to amp specific to avoid naming conflict. Tentatively: `ampslots`","created_at":"2016-11-09T17:41:14Z","updated_at":"2016-11-09T17:41:14Z","html_url":"https://github.com/ampproject/amphtml/pull/5751#discussion_r87241172","pull_request_url":"https://api.github.com/repos/ampproject/amphtml/pulls/5751","_links":{"self":{"href":"https://api.github.com/repos/ampproject/amphtml/pulls/comments/87241172"},"html":{"href":"https://github.com/ampproject/amphtml/pull/5751#discussion_r87241172"},"pull_request":{"href":"https://api.github.com/repos/ampproject/amphtml/pulls/5751"}}},"pull_request":{"url":"https://api.github.com/repos/ampproject/amphtml/pulls/5751","id":90391291,"html_url":"https://github.com/ampproject/amphtml/pull/5751","diff_url":"https://github.com/ampproject/amphtml/pull/5751.diff","patch_url":"https://github.com/ampproject/amphtml/pull/5751.patch","issue_url":"https://api.github.com/repos/ampproject/amphtml/issues/5751","number":5751,"state":"open","locked":false,"title":"First implementation of imagead (intent to implement #5541)","user":{"login":"xgretsch","id":898362,"avatar_url":"https://avatars.githubusercontent.com/u/898362?v=3","gravatar_id":"","url":"https://api.github.com/users/xgretsch","html_url":"https://github.com/xgretsch","followers_url":"https://api.github.com/users/xgretsch/followers","following_url":"https://api.github.com/users/xgretsch/following{/other_user}","gists_url":"https://api.github.com/users/xgretsch/gists{/gist_id}","starred_url":"https://api.github.com/users/xgretsch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xgretsch/subscriptions","organizations_url":"https://api.github.com/users/xgretsch/orgs","repos_url":"https://api.github.com/users/xgretsch/repos","events_url":"https://api.github.com/users/xgretsch/events{/privacy}","received_events_url":"https://api.github.com/users/xgretsch/received_events","type":"User","site_admin":false},"body":"This is fairly bare-bones: still needs converting the example ad server\nfrom one on pbl.bachtrack.com to one on the test server, and still\nneeds some tests implemented. May possibly also want to add support\nfor mustache.js templates - to be decided.\n","created_at":"2016-10-21T14:16:46Z","updated_at":"2016-11-09T17:41:14Z","closed_at":null,"merged_at":null,"merge_commit_sha":"cf48036f7800001ee949d30555ea88f26cf54218","assignee":{"login":"lannka","id":8496897,"avatar_url":"https://avatars.githubusercontent.com/u/8496897?v=3","gravatar_id":"","url":"https://api.github.com/users/lannka","html_url":"https://github.com/lannka","followers_url":"https://api.github.com/users/lannka/followers","following_url":"https://api.github.com/users/lannka/following{/other_user}","gists_url":"https://api.github.com/users/lannka/gists{/gist_id}","starred_url":"https://api.github.com/users/lannka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lannka/subscriptions","organizations_url":"https://api.github.com/users/lannka/orgs","repos_url":"https://api.github.com/users/lannka/repos","events_url":"https://api.github.com/users/lannka/events{/privacy}","received_events_url":"https://api.github.com/users/lannka/received_events","type":"User","site_admin":false},"assignees":[{"login":"lannka","id":8496897,"avatar_url":"https://avatars.githubusercontent.com/u/8496897?v=3","gravatar_id":"","url":"https://api.github.com/users/lannka","html_url":"https://github.com/lannka","followers_url":"https://api.github.com/users/lannka/followers","following_url":"https://api.github.com/users/lannka/following{/other_user}","gists_url":"https://api.github.com/users/lannka/gists{/gist_id}","starred_url":"https://api.github.com/users/lannka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lannka/subscriptions","organizations_url":"https://api.github.com/users/lannka/orgs","repos_url":"https://api.github.com/users/lannka/repos","events_url":"https://api.github.com/users/lannka/events{/privacy}","received_events_url":"https://api.github.com/users/lannka/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/ampproject/amphtml/pulls/5751/commits","review_comments_url":"https://api.github.com/repos/ampproject/amphtml/pulls/5751/comments","review_comment_url":"https://api.github.com/repos/ampproject/amphtml/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ampproject/amphtml/issues/5751/comments","statuses_url":"https://api.github.com/repos/ampproject/amphtml/statuses/01db1440fd6534afe2dde5ae7f83e3e97f6e4ffc","head":{"label":"xgretsch:imagead","ref":"imagead","sha":"01db1440fd6534afe2dde5ae7f83e3e97f6e4ffc","user":{"login":"xgretsch","id":898362,"avatar_url":"https://avatars.githubusercontent.com/u/898362?v=3","gravatar_id":"","url":"https://api.github.com/users/xgretsch","html_url":"https://github.com/xgretsch","followers_url":"https://api.github.com/users/xgretsch/followers","following_url":"https://api.github.com/users/xgretsch/following{/other_user}","gists_url":"https://api.github.com/users/xgretsch/gists{/gist_id}","starred_url":"https://api.github.com/users/xgretsch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xgretsch/subscriptions","organizations_url":"https://api.github.com/users/xgretsch/orgs","repos_url":"https://api.github.com/users/xgretsch/repos","events_url":"https://api.github.com/users/xgretsch/events{/privacy}","received_events_url":"https://api.github.com/users/xgretsch/received_events","type":"User","site_admin":false},"repo":{"id":71483792,"name":"amphtml","full_name":"xgretsch/amphtml","owner":{"login":"xgretsch","id":898362,"avatar_url":"https://avatars.githubusercontent.com/u/898362?v=3","gravatar_id":"","url":"https://api.github.com/users/xgretsch","html_url":"https://github.com/xgretsch","followers_url":"https://api.github.com/users/xgretsch/followers","following_url":"https://api.github.com/users/xgretsch/following{/other_user}","gists_url":"https://api.github.com/users/xgretsch/gists{/gist_id}","starred_url":"https://api.github.com/users/xgretsch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xgretsch/subscriptions","organizations_url":"https://api.github.com/users/xgretsch/orgs","repos_url":"https://api.github.com/users/xgretsch/repos","events_url":"https://api.github.com/users/xgretsch/events{/privacy}","received_events_url":"https://api.github.com/users/xgretsch/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/xgretsch/amphtml","description":"AMP HTML source code, samples, and documentation.  See below for more info.","fork":true,"url":"https://api.github.com/repos/xgretsch/amphtml","forks_url":"https://api.github.com/repos/xgretsch/amphtml/forks","keys_url":"https://api.github.com/repos/xgretsch/amphtml/keys{/key_id}","collaborators_url":"https://api.github.com/repos/xgretsch/amphtml/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/xgretsch/amphtml/teams","hooks_url":"https://api.github.com/repos/xgretsch/amphtml/hooks","issue_events_url":"https://api.github.com/repos/xgretsch/amphtml/issues/events{/number}","events_url":"https://api.github.com/repos/xgretsch/amphtml/events","assignees_url":"https://api.github.com/repos/xgretsch/amphtml/assignees{/user}","branches_url":"https://api.github.com/repos/xgretsch/amphtml/branches{/branch}","tags_url":"https://api.github.com/repos/xgretsch/amphtml/tags","blobs_url":"https://api.github.com/repos/xgretsch/amphtml/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/xgretsch/amphtml/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/xgretsch/amphtml/git/refs{/sha}","trees_url":"https://api.github.com/repos/xgretsch/amphtml/git/trees{/sha}","statuses_url":"https://api.github.com/repos/xgretsch/amphtml/statuses/{sha}","languages_url":"https://api.github.com/repos/xgretsch/amphtml/languages","stargazers_url":"https://api.github.com/repos/xgretsch/amphtml/stargazers","contributors_url":"https://api.github.com/repos/xgretsch/amphtml/contributors","subscribers_url":"https://api.github.com/repos/xgretsch/amphtml/subscribers","subscription_url":"https://api.github.com/repos/xgretsch/amphtml/subscription","commits_url":"https://api.github.com/repos/xgretsch/amphtml/commits{/sha}","git_commits_url":"https://api.github.com/repos/xgretsch/amphtml/git/commits{/sha}","comments_url":"https://api.github.com/repos/xgretsch/amphtml/comments{/number}","issue_comment_url":"https://api.github.com/repos/xgretsch/amphtml/issues/comments{/number}","contents_url":"https://api.github.com/repos/xgretsch/amphtml/contents/{+path}","compare_url":"https://api.github.com/repos/xgretsch/amphtml/compare/{base}...{head}","merges_url":"https://api.github.com/repos/xgretsch/amphtml/merges","archive_url":"https://api.github.com/repos/xgretsch/amphtml/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/xgretsch/amphtml/downloads","issues_url":"https://api.github.com/repos/xgretsch/amphtml/issues{/number}","pulls_url":"https://api.github.com/repos/xgretsch/amphtml/pulls{/number}","milestones_url":"https://api.github.com/repos/xgretsch/amphtml/milestones{/number}","notifications_url":"https://api.github.com/repos/xgretsch/amphtml/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/xgretsch/amphtml/labels{/name}","releases_url":"https://api.github.com/repos/xgretsch/amphtml/releases{/id}","deployments_url":"https://api.github.com/repos/xgretsch/amphtml/deployments","created_at":"2016-10-20T16:44:46Z","updated_at":"2016-10-20T16:44:51Z","pushed_at":"2016-11-09T15:15:29Z","git_url":"git://github.com/xgretsch/amphtml.git","ssh_url":"git@github.com:xgretsch/amphtml.git","clone_url":"https://github.com/xgretsch/amphtml.git","svn_url":"https://github.com/xgretsch/amphtml","homepage":"https://ampproject.org","size":178083,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ampproject:master","ref":"master","sha":"2eb26fea7d6fb93750543372eeb9b1c25e6a0216","user":{"login":"ampproject","id":14114390,"avatar_url":"https://avatars.githubusercontent.com/u/14114390?v=3","gravatar_id":"","url":"https://api.github.com/users/ampproject","html_url":"https://github.com/ampproject","followers_url":"https://api.github.com/users/ampproject/followers","following_url":"https://api.github.com/users/ampproject/following{/other_user}","gists_url":"https://api.github.com/users/ampproject/gists{/gist_id}","starred_url":"https://api.github.com/users/ampproject/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ampproject/subscriptions","organizations_url":"https://api.github.com/users/ampproject/orgs","repos_url":"https://api.github.com/users/ampproject/repos","events_url":"https://api.github.com/users/ampproject/events{/privacy}","received_events_url":"https://api.github.com/users/ampproject/received_events","type":"Organization","site_admin":false},"repo":{"id":41766002,"name":"amphtml","full_name":"ampproject/amphtml","owner":{"login":"ampproject","id":14114390,"avatar_url":"https://avatars.githubusercontent.com/u/14114390?v=3","gravatar_id":"","url":"https://api.github.com/users/ampproject","html_url":"https://github.com/ampproject","followers_url":"https://api.github.com/users/ampproject/followers","following_url":"https://api.github.com/users/ampproject/following{/other_user}","gists_url":"https://api.github.com/users/ampproject/gists{/gist_id}","starred_url":"https://api.github.com/users/ampproject/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ampproject/subscriptions","organizations_url":"https://api.github.com/users/ampproject/orgs","repos_url":"https://api.github.com/users/ampproject/repos","events_url":"https://api.github.com/users/ampproject/events{/privacy}","received_events_url":"https://api.github.com/users/ampproject/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ampproject/amphtml","description":"AMP HTML source code, samples, and documentation.  See below for more info.","fork":false,"url":"https://api.github.com/repos/ampproject/amphtml","forks_url":"https://api.github.com/repos/ampproject/amphtml/forks","keys_url":"https://api.github.com/repos/ampproject/amphtml/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ampproject/amphtml/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ampproject/amphtml/teams","hooks_url":"https://api.github.com/repos/ampproject/amphtml/hooks","issue_events_url":"https://api.github.com/repos/ampproject/amphtml/issues/events{/number}","events_url":"https://api.github.com/repos/ampproject/amphtml/events","assignees_url":"https://api.github.com/repos/ampproject/amphtml/assignees{/user}","branches_url":"https://api.github.com/repos/ampproject/amphtml/branches{/branch}","tags_url":"https://api.github.com/repos/ampproject/amphtml/tags","blobs_url":"https://api.github.com/repos/ampproject/amphtml/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ampproject/amphtml/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ampproject/amphtml/git/refs{/sha}","trees_url":"https://api.github.com/repos/ampproject/amphtml/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ampproject/amphtml/statuses/{sha}","languages_url":"https://api.github.com/repos/ampproject/amphtml/languages","stargazers_url":"https://api.github.com/repos/ampproject/amphtml/stargazers","contributors_url":"https://api.github.com/repos/ampproject/amphtml/contributors","subscribers_url":"https://api.github.com/repos/ampproject/amphtml/subscribers","subscription_url":"https://api.github.com/repos/ampproject/amphtml/subscription","commits_url":"https://api.github.com/repos/ampproject/amphtml/commits{/sha}","git_commits_url":"https://api.github.com/repos/ampproject/amphtml/git/commits{/sha}","comments_url":"https://api.github.com/repos/ampproject/amphtml/comments{/number}","issue_comment_url":"https://api.github.com/repos/ampproject/amphtml/issues/comments{/number}","contents_url":"https://api.github.com/repos/ampproject/amphtml/contents/{+path}","compare_url":"https://api.github.com/repos/ampproject/amphtml/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ampproject/amphtml/merges","archive_url":"https://api.github.com/repos/ampproject/amphtml/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ampproject/amphtml/downloads","issues_url":"https://api.github.com/repos/ampproject/amphtml/issues{/number}","pulls_url":"https://api.github.com/repos/ampproject/amphtml/pulls{/number}","milestones_url":"https://api.github.com/repos/ampproject/amphtml/milestones{/number}","notifications_url":"https://api.github.com/repos/ampproject/amphtml/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ampproject/amphtml/labels{/name}","releases_url":"https://api.github.com/repos/ampproject/amphtml/releases{/id}","deployments_url":"https://api.github.com/repos/ampproject/amphtml/deployments","created_at":"2015-09-01T22:10:53Z","updated_at":"2016-11-09T16:44:32Z","pushed_at":"2016-11-09T17:32:15Z","git_url":"git://github.com/ampproject/amphtml.git","ssh_url":"git@github.com:ampproject/amphtml.git","clone_url":"https://github.com/ampproject/amphtml.git","svn_url":"https://github.com/ampproject/amphtml","homepage":"https://ampproject.org","size":220719,"stargazers_count":9012,"watchers_count":9012,"language":"JavaScript","has_issues":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":1378,"mirror_url":null,"open_issues_count":957,"forks":1378,"open_issues":957,"watchers":9012,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ampproject/amphtml/pulls/5751"},"html":{"href":"https://github.com/ampproject/amphtml/pull/5751"},"issue":{"href":"https://api.github.com/repos/ampproject/amphtml/issues/5751"},"comments":{"href":"https://api.github.com/repos/ampproject/amphtml/issues/5751/comments"},"review_comments":{"href":"https://api.github.com/repos/ampproject/amphtml/pulls/5751/comments"},"review_comment":{"href":"https://api.github.com/repos/ampproject/amphtml/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ampproject/amphtml/pulls/5751/commits"},"statuses":{"href":"https://api.github.com/repos/ampproject/amphtml/statuses/01db1440fd6534afe2dde5ae7f83e3e97f6e4ffc"}}}}
{"actor":{"display_login":"lannka"}}