Free Support Forum - aspose.cloud

Asposehtmlcloud NodeJS package cannot authenticate any requests


#1

Hi,

The asposehtmlcloud package does not seem to be usable because it is unable to complete the authentication flow to get a bearer token.

It appears this was broken in this commit https://github.com/aspose-html-cloud/aspose-html-cloud-nodejs/commit/c6310739f0d55ba7441e2d6b0178952c94ed6060#diff-412eda8bdcccd6b1a45c25c9647614d1R125

Strings here are immutable and concatenating strings does not maintain a reference to the component strings, which means the logic there does not work. Although this.accessToken is updated with the bearer token, this.defaultHeaders.Authorization is not updated because it has no reference to this.accessToken.

The impact of this is that all API requests are made with an Authorization header of Bearer undefined and therefore they return an error.


#2

@RBIEGTechTeam

Thanks for your inquiry. We have logged a ticket HTMLCLOUD-1231 for further investigation and rectification. We will notify you as soon as it is resolved.


#3

@RBIEGTechTeam

Thanks for your patience. Please note, your reported issue has fixed in Aspose.HTML Cloud SDK for Node.js. It should work now. Please feel free to contact us for any further assistance.