Bearer 401 Authentication Error in http module

Help, I am getting a 401 {“error_message”:“Authorization header with scheme ‘Bearer’ required”} even though I have the bearer api key in the box. The API code is coming directly from Retellai.com and is correct and there are no “Bearer key_feb5c898dr8e8b2f50ba54071118” (fake aoi key).

Very frustrating since I have used the exact same setup successfully in other scenarios without any issues. I tried recreating it multiple times and they all say the same thing. Anyone have a suggestion?

1 Like

Hey @David_Oziel

You have to pass the authorization in following way:

BearerYour API key

Regards,
Msquare Automation - Platinum Partner of Make
@Msquare_Automation

I removed the extra space and I am still getting the same error message. :sob:

Hi @David_Oziel,

Could you share a screenshot showing the configuration of the module? Community members might then be able to spot an issue.

Regards, Terry.

This is what I keep getting. I know I put in the right API Key because I have used it many times before.

Does anyone know why this is happening? :confounded:

Hi everyone,
Exact same issue here, any suggestions?
My API token works with postman or via curl.

Are you saying I should use Postman via cURL to make this work? If so, how do I do that? I want to use GoHighLevel to launch the campaign but the HTTP won’t recognize my API. :cry:

Hi @David_Oziel,

I can see you’re using a “Basic Auth” key and have also added a Bearer token. These are two different authentication methods.

  1. You could either use the “Make an API Key Auth request” HTTP module, and let Make store your API key (you won’t then need to add headers at all),
    OR
  2. Use the “Make a request” HTTP module, and add your own Authorization headers. Make will then not ask you to create a connection.

I personally usually use the “Make a request” HTTP module, this gives me the most control over what gets sent to my APIs.

Regards, Terry.

Hi @David_Oziel
I’m saying my API token works in other platforms.

All right, Terry, let me try this and I will report back. :grinning:

Hey Terry, that worked! thanks! Now I am having trouble getting the “to_number” recognize my number. I am getting an “400” error code because of the format of the number not being e.164.

I appreciate your help with this issue though.

Thanks again!

1 Like

Hi @David_Oziel,

That’s excellent. I’m glad it worked.

Please can you mark my answer as the solution, so that other users can quickly find the answer if they have the same problem. Currently you’ve marked your own reply as the solution!

Regards, Terry.

Hi @Admin_Drouet,

Did you try using the “Make a request” HTTP module, like in this answer:

Regards, Terry.