I follow up on this doc to generate tokens via API but I didn't receive any response from the server.
https://docs.appdynamics.com/appd/4.5.x/en/extend-appdynamics/appdynamics-apis/api-clients#APIClient...
the curl like below:
curl -X POST -H "Content-Type: application/vnd.appd.cntrl+protobuf;v=1" "https://(accountName).saas.appdynamics.com/controller/api/oauth/access_token" -d 'grant_type=client_credentials&client_id=(username)@(accountName)&client_secret=(clientsecret)'
Please help me!
@Tran.Vinh, I spoke to our engineer again, and his last suggestion was to make sure your client secret was correct as well, even if that means generating a new one. If that doesn't work, please go to https://help.appdynamics.com/hc/en-us/requests and file a ticket, so our customer support team will look into it. I'd also make sure that the client name and account name don't have any trailing spaces. I hope regenerating a client secret helps, but if not, I'm sorry I couldn't help you.
Hi @Tran.Vinh,
I'm also trying to figure this out. I'll report back when I get an answer.
@Mario.Morelli
Sorry If I interrupt you but could you confirm for me about the trials controller can not get tokens via API? If you can not so Can you please give me the contact of people who can answer my question above?
Thanks.
I tried on another Linux machine but I still got the same situation.
Our company considering to use appDynamic as a monitoring server for our application and we would like to have a way to get the token dynamically via API so you can help me confirm that the trial controller can not use this feature.
I would possibly try the request on another machine, I see you have a Macbook. Can you check another Linux machine?
Or it might be a limit on using the API Client when it's a trial controller, I would suggest to log a case to AppDynamics support to check if this is the case, as your request is correct, I have used your exact call, and replaced with my own details and it works.
Hi Tran
Your syntax is 100% correct, is this a trial controller?
yes, this is the trial controller and the syntax is correct.
this is the response after changed
After changing clientId = clientName of my API client but I still cannot get the response from the server.
If you get no response, something is wrong with one of the 3 below
client_id, accountname or client secret
Can you double check, that under Administration that the Client Id for the API Client is correct, account name of your controller, as well as the secret(All Case sensitive)
Just validating that the client_id value is the Client Name value that you have created for the API Client, not the username that you login to AppD with.
Ciao
Hi Mario,
Nothing response 😞
Hi Tran
Can you share a screenshot of what response you get from the terminal when running the POST command(Just hide sensitive data).
Thanks