cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1641
Views
0
Helpful
4
Replies

generate API token fails

Ionut T
Level 1
Level 1

Hi, 

 

I am trying to generate the EOX API token using valid client_id and client_secret.

 

url_token='https://cloudsso.cisco.com/as/token.oauth2'

headers = {'Content-type': 'application/x-www-form-urlencoded'}

params = {
'grant_type': 'client_credentials',
'client_id': client_id,
'client_secret': client_secret,
}
response = requests.post(url_token,
headers=headers,
params=params,
timeout=10)
print(response.json())

 

But it fails with this error:
 
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 401 Client Error: Unauthorized for url: https://cloudsso.cisco.com/as/token.oauth2? grant_type=client_credentials&client_id=<MY_CLIENT_ID>&client_secret=<MY_CLIENT_SECRET>&content-Type=application%2Fx-www-form-urlencoded
 
I have followed this documentation: 

 

Can you please let me know what I am doing wrong ?

Thank you

 

 

4 Replies 4

madhushr
Cisco Employee
Cisco Employee

Hi,

 

Let us check on the details and get back to you on this.

 

Thanks and Regards,

Madhusha R

madhushr
Cisco Employee
Cisco Employee

Hi,

 

Could you please confirm if this is Support APIs or SNTC APIs.

 

Thanks and Regards,

Madhusha R

Hello Madhusha,

 

How can I figure out if this is a Support or SNTC APIs ? 

The only information I have is from here  https://apiconsole.cisco.com/

EOX V5 API  

https://developer.cisco.com/docs/support-apis/#!eox/eoxrecordtype

 

Thank you,

Ionut

Hi,

 

It seems to be Support APIs. Hence we request you to drop the mail to the mail ID-help(mailer list) supportapis-help@cisco.com for further troubleshooting.

 

Thanks and Regards,

Madhusha R

 

 

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: