HERE.com Usage API - connection problems

Hi All

Assuming I use the HTTP Request node, could anyone advise how I could determine my usage ‘by my organization’ through the HERE.com Usage API. The documents are at here but for the life of me I cant seem to get it to work.

My last shot at it looked like the image below, but I’ve even tried the GET request to https://usage.bam.api.here.com/v2/usage/realms/orgXXXXXX and that does’t appear to work either.

I’m also using ‘Header Auth’ with the api password.

I feel like it’s something very basic that I’m messing up in the node.

Any help or advice would be greatly appreciated.

Thanks

Stephen

Hi @spessex

You are filling in a query parameter, this isn’t the same as the URL you are sending.
what you get with this what you have now is this: /usage?realms:orgXXXX

1 Like

Many thanks @BramKn for your feedback. I’ve made the requisite change and from the new response code now believe it’s an issue with Oath.

In respect of Oauth2 n8n requires both a ‘Authorization URL’ and a ‘Access Token URL’. Which of these would be ‘https://account.api.here.com/oauth2/token’ provided by HERE.com? And then, what is the other URL they are requesting? The only details HERE.com provide for Oauth2 are User ID, Client ID, Access Key ID, Access Key Secret, and Token Endpoint URL.

I’m losing the will to live on this one :wink: @MutedJam can your genius provide any insight on this? :slight_smile:

The main thing I cant understand now is why the HERE.com service is stating the ‘client id’ and ‘client secret’ fields are missing even though they are specified in the OAuth2 API.

See all relevant screenshots.

Any help would be greatly appreciated.

PS I’ve tried both GET and POST but I doubt this is the issue as it returns the same response code.



Hi @spessex

Your authentication steps arent completed I guess.
Had a quick look at their docs, it doesn’t look like “normal” Oauth2. So it would need some messing arround to get it to work, might not be as easy as adding the credentials as Oauth2 in n8n. You might need to do it manually. Not sure though.

1 Like

Thanks @BramKn. So when you say ‘manually’ do you mean outside of n8n or is there some kind of manual node available in n8n to do more complicated workarounds?

What happens if you set the authentication to body?

Unfortunately that doesnt seem to work either @Jon as it’s actually now stating "
“errorCode”:
401200,
“message”:
“Missing Authorization header.”,"

I guess it does need to be a header then :thinking: I will need to take a proper look at their docs to see what is missing.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.