Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Anonymous
Not applicable

Connecting to an API....

Hello Everyone,

I am currently trying to connect via API to the Knowbe4 platform however I am getting authorization issues. I keep getting access denied and it will not accept my API token.

Can anyone help?

Here is the link to the information they provide for the setup: https://developer.knowbe4.com/reporting/#tag/Authentication

 

 

8 REPLIES 8
jbenson
Helper III
Helper III

I am also having problems getting know b4 data to flow to power bi. Did anyone get their know b4 power bi issue resolved?

MattPennerVV
Regular Visitor

Hi @Anonymous,

I just created a Power BI report against KnowBe4 for one of our recent campaigns. I had much the same questions as I had not done this before and came across your post when I was searching for answers.

 

First off, when you enable the Reporting API in your Account Settings ensure you scroll all the way down and hit the save button.  Some of their site settings save immediatley when you click on them and others you have to specifically click the save button.  When I first enabled the API I was getting not authorized errors like you.  I then scrolled all the way down (it's a long way) and saw a Save button.  When I clicked that within a few seconds I started getting results.

 

To get the data I used the Web source.  Enter the following:

MattPennerVV_0-1623204546921.png

  1. Click on the Advanced option
  2. In the URL Parts textbox enter the desired URL from the KnowBe4 API. Make sure to use https and not http otherwise KnowBe4 will reject it
  3. In the HTTP request header parameters section, in the left textbox enter "Authorization"
  4. In the right textbox enter "Bearer APIToken" , substituting your KnowBe4 API Token.  Ensure there is a space between Bearer and your token.

That's it.  When you click OK you should start seeing data come in. 

 

Hope that helps.

Appreciate that this is old but thanks for this. Been struggling with this and this was the clearest and easiest instruction I've used that worked!
Though will add that when it prompts for credentials, to use "Anonymous" and resist the urge of using the API option. 


Please note - I am not affiliated with Microsoft, I'm just an end user like yourself.
Just a regular guy doin' Data Science.

If my post has helped you, please don't forget to thumbs up or click "Accept as solution" if it solved your problem!
parry2k
Super User
Super User

@Anonymous try something like this and then add the next steps.

 

let
        #"API Key" = "your api key",
        Source = Json.Document( Web.Contents("http://your url", 
        [
            Headers = [Bearer = #"API Key"]
        ]))
in 
      Source

 

 



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

mahoneypat
Microsoft Employee
Microsoft Employee

Can you share your M code (with a modified token, of course)?  Did you include "Bearer " in your Authentication record?

Regards,

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


rlufcy1
New Member

I am having the same issue. There is no instructions for PowerBI from KnowBe4. Any help would be appreciated. 

parry2k
Super User
Super User

@Anonymous do you have your access token from them?



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Anonymous
Not applicable

Yep I have the access token from them but when I try to add it in the authorization says it has failed.

Helpful resources

Announcements
Sept PBI Carousel

Power BI Monthly Update - September 2024

Check out the September 2024 Power BI update to learn about new features.

September Hackathon Carousel

Microsoft Fabric & AI Learning Hackathon

Learn from experts, get hands-on experience, and win awesome prizes.

Sept NL Carousel

Fabric Community Update - September 2024

Find out what's new and trending in the Fabric Community.

Top Kudoed Authors