Added support for api version and region parameters.