Hello everyone
Does anyone have experience creating a connector using the Brandwatch API?
I would love to hear about that.
Thanks in advance
Rodrigo
Solved! Go to Solution.
This article series may help. See here
Thanks, that's very helpful.
I hope someday Alteryx can provide some sort of training on building those tools... I am one that learns more by seeing others doing and replicating. Starting from scratch is a hassle.
Rodrigo
@calloni I drafted up an APIs for Beginners article that I'm hoping to have reviewed and published soon for the Alteryx Community that covers all different kinds of configurations and approaches.
For Brandwatch, the first step is finding their API documentation which is located here: https://developers.brandwatch.com/docs/getting-started
Within the documentation, you will see that it has an Authentication endpoint which you will want to use a download tool to do a POST request to the endpoint to return back a token: https://developers.brandwatch.com/docs/authenticate
This token will then be used in the headers of a download tool for a subsequent call to the next API endpoint of your choosing. Hopefully that gets you started!
@calloni , there is a recording of a training session called Intro to REST APIs
See here for the recording.
There is a sample workflow and pdf on that page.
FWIW, I used the recording sample and my specific API documentation to build a connection.
After finding the other item I posted, I was able to successfully make a connection and get data from the site.
I did learn that my data had multiple pages, so I had to create an iterative macro to get all the data. That information is in the series.
One item to note is that after getting the authorization key, I had to concat the text "bearer" to the key so it would be in the format required for the API.
I think yours will be the same.
I did see that your API key is good for 1 year, so you could do 2 workflows - 1 for the key and the other for the data you want.
Below is a screenshot. Maybe it will help. I am getting a 401 Unathorized error at the moment, so I can't give more details.
Hi Brandon
Thanks for the reply. I saw the documentation and the video but I am finding a hard time to reproduce this curl command in downloads tool:
curl -X POST --data-urlencode 'password=[yourpassword]' \
'https://api.brandwatch.com/oauth/token?username=[your@username.com]&grant_type=api-password&client_i...'
I wanted to have a text input tool where I would put these varialbes:
- yourpassword
- api-password
- brandwatch-api-client
But I don't even know where to put these:
--data-urlencode
'https://api.brandwatch.com/oauth/token?username=
Would it be possible to mock these up in a workflow and share it with me?
Thanks
Rodrigo
Can you give this a try? Put your email username in the text input where I have the dummy value and update the password in the Payload tab. If it is successful you should see a token return in the DownloadData column. I'm getting an auth error because I don't have Brandwatch credentials of my own. Workflow attached
I am definitely NOT an expert.
@BrandonB , I think you have too much in the URL field. The items after the question mark should be other fields.
@calloni , I tried to mock up some examples. The query is for Total Mentions from the developers page. None of these will successfully run until more information is provided to the fields.
Workflow:
Text input with all fields for Authorization
Manually entered fields for Authorization Payload
Text input fields for Total Mentions query
Payload for Total Mentions query
Ohhhh so I pick that URL and build it before sending to download tool.
I will work on this as soon as I get my credentials in Brandwatch
Thanks a bunch
Rodrigo