{"action":"created","comment":{"url":"https://api.github.com/repos/CanalTP/navitia/pulls/comments/153801991","pull_request_review_id":79863652,"id":153801991,"diff_hunk":"@@ -135,13 +168,21 @@ class PlacesSerializer(serpy.Serializer):\n     feed_publishers = FeedPublisherSerializer(many=True, display_none=True)\n     disruptions = pt.DisruptionSerializer(attr='impacts', many=True, display_none=True)\n     places = pt.PlaceSerializer(many=True)\n+    context = MethodField(schema_type=ContextSerializer(), display_none=False)\n+\n+    def get_context(self, obj):\n+        return ContextSerializer(obj, display_none=False).data\n \n \n class PtObjectsSerializer(serpy.Serializer):\n     error = ErrorSerializer(display_none=False)\n     feed_publishers = FeedPublisherSerializer(many=True, display_none=True)\n     disruptions = pt.DisruptionSerializer(attr='impacts', many=True, display_none=True)\n     pt_objects = pt.PtObjectSerializer(many=True, attr='places')\n+    context = MethodField(schema_type=ContextSerializer(), display_none=False)","path":"source/jormungandr/jormungandr/interfaces/v1/serializer/api.py","position":73,"original_position":73,"commit_id":"47126535e1796d63b9e7330465aa83a43017bf74","original_commit_id":"47126535e1796d63b9e7330465aa83a43017bf74","user":{"login":"azime","id":4006603,"avatar_url":"https://avatars0.githubusercontent.com/u/4006603?v=4","gravatar_id":"","url":"https://api.github.com/users/azime","html_url":"https://github.com/azime","followers_url":"https://api.github.com/users/azime/followers","following_url":"https://api.github.com/users/azime/following{/other_user}","gists_url":"https://api.github.com/users/azime/gists{/gist_id}","starred_url":"https://api.github.com/users/azime/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/azime/subscriptions","organizations_url":"https://api.github.com/users/azime/orgs","repos_url":"https://api.github.com/users/azime/repos","events_url":"https://api.github.com/users/azime/events{/privacy}","received_events_url":"https://api.github.com/users/azime/received_events","type":"User","site_admin":false},"body":"Done","created_at":"2017-11-29T14:29:55Z","updated_at":"2017-11-29T14:29:55Z","html_url":"https://github.com/CanalTP/navitia/pull/2255#discussion_r153801991","pull_request_url":"https://api.github.com/repos/CanalTP/navitia/pulls/2255","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/CanalTP/navitia/pulls/comments/153801991"},"html":{"href":"https://github.com/CanalTP/navitia/pull/2255#discussion_r153801991"},"pull_request":{"href":"https://api.github.com/repos/CanalTP/navitia/pulls/2255"}},"in_reply_to_id":153752907},"pull_request":{"url":"https://api.github.com/repos/CanalTP/navitia/pulls/2255","id":154828990,"html_url":"https://github.com/CanalTP/navitia/pull/2255","diff_url":"https://github.com/CanalTP/navitia/pull/2255.diff","patch_url":"https://github.com/CanalTP/navitia/pull/2255.patch","issue_url":"https://api.github.com/repos/CanalTP/navitia/issues/2255","number":2255,"state":"open","locked":false,"title":"Context for all apis","user":{"login":"azime","id":4006603,"avatar_url":"https://avatars0.githubusercontent.com/u/4006603?v=4","gravatar_id":"","url":"https://api.github.com/users/azime","html_url":"https://github.com/azime","followers_url":"https://api.github.com/users/azime/followers","following_url":"https://api.github.com/users/azime/following{/other_user}","gists_url":"https://api.github.com/users/azime/gists{/gist_id}","starred_url":"https://api.github.com/users/azime/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/azime/subscriptions","organizations_url":"https://api.github.com/users/azime/orgs","repos_url":"https://api.github.com/users/azime/repos","events_url":"https://api.github.com/users/azime/events{/privacy}","received_events_url":"https://api.github.com/users/azime/received_events","type":"User","site_admin":false},"body":"for more informations, [See](https://jira.canaltp.fr/browse/NAVP-681)\r\nExample for journeys API:\r\n```json\r\n{\r\n....\r\n  \"context\": {\r\n    \"car_direct_path\": {\r\n      \"co2_emission\": {\r\n        \"value\": 50.23,\r\n        \"unit\": \"\"\r\n      }\r\n    },\r\n    \"current_datetime\": \"20120614T080000\",\r\n    \"timezone\": \"Europe/Paris\"\r\n  }\r\n}\r\n```\r\n\r\nExample for ptref API:\r\n```json\r\n{\r\n...\r\n  \"context\": {\r\n    \"current_datetime\": \"20120614T080000\",\r\n    \"timezone\": \"Europe/Paris\"\r\n  }\r\n}\r\n```","created_at":"2017-11-27T14:50:42Z","updated_at":"2017-11-29T14:29:55Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4e224a7a56f3643ff6e8effcfdacfe359bd25cdc","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/CanalTP/navitia/pulls/2255/commits","review_comments_url":"https://api.github.com/repos/CanalTP/navitia/pulls/2255/comments","review_comment_url":"https://api.github.com/repos/CanalTP/navitia/pulls/comments{/number}","comments_url":"https://api.github.com/repos/CanalTP/navitia/issues/2255/comments","statuses_url":"https://api.github.com/repos/CanalTP/navitia/statuses/47126535e1796d63b9e7330465aa83a43017bf74","head":{"label":"azime:context_for_all_apis","ref":"context_for_all_apis","sha":"47126535e1796d63b9e7330465aa83a43017bf74","user":{"login":"azime","id":4006603,"avatar_url":"https://avatars0.githubusercontent.com/u/4006603?v=4","gravatar_id":"","url":"https://api.github.com/users/azime","html_url":"https://github.com/azime","followers_url":"https://api.github.com/users/azime/followers","following_url":"https://api.github.com/users/azime/following{/other_user}","gists_url":"https://api.github.com/users/azime/gists{/gist_id}","starred_url":"https://api.github.com/users/azime/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/azime/subscriptions","organizations_url":"https://api.github.com/users/azime/orgs","repos_url":"https://api.github.com/users/azime/repos","events_url":"https://api.github.com/users/azime/events{/privacy}","received_events_url":"https://api.github.com/users/azime/received_events","type":"User","site_admin":false},"repo":{"id":19149123,"name":"navitia","full_name":"azime/navitia","owner":{"login":"azime","id":4006603,"avatar_url":"https://avatars0.githubusercontent.com/u/4006603?v=4","gravatar_id":"","url":"https://api.github.com/users/azime","html_url":"https://github.com/azime","followers_url":"https://api.github.com/users/azime/followers","following_url":"https://api.github.com/users/azime/following{/other_user}","gists_url":"https://api.github.com/users/azime/gists{/gist_id}","starred_url":"https://api.github.com/users/azime/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/azime/subscriptions","organizations_url":"https://api.github.com/users/azime/orgs","repos_url":"https://api.github.com/users/azime/repos","events_url":"https://api.github.com/users/azime/events{/privacy}","received_events_url":"https://api.github.com/users/azime/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/azime/navitia","description":null,"fork":true,"url":"https://api.github.com/repos/azime/navitia","forks_url":"https://api.github.com/repos/azime/navitia/forks","keys_url":"https://api.github.com/repos/azime/navitia/keys{/key_id}","collaborators_url":"https://api.github.com/repos/azime/navitia/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/azime/navitia/teams","hooks_url":"https://api.github.com/repos/azime/navitia/hooks","issue_events_url":"https://api.github.com/repos/azime/navitia/issues/events{/number}","events_url":"https://api.github.com/repos/azime/navitia/events","assignees_url":"https://api.github.com/repos/azime/navitia/assignees{/user}","branches_url":"https://api.github.com/repos/azime/navitia/branches{/branch}","tags_url":"https://api.github.com/repos/azime/navitia/tags","blobs_url":"https://api.github.com/repos/azime/navitia/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/azime/navitia/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/azime/navitia/git/refs{/sha}","trees_url":"https://api.github.com/repos/azime/navitia/git/trees{/sha}","statuses_url":"https://api.github.com/repos/azime/navitia/statuses/{sha}","languages_url":"https://api.github.com/repos/azime/navitia/languages","stargazers_url":"https://api.github.com/repos/azime/navitia/stargazers","contributors_url":"https://api.github.com/repos/azime/navitia/contributors","subscribers_url":"https://api.github.com/repos/azime/navitia/subscribers","subscription_url":"https://api.github.com/repos/azime/navitia/subscription","commits_url":"https://api.github.com/repos/azime/navitia/commits{/sha}","git_commits_url":"https://api.github.com/repos/azime/navitia/git/commits{/sha}","comments_url":"https://api.github.com/repos/azime/navitia/comments{/number}","issue_comment_url":"https://api.github.com/repos/azime/navitia/issues/comments{/number}","contents_url":"https://api.github.com/repos/azime/navitia/contents/{+path}","compare_url":"https://api.github.com/repos/azime/navitia/compare/{base}...{head}","merges_url":"https://api.github.com/repos/azime/navitia/merges","archive_url":"https://api.github.com/repos/azime/navitia/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/azime/navitia/downloads","issues_url":"https://api.github.com/repos/azime/navitia/issues{/number}","pulls_url":"https://api.github.com/repos/azime/navitia/pulls{/number}","milestones_url":"https://api.github.com/repos/azime/navitia/milestones{/number}","notifications_url":"https://api.github.com/repos/azime/navitia/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/azime/navitia/labels{/name}","releases_url":"https://api.github.com/repos/azime/navitia/releases{/id}","deployments_url":"https://api.github.com/repos/azime/navitia/deployments","created_at":"2014-04-25T14:34:34Z","updated_at":"2014-06-17T14:45:02Z","pushed_at":"2017-11-28T11:21:40Z","git_url":"git://github.com/azime/navitia.git","ssh_url":"git@github.com:azime/navitia.git","clone_url":"https://github.com/azime/navitia.git","svn_url":"https://github.com/azime/navitia","homepage":"http://www.navitia.io/","size":37455,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"agpl-3.0","name":"GNU Affero General Public License v3.0","spdx_id":"AGPL-3.0","url":"https://api.github.com/licenses/agpl-3.0"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"dev"}},"base":{"label":"CanalTP:dev","ref":"dev","sha":"6b92de28bef0573f6a291a1a7a48d863eae091ed","user":{"login":"CanalTP","id":2743985,"avatar_url":"https://avatars2.githubusercontent.com/u/2743985?v=4","gravatar_id":"","url":"https://api.github.com/users/CanalTP","html_url":"https://github.com/CanalTP","followers_url":"https://api.github.com/users/CanalTP/followers","following_url":"https://api.github.com/users/CanalTP/following{/other_user}","gists_url":"https://api.github.com/users/CanalTP/gists{/gist_id}","starred_url":"https://api.github.com/users/CanalTP/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CanalTP/subscriptions","organizations_url":"https://api.github.com/users/CanalTP/orgs","repos_url":"https://api.github.com/users/CanalTP/repos","events_url":"https://api.github.com/users/CanalTP/events{/privacy}","received_events_url":"https://api.github.com/users/CanalTP/received_events","type":"Organization","site_admin":false},"repo":{"id":10797333,"name":"navitia","full_name":"CanalTP/navitia","owner":{"login":"CanalTP","id":2743985,"avatar_url":"https://avatars2.githubusercontent.com/u/2743985?v=4","gravatar_id":"","url":"https://api.github.com/users/CanalTP","html_url":"https://github.com/CanalTP","followers_url":"https://api.github.com/users/CanalTP/followers","following_url":"https://api.github.com/users/CanalTP/following{/other_user}","gists_url":"https://api.github.com/users/CanalTP/gists{/gist_id}","starred_url":"https://api.github.com/users/CanalTP/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CanalTP/subscriptions","organizations_url":"https://api.github.com/users/CanalTP/orgs","repos_url":"https://api.github.com/users/CanalTP/repos","events_url":"https://api.github.com/users/CanalTP/events{/privacy}","received_events_url":"https://api.github.com/users/CanalTP/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CanalTP/navitia","description":"The open source software to build cool stuff with locomotion","fork":false,"url":"https://api.github.com/repos/CanalTP/navitia","forks_url":"https://api.github.com/repos/CanalTP/navitia/forks","keys_url":"https://api.github.com/repos/CanalTP/navitia/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CanalTP/navitia/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CanalTP/navitia/teams","hooks_url":"https://api.github.com/repos/CanalTP/navitia/hooks","issue_events_url":"https://api.github.com/repos/CanalTP/navitia/issues/events{/number}","events_url":"https://api.github.com/repos/CanalTP/navitia/events","assignees_url":"https://api.github.com/repos/CanalTP/navitia/assignees{/user}","branches_url":"https://api.github.com/repos/CanalTP/navitia/branches{/branch}","tags_url":"https://api.github.com/repos/CanalTP/navitia/tags","blobs_url":"https://api.github.com/repos/CanalTP/navitia/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CanalTP/navitia/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CanalTP/navitia/git/refs{/sha}","trees_url":"https://api.github.com/repos/CanalTP/navitia/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CanalTP/navitia/statuses/{sha}","languages_url":"https://api.github.com/repos/CanalTP/navitia/languages","stargazers_url":"https://api.github.com/repos/CanalTP/navitia/stargazers","contributors_url":"https://api.github.com/repos/CanalTP/navitia/contributors","subscribers_url":"https://api.github.com/repos/CanalTP/navitia/subscribers","subscription_url":"https://api.github.com/repos/CanalTP/navitia/subscription","commits_url":"https://api.github.com/repos/CanalTP/navitia/commits{/sha}","git_commits_url":"https://api.github.com/repos/CanalTP/navitia/git/commits{/sha}","comments_url":"https://api.github.com/repos/CanalTP/navitia/comments{/number}","issue_comment_url":"https://api.github.com/repos/CanalTP/navitia/issues/comments{/number}","contents_url":"https://api.github.com/repos/CanalTP/navitia/contents/{+path}","compare_url":"https://api.github.com/repos/CanalTP/navitia/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CanalTP/navitia/merges","archive_url":"https://api.github.com/repos/CanalTP/navitia/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CanalTP/navitia/downloads","issues_url":"https://api.github.com/repos/CanalTP/navitia/issues{/number}","pulls_url":"https://api.github.com/repos/CanalTP/navitia/pulls{/number}","milestones_url":"https://api.github.com/repos/CanalTP/navitia/milestones{/number}","notifications_url":"https://api.github.com/repos/CanalTP/navitia/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CanalTP/navitia/labels{/name}","releases_url":"https://api.github.com/repos/CanalTP/navitia/releases{/id}","deployments_url":"https://api.github.com/repos/CanalTP/navitia/deployments","created_at":"2013-06-19T15:34:30Z","updated_at":"2017-11-26T09:30:55Z","pushed_at":"2017-11-29T12:47:15Z","git_url":"git://github.com/CanalTP/navitia.git","ssh_url":"git@github.com:CanalTP/navitia.git","clone_url":"https://github.com/CanalTP/navitia.git","svn_url":"https://github.com/CanalTP/navitia","homepage":"http://www.navitia.io","size":38571,"stargazers_count":235,"watchers_count":235,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":80,"mirror_url":null,"archived":false,"open_issues_count":31,"license":{"key":"agpl-3.0","name":"GNU Affero General Public License v3.0","spdx_id":"AGPL-3.0","url":"https://api.github.com/licenses/agpl-3.0"},"forks":80,"open_issues":31,"watchers":235,"default_branch":"dev"}},"_links":{"self":{"href":"https://api.github.com/repos/CanalTP/navitia/pulls/2255"},"html":{"href":"https://github.com/CanalTP/navitia/pull/2255"},"issue":{"href":"https://api.github.com/repos/CanalTP/navitia/issues/2255"},"comments":{"href":"https://api.github.com/repos/CanalTP/navitia/issues/2255/comments"},"review_comments":{"href":"https://api.github.com/repos/CanalTP/navitia/pulls/2255/comments"},"review_comment":{"href":"https://api.github.com/repos/CanalTP/navitia/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/CanalTP/navitia/pulls/2255/commits"},"statuses":{"href":"https://api.github.com/repos/CanalTP/navitia/statuses/47126535e1796d63b9e7330465aa83a43017bf74"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"azime"}}