diff --git a/lib/api.js b/lib/api.js
index <HASH>..<HASH> 100644
--- a/lib/api.js
+++ b/lib/api.js
@@ -1,7 +1,8 @@
 /**
  * Helper "class" for accessing MediaWiki API and handling cookie-based session
  */
-	var VERSION = '0.3.5';
+module.exports = (function() {
+	var VERSION = '0.3.6';
 
 	// @see https://github.com/mikeal/request
 	var request = require('request');
@@ -104,15 +105,21 @@
 			port: this.port,
 			hostname: this.server,
 			pathname: this.path + '/api.php',
-			query: params
+			query: (options.method === 'GET') ? params : {}
 		});
 
+		// POST all parameters (avoid "request string too long" errors)
+		if (method === 'POST') {
+			options.form = params;
+		}
+
 		request(options, function(error, response, body) {
 			if (error) {
 				throw 'Request to API failed: ' + error;
 			}
 
 			if (response.statusCode !== 200) {
+				console.log(new Error().stack);
 				throw 'Request to API failed: HTTP status code was ' + response.statusCode;
 			}
 
@@ -246,4 +253,5 @@
 		}
 	};
 
-	module.exports = api;
+	return api;
+}());
api.js:

* fix for huge POST requests (make sure data is POSTed, not encoded in URL)
* wrap module in immediate function
* <I>