How to Add Managed OAuth 2.0 Apps for Trustpilot API and Refresh Tokens Every 4 Days?

So I think I missed out adding your api.pipedream.com host to the redirect URI allow list

Done that

Now getting this

Ok cool I should have a record of that error, hang on

Exception:
401 "Unauthorized"
Received 401 from the test request:
https://api.trustpilot.com/v1/business-units/all
Decoded error:
{"fault":{"faultstring":"Invalid ApiKey","detail":{"errorcode":"oauth.v2.InvalidApiKey"}}}

Looks like a bad API Key

Specifically though, it seems like the auth portion of the OAuth flow may have actually worked though, and it failed when making the test request to that endpoint.

Some suggestions for your connection step copy:

• Mention that the API will only work if the user used to authenticate does NOT have two factor auth enabled
• Clarify the Redirect URI instruction. The hostname needs to be added in the Trustpilot app settings, not the whole URI, and they don’t prompt you as part of the initial auth flow, it’s when you create the app

Yes that’s great, thank you

Adding now

Hmm

The API key is definitely correct

Can you try again?

I removed the requirement to make the test request at the end, to remove the variables. So now you should only be going through the OAuth flow

If you’re testing an API call with https://api.trustpilot.com/v1/business-units/all, that’s a different type of authentication, you realise that?

Part of our standard OAuth implementation includes making a test request as a last part of the flow, so if that request fails, the whole flow fails. I just removed that step.

Yeah, but that test isn’t actually a fair test of the authentication type we’re trying to set up

That API call (https://api.trustpilot.com/v1/business-units/all) only requires an API key and that’s it, no OAuth.

Ah, noted, thanks

So some endpoints just require a key and no access token?