{"issue":{"state":"open","created_at":"2011-08-24T18:52:45Z","updated_at":"2011-12-06T01:58:10Z","user":{"gravatar_id":"55234a0410bd45d5a24adbe3002107b5","id":341417,"url":"https://api.github.com/users/ezarko","login":"ezarko","avatar_url":"https://secure.gravatar.com/avatar/55234a0410bd45d5a24adbe3002107b5?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png"},"comments":3,"body":"Change \"apiConfig.baseURL\" to \"apiConfig.host\" since that is all it\r\nreally supports. Added \"apiConfig.port\". Removed paramString from URL\r\nfor POST/PUT. Added body for POST/PUT. Changed from http.request to\r\nhttps.request if https protocol is used. Fixed edge case where API Key\r\nis added to URL with no query string.","assignee":null,"id":1476877,"number":6,"pull_request":{"patch_url":"https://github.com/mashery/iodocs/pull/6.patch","html_url":"https://github.com/mashery/iodocs/pull/6","diff_url":"https://github.com/mashery/iodocs/pull/6.diff"},"labels":[],"title":"Issue #3++","html_url":"https://github.com/mashery/iodocs/issues/6","closed_at":null,"url":"https://api.github.com/repos/mashery/iodocs/issues/6","milestone":null},"action":"created","comment":{"created_at":"2011-12-06T01:58:10Z","updated_at":"2011-12-06T01:58:10Z","user":{"gravatar_id":"703c2eaf093a7caf1008362209d2903e","id":161071,"url":"https://api.github.com/users/jasonmccreary","login":"jasonmccreary","avatar_url":"https://secure.gravatar.com/avatar/703c2eaf093a7caf1008362209d2903e?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png"},"body":"There is also a bug in the PUT/POST when appending the apiKey. You did not update the Content-Length header.\r\n\r\n    options.headers[\"Content-Length\"] = Buffer.byteLength(options.body);\r\n\r\nI did not check this for the OAuth path. But it should not be a problem there since the apiKey is used in a different capacity.\r\n\r\nOtherwise, excellent addition. I'm surprised the original ever ran successfully for requests with only the API Key. It never did for me or any of the sample APIs.","id":3027048,"url":"https://api.github.com/repos/mashery/iodocs/issues/comments/3027048"}}