Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Adobe Summit is happening now. Discover what's next in customer experience.

PhotoShop API Error

Avatar

Level 1

Hello


I have created project for Adobe Photoshop API (Trial)

 

I have JWT token 

I am able to generate Bearer AccessToken properly. Following is the code :

var client = new RestClient("https://image.adobe.io/lrService/edit");
var request = new RestRequest(Method.POST);
request.AddHeader("cache-control", "no-cache");
request.AddHeader("Authorization", bearertoken);
request.AddHeader("x-api-key", ApiKey);
request.AddHeader("Content-Type", "application/json");
request.Parameters.Clear();

string data = "{\"inputs\": {\"source\": {\"href\": \"unedited/image.jpg\",\"storage\": \"external\"}},\"options\": {\"Whites\": 80},\"outputs\": [{\"href\": \"edited/image.jpg\",\"type\": \"image/jpeg\",\"storage\": \"external\"}]}";

request.AddParameter("application/json", data, ParameterType.RequestBody);

string responseFromServer = "";
IRestResponse response = client.Execute(request);
responseFromServer = response.Content;


I am getting response as :
{"error_code":"401013","message":"Oauth token is not valid"}


Please help me out with this error, how I can resolve it please advise.

 

thanks

0 Replies

The ultimate experience is back.

Join us in Vegas to build skills, learn from the world's top brands, and be inspired.

Register Now