How to authenticate web API Requests with Token using Aspose.PDF REST API

After I’ve generated an access token through the endpoint “/oauth2/token”, I tried to upload a file (“/pdf/storage/file/”) but got this error: “AppSid is undefined. Please check authorization.”

I’m using the generated access token as a bearer token in the header, just like the documentation states: Authenticating API Requests|Documentation

Just a heads up. When I use the access token generated by the API reference (Aspose.Pdf Cloud - API References) it works.

My access token request might be missing something, like a scope.

Well… got it. Wrong authorization endpoint. The correct one was https://api.aspose.cloud/connect/token. Documentation might need a revision.

@luizrocha

Thanks for your query and good to know that you have managed to resolve the issue.

We have recently released V3 version of Aspose.PDF Cloud and it is using JWT(JSON Web Token). We have updated the documentation examples and will fix “Overview of Aspose Cloud REST API” page to avoid any further confusion.