{"action":"created","issue":{"url":"https://api.github.com/repos/tuupola/branca-spec/issues/8","repository_url":"https://api.github.com/repos/tuupola/branca-spec","labels_url":"https://api.github.com/repos/tuupola/branca-spec/issues/8/labels{/name}","comments_url":"https://api.github.com/repos/tuupola/branca-spec/issues/8/comments","events_url":"https://api.github.com/repos/tuupola/branca-spec/issues/8/events","html_url":"https://github.com/tuupola/branca-spec/issues/8","id":285904038,"number":8,"title":"Go implementation","user":{"login":"tuupola","id":21913,"avatar_url":"https://avatars0.githubusercontent.com/u/21913?v=4","gravatar_id":"","url":"https://api.github.com/users/tuupola","html_url":"https://github.com/tuupola","followers_url":"https://api.github.com/users/tuupola/followers","following_url":"https://api.github.com/users/tuupola/following{/other_user}","gists_url":"https://api.github.com/users/tuupola/gists{/gist_id}","starred_url":"https://api.github.com/users/tuupola/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tuupola/subscriptions","organizations_url":"https://api.github.com/users/tuupola/orgs","repos_url":"https://api.github.com/users/tuupola/repos","events_url":"https://api.github.com/users/tuupola/events{/privacy}","received_events_url":"https://api.github.com/users/tuupola/received_events","type":"User","site_admin":false},"labels":[{"id":653063205,"url":"https://api.github.com/repos/tuupola/branca-spec/labels/help%20wanted","name":"help wanted","color":"128A0C","default":true}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2018-01-04T07:40:53Z","updated_at":"2018-03-14T16:35:46Z","closed_at":"2018-02-12T04:19:31Z","author_association":"OWNER","body":"Go implementation is missing. Something similar as [fernet-go](https://github.com/fernet/fernet-go) by @kr. Anyone interested in implementing it write me a note here and I will add it to the docs.\r\n  "},"comment":{"url":"https://api.github.com/repos/tuupola/branca-spec/issues/comments/373088569","html_url":"https://github.com/tuupola/branca-spec/issues/8#issuecomment-373088569","issue_url":"https://api.github.com/repos/tuupola/branca-spec/issues/8","id":373088569,"user":{"login":"hako","id":2040416,"avatar_url":"https://avatars0.githubusercontent.com/u/2040416?v=4","gravatar_id":"","url":"https://api.github.com/users/hako","html_url":"https://github.com/hako","followers_url":"https://api.github.com/users/hako/followers","following_url":"https://api.github.com/users/hako/following{/other_user}","gists_url":"https://api.github.com/users/hako/gists{/gist_id}","starred_url":"https://api.github.com/users/hako/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hako/subscriptions","organizations_url":"https://api.github.com/users/hako/orgs","repos_url":"https://api.github.com/users/hako/repos","events_url":"https://api.github.com/users/hako/events{/privacy}","received_events_url":"https://api.github.com/users/hako/received_events","type":"User","site_admin":false},"created_at":"2018-03-14T16:35:46Z","updated_at":"2018-03-14T16:35:46Z","author_association":"NONE","body":"Here is a short example:\r\n\r\n```go\r\npackage main\r\n\r\nimport (\r\n        \"fmt\"\r\n\t\"encoding/json\"\r\n\t\r\n\t\"github.com/hako/branca\"\r\n)\r\n\r\nfunc main() {\r\n\tbrca := branca.NewBranca(\"supersecretkeyyoushouldnotcommit\")\r\n\r\n\tdata := struct {\r\n\t\tUser  string   `json:\"user\"`\r\n\t\tScope []string `json:\"scope\"`\r\n\t}{\r\n\t\tUser:  \"someone@example.com\",\r\n\t\tScope: []string{\"read\", \"write\", \"delete\"},\r\n\t}\r\n\r\n\tjsn, err := json.Marshal(data)\r\n\ttoken, err := brca.EncodeToString(string(jsn[:]))\r\n\tpayload, err := brca.DecodeToString(token)\r\n\tif err != nil {\r\n\t\tfmt.Println(err)\r\n\t\treturn\r\n\t}\r\n\r\n\tfmt.Println(token)\r\n\tfmt.Println(payload)\r\n}\r\n```"}}
{"actor":{"display_login":"hako"}}