{"action":"created","issue":{"url":"https://api.github.com/repos/bwmarrin/discordgo/issues/273","repository_url":"https://api.github.com/repos/bwmarrin/discordgo","labels_url":"https://api.github.com/repos/bwmarrin/discordgo/issues/273/labels{/name}","comments_url":"https://api.github.com/repos/bwmarrin/discordgo/issues/273/comments","events_url":"https://api.github.com/repos/bwmarrin/discordgo/issues/273/events","html_url":"https://github.com/bwmarrin/discordgo/pull/273","id":183988191,"number":273,"title":"Ratelimits","user":{"login":"jonas747","id":1083807,"avatar_url":"https://avatars.githubusercontent.com/u/1083807?v=3","gravatar_id":"","url":"https://api.github.com/users/jonas747","html_url":"https://github.com/jonas747","followers_url":"https://api.github.com/users/jonas747/followers","following_url":"https://api.github.com/users/jonas747/following{/other_user}","gists_url":"https://api.github.com/users/jonas747/gists{/gist_id}","starred_url":"https://api.github.com/users/jonas747/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonas747/subscriptions","organizations_url":"https://api.github.com/users/jonas747/orgs","repos_url":"https://api.github.com/users/jonas747/repos","events_url":"https://api.github.com/users/jonas747/events{/privacy}","received_events_url":"https://api.github.com/users/jonas747/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":11,"created_at":"2016-10-19T15:03:40Z","updated_at":"2016-10-27T07:36:01Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/bwmarrin/discordgo/pulls/273","html_url":"https://github.com/bwmarrin/discordgo/pull/273","diff_url":"https://github.com/bwmarrin/discordgo/pull/273.diff","patch_url":"https://github.com/bwmarrin/discordgo/pull/273.patch"},"body":"Handles the new ratelimit headers\r\n - X-RateLimit-Remaining\r\n - X-RateLimit-Reset\r\n - X-RateLimit-Global\r\n\r\nI stuck it in an internal package, hope that's okay.\r\nThis is probably not the best way to do the removal of minor url variables, the alternative is to redo the whole endpoint system.\r\n\r\nAs for the reliability of this, after sending around 1k requests non-stop i didn't encounter a single 429.\r\n\r\nI pad the reset time with 1 second, because if i don't it will still occasionally run into 429's of the size 1ms - 50ms (yeah, i got ratelimited for 1 ms a lot...), padding with anything less than 1 second would still give those tiny ratelimits sometimes. "},"comment":{"url":"https://api.github.com/repos/bwmarrin/discordgo/issues/comments/256568949","html_url":"https://github.com/bwmarrin/discordgo/pull/273#issuecomment-256568949","issue_url":"https://api.github.com/repos/bwmarrin/discordgo/issues/273","id":256568949,"user":{"login":"jonas747","id":1083807,"avatar_url":"https://avatars.githubusercontent.com/u/1083807?v=3","gravatar_id":"","url":"https://api.github.com/users/jonas747","html_url":"https://github.com/jonas747","followers_url":"https://api.github.com/users/jonas747/followers","following_url":"https://api.github.com/users/jonas747/following{/other_user}","gists_url":"https://api.github.com/users/jonas747/gists{/gist_id}","starred_url":"https://api.github.com/users/jonas747/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonas747/subscriptions","organizations_url":"https://api.github.com/users/jonas747/orgs","repos_url":"https://api.github.com/users/jonas747/repos","events_url":"https://api.github.com/users/jonas747/events{/privacy}","received_events_url":"https://api.github.com/users/jonas747/received_events","type":"User","site_admin":false},"created_at":"2016-10-27T07:36:01Z","updated_at":"2016-10-27T07:36:01Z","body":"Also done"}}
{"actor":{"display_login":"jonas747"}}