I am trying to create a monitoring service for Xing. When I try to get de access token with the following request:
consumer = oauth2.Consumer(app_key, app_secret)
client = oauth2.Client(consumer)
...
params = {
"client_id": app_key,
"client_secret": app_secret,
"redirect_uri": app_callback_url,
"code": code,
"grant_type": "authorization_code",
}
_, content = client.request(access_token_url, "POST", body=urllib.parse.urlencode(params))
I get the following response:
{'error': 'invalid_client', 'error_description': 'Client {CLIENT_ID} not found or disabled', 'error_detail_key': 'E20109', 'error_uri': 'https://dev.xing.com/docs/error_responses'}
How can I fix it?
I fixed it by removing the "client_secret" from the parameters and adding the "code_verifier"