code: function postRequest(url, payload, params, callback) {
      var options = urllib.parse(url),
          finished = false,
          response = null,
          req;
  
      options.method = 'POST';
  
      /**
       * Cleanup all the event listeners registered on the request, and ensure that *callback* is only called one time
       *
       * @note passes all the arguments passed to this function to *callback*
       */
      var cleanupAndCallback = function() {
          if (finished === true) {
              return;
          }
          finished = true;
          req.removeAllListeners();
          if (response !== null) {
              response.removeAllListeners();
          }
          callback.apply(null, arguments);
      };
  
      req = (options.protocol === 'https:' ? https : http).request(options, function(res) {
          response = res;
          var data = [];
          var datalen = 0;
  
          res.on('data', function(chunk) {
              data.push(chunk);
              datalen += chunk.length;
          });
  
          res.on('end', function() {
              return cleanupAndCallback(null, res, Buffer.concat(data, datalen));
          });
  
          res.on('error', function(err) {
              return cleanupAndCallback(err);
          });
      });
  
      req.on('error', function(err) {
          return cleanupAndCallback(err);
      });
  
      if (payload) {
          req.setHeader('Content-Type', 'application/x-www-form-urlencoded');
          req.setHeader('Content-Length', typeof payload === 'string' ? Buffer.byteLength(payload) : payload.length);
      }
  
      for (var customHeaderName in params.customHeaders) {
        req.setHeader(customHeaderName, params.customHeaders[customHeaderName]);
      }
  
      req.end(payload);
  }
docs: Custom POST request handler.
  This is only needed to keep paths short in Windows – usually this module
  is a dependency of a dependency and if it tries to require something
  like the request module the paths get way too long to handle for Windows.
  As we do only a simple POST request we do not actually require complicated
  logic support (no redirects, no nothing) anyway.
  
  @param {String} url Url to POST to
  @param {String|Buffer} payload Payload to POST
  @param {Function} callback Callback function with (err, buff)