JSON No Code Connector - Base64 Encode and Basic Authentication?
Hi All,
Does anyone know how to use the JSON No Code (or any of the JSON connectors, really) to do basic authentication via a client id and secret where the client id/secret are base64 encoded?
Based on the API documentation, I need to pass the following header where the client id:secret string is base64 encoded.
Authorization: Basic <client id:secret>
So what I did was take the client id:secret string, and ran it through base64encode.org so I ended up with the following:
However, when I try to get a preview, I get the following error:
When I do my own manual curl request via command line, I get back data. So I'm not sure if I'm leveraging the JSON connector correctly. Any help would be greatly appreciated.
Answers
-
Is that word "Basic" supposed to be in the authentication value? That doesn't look like part of the base 64 string.
** Was this post helpful? Click Agree or Like below. **
** Did this solve your problem? Accept it as a solution! **0 -
@ArborRose according to their python API sample, it should be "Authorization: Basic <base64 encoded id:secret>
Looking at cURL documentation, this is the correct and expected way to specify basic authentication in a header:
curl \ --header "Content-Type: application/json" \ --header "Authorization: Basic $AUTH" \
So in theory, what I have setup in the json no code connector should work.
0 -
Here's the way I do it in Python. In your comments, you use "Authentication". But in both of our code examples, we're showing "Authorization".
** Was this post helpful? Click Agree or Like below. **
** Did this solve your problem? Accept it as a solution! **0 -
@ArborRose - I caught that and changed it right after posting. Still getting the same result. Looking at the network inspector what I seem to be getting back during the preview is an internal server 500 error from domo went it tries to execute the curl command.
Starting to think I need to go back to the client and see if maybe the way they set things up for my auth is incorrect or something. I'll keep messing with it.
Thanks for the help!
0
Categories
- All Categories
- 1.8K Product Ideas
- 1.8K Ideas Exchange
- 1.5K Connect
- 1.2K Connectors
- 300 Workbench
- 6 Cloud Amplifier
- 8 Federated
- 2.9K Transform
- 100 SQL DataFlows
- 616 Datasets
- 2.2K Magic ETL
- 3.9K Visualize
- 2.5K Charting
- 738 Beast Mode
- 57 App Studio
- 40 Variables
- 685 Automate
- 176 Apps
- 452 APIs & Domo Developer
- 47 Workflows
- 10 DomoAI
- 36 Predict
- 15 Jupyter Workspaces
- 21 R & Python Tiles
- 394 Distribute
- 113 Domo Everywhere
- 275 Scheduled Reports
- 6 Software Integrations
- 124 Manage
- 121 Governance & Security
- 8 Domo Community Gallery
- 38 Product Releases
- 10 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 108 Community Announcements
- 4.8K Archive