diff --git a/CODEOWNERS b/CODEOWNERS index 5685aa6e9..37f8a98b8 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -67,7 +67,7 @@ lexicon/providers/ovh.py @adferrand lexicon/providers/plesk.py @ctron lexicon/providers/pointhq.py @analogj lexicon/providers/powerdns.py @insertjokehere @splashx -lexicon/providers/rackspace.py @rmarscher +lexicon/providers/rackspace.py @rmarscher @mattgauf lexicon/providers/rage4.py @analogj lexicon/providers/rcodezero.py @MikeAT lexicon/providers/route53.py @eadmundo diff --git a/lexicon/providers/rackspace.py b/lexicon/providers/rackspace.py index 2933ffce3..0abc9101f 100644 --- a/lexicon/providers/rackspace.py +++ b/lexicon/providers/rackspace.py @@ -206,11 +206,12 @@ def _request(self, action="GET", url="/", data=None, query_params=None): full_url = ( f"{self.api_endpoint}/{self._get_rackspace_option('auth_account')}{url}" ) + # For data= argument, use None value for GET requests to comply with Rackspace API response = requests.request( action, full_url, params=query_params, - data=json.dumps(data), + data=json.dumps(data) if action != "GET" else None, headers={ "X-Auth-Token": self._get_rackspace_option("auth_token"), "Content-Type": "application/json",