Fix the SQL API URL in MM (#3111) (#156)

Signed-off-by: Modular Magician <magic-modules@google.com>
This commit is contained in:
The Magician 2020-02-11 12:35:42 -08:00 committed by GitHub
parent caae08275f
commit e17ffe42fb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 12 additions and 12 deletions

View file

@ -856,11 +856,11 @@ def fetch_resource(module, link, kind, allow_not_found=True):
def self_link(module):
return "https://sqladmin.googleapis.com/v1beta4/projects/{project}/instances/{name}".format(**module.params)
return "https://sqladmin.googleapis.com/sql/v1beta4/projects/{project}/instances/{name}".format(**module.params)
def collection(module):
return "https://sqladmin.googleapis.com/v1beta4/projects/{project}/instances".format(**module.params)
return "https://sqladmin.googleapis.com/sql/v1beta4/projects/{project}/instances".format(**module.params)
def return_if_object(module, response, kind, allow_not_found=False):
@ -930,7 +930,7 @@ def response_to_hash(module, response):
def async_op_url(module, extra_data=None):
if extra_data is None:
extra_data = {}
url = "https://sqladmin.googleapis.com/v1beta4/projects/{project}/operations/{op_id}"
url = "https://sqladmin.googleapis.com/sql/v1beta4/projects/{project}/operations/{op_id}"
combined = extra_data.copy()
combined.update(module.params)
return url.format(**combined)