{"action":"created","issue":{"url":"https://api.github.com/repos/eHealthAfrica/aether/issues/381","repository_url":"https://api.github.com/repos/eHealthAfrica/aether","labels_url":"https://api.github.com/repos/eHealthAfrica/aether/issues/381/labels{/name}","comments_url":"https://api.github.com/repos/eHealthAfrica/aether/issues/381/comments","events_url":"https://api.github.com/repos/eHealthAfrica/aether/issues/381/events","html_url":"https://github.com/eHealthAfrica/aether/pull/381","id":365554439,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE5NDQ3NzAw","number":381,"title":"feat: create passthrough mapping from AVRO schema","user":{"login":"obdulia-losantos","id":8459537,"node_id":"MDQ6VXNlcjg0NTk1Mzc=","avatar_url":"https://avatars1.githubusercontent.com/u/8459537?v=4","gravatar_id":"","url":"https://api.github.com/users/obdulia-losantos","html_url":"https://github.com/obdulia-losantos","followers_url":"https://api.github.com/users/obdulia-losantos/followers","following_url":"https://api.github.com/users/obdulia-losantos/following{/other_user}","gists_url":"https://api.github.com/users/obdulia-losantos/gists{/gist_id}","starred_url":"https://api.github.com/users/obdulia-losantos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/obdulia-losantos/subscriptions","organizations_url":"https://api.github.com/users/obdulia-losantos/orgs","repos_url":"https://api.github.com/users/obdulia-losantos/repos","events_url":"https://api.github.com/users/obdulia-losantos/events{/privacy}","received_events_url":"https://api.github.com/users/obdulia-losantos/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-10-01T17:03:54Z","updated_at":"2018-10-02T13:52:28Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/eHealthAfrica/aether/pulls/381","html_url":"https://github.com/eHealthAfrica/aether/pull/381","diff_url":"https://github.com/eHealthAfrica/aether/pull/381.diff","patch_url":"https://github.com/eHealthAfrica/aether/pull/381.patch"},"body":"This is the first step to integrate Gather 3 with Aether CouchDB-Sync module.\r\n\r\nInstead of creating the artefacts in the module just pushed the AVRO schema and let Kernel create all the necessary and related items.\r\n\r\nInclude this new feature also in the ODK module.\r\n\r\nThe endpoint in Kernel is `.../projects/{pk}/avro-schemas/`\r\n\r\nExpected payload:\r\n\r\n```python\r\n    {\r\n        # this is optional, indicates the action to execute:\r\n        #   \"create\", creates the missing objects but does not update the existing ones\r\n        #   otherwise creates/updates the given objects\r\n        'action': 'upsert',\r\n\r\n        # this is optional, if missing the method will assign a random name\r\n        \"name\": \"project name (optional but unique)\",\r\n\r\n        # this is optional, for each entry the method will\r\n        # create/update a schema and also link it to the project\r\n        # (projectschema entry) creating the passthrough mapping\r\n        \"avro_schemas\": [\r\n            {\r\n                \"id\": \"schema id (optional and shared with the linked artefacts)\",\r\n                \"definition\": {\r\n                    # the avro schema\r\n                }\r\n            },\r\n            # ...\r\n        ],\r\n    }\r\n```"},"comment":{"url":"https://api.github.com/repos/eHealthAfrica/aether/issues/comments/426281861","html_url":"https://github.com/eHealthAfrica/aether/pull/381#issuecomment-426281861","issue_url":"https://api.github.com/repos/eHealthAfrica/aether/issues/381","id":426281861,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNjI4MTg2MQ==","user":{"login":"adamvert","id":1815204,"node_id":"MDQ6VXNlcjE4MTUyMDQ=","avatar_url":"https://avatars1.githubusercontent.com/u/1815204?v=4","gravatar_id":"","url":"https://api.github.com/users/adamvert","html_url":"https://github.com/adamvert","followers_url":"https://api.github.com/users/adamvert/followers","following_url":"https://api.github.com/users/adamvert/following{/other_user}","gists_url":"https://api.github.com/users/adamvert/gists{/gist_id}","starred_url":"https://api.github.com/users/adamvert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adamvert/subscriptions","organizations_url":"https://api.github.com/users/adamvert/orgs","repos_url":"https://api.github.com/users/adamvert/repos","events_url":"https://api.github.com/users/adamvert/events{/privacy}","received_events_url":"https://api.github.com/users/adamvert/received_events","type":"User","site_admin":false},"created_at":"2018-10-02T13:52:28Z","updated_at":"2018-10-02T13:52:28Z","author_association":"CONTRIBUTOR","body":"This works well! The one thing I would say is that the endpoint should probably be `/propagate` rather than `/propagates`."}}
{"actor":{"display_login":"adamvert"}}