Closed Trazzmonger closed 1 month ago
I was able to resolve this issue by adding the following additional code:
const string proxyAddress = "http://proxy.jpmchase.net:8443";
...and then changing this existing code:
var client = new RestClient("https://ims-na1.adobelogin.com/ims/exchange/jwt/");
...to this instead:
var client = new RestClient("https://ims-na1.adobelogin.com/ims/exchange/jwt/") { Proxy = new WebProxy(proxyAddress) };
Since most companies (and surely all large companies) have a proxy server, I strongly recommend you add such code to your sample code (after changing the JPMC-specific proxy server address to something generic, obviously).
Hello, seems like this issue relates to sample code provided for the deprecated Service Account (JWT) credentials. We are no longer enhancing the documentation surrounding the deprecated credentials.
Expected Behaviour
The sample code is supposed to build a JWT object and then pass it in an Adobe API call to get back an "access token".
Actual Behaviour
Such API calls are failing with a response.ErrorMessage of "The remote server returned an error: (407) Proxy Authentication Required."
However, from that error message, I can't tell if the "remote server" is referring to the ims-na1.adobelogin.com site (to which I'm sending the request) or if it's referring to some proxy server of my own company (which might be blocking the request before it even leaves my company's internal network).
Reproduce Scenario (including but not limited to)
Use the sample code to make the API call. NOTE: I successfully get an Access Token when I copy-paste my Adobe API Project's private key into the GUI box provided for such testing at https://developer.adobe.com/console/projects/374378/4566206088344859311/apis/AdobeIOManagementAPISDK/details.
Steps to Reproduce
Platform and Version
Windows 10 running Microsoft Visual Studio 2019.
Sample Code that illustrates the problem
Current code leveraging an older version of the RestSharp library (e.g., v106.13.0).
Logs taken while reproducing problem
n/a