protected Map<String, String> getParams(ApiRequest request) {
		Map<String, String> result = new HashMap<String, String>();
		result.put("version", Integer.toString(request.getVersion()));
		ApiAuth<?> auth = request.getAuth();
		if (auth != null)
			result.putAll(auth.getParams());
		Map<String, String> params = request.getParams();
		if (params != null) {
			result.putAll(params);
		}
		return result;
	}