I am rebuilding some APIs using the new Access Token and @hubspot/api-client for Node.JS
The connection and calls work fine however, on the response side, I get the message correctly but how do I access the response headers?
I need to know if the headers are accessible and if X-HubSpot-RateLimit-Remaining, is featured in the headers.
I cannot find any documentation on this at all for the Wrapped APIs and the only community posts said it worked on Postman. I am using NodeJs and as such need it to be accessible here.
I would like to advise you to use Axios, as it gives you much more control on how the data is being send, but also accessing the response data. Here is quick example using Axios:
I am aware of Axios and looks like I am needing to use it for the Association APIs.
My question now becomes, why offer these Wrapped APIs if the limit needs to be managed but is not supplied and other services such as Axios and HTTPS are better equiped?
I decided to use the Wrapped APIs for a longer term solution where it would update the API used instead of changing all the URLs from potential legacy ones.
Are Wrapped APIs not ideal and should be scrapped in favour of other tools?