Added new API initialization method that allows the user to pass in the server configuration