OAuth2.0 Endpoint for ASDK

Matt Davison 26 Reputation points
2020-06-15T17:42:49.25+00:00

Hi,

I am trying to write a REST API call to download my Key Vault secrets using a bash script. I am having an issue with making a HTTP POST request to get the Access Token to gain access to the Key Vault resource. The endpoint I am using to get the Access Token is "https://login.microsoftonline.com/<TenantID>/oauth2/token", but I am getting an error response that it cannot find my Tenant ID. Im assuming this is because I am using ASDK and not a full Azure Stack Hub? Which endpoint uri should I be making my POST request to get my access token? If anyone has any documentation on this for ASDK that would be really helpful.

Thanks,

Matt

Azure Stack Hub
Azure Stack Hub
An extension of Azure for running apps in an on-premises environment and delivering Azure services in a datacenter.
189 questions
0 comments No comments
{count} vote

1 answer

Sort by: Most helpful
  1. TravisCragg-MSFT 5,681 Reputation points Microsoft Employee
    2020-06-25T19:55:28.493+00:00

    Here is a great doc that outlines this process for Azure Stack Hub. When Using the ASDK, it is a slightly different management endpoint, and is called out directly in the doc.

    Using Azure Stack vs the ASDK should not make a difference here, just make sure that you are using an tenant ID that Azure is aware of.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.