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.6K Connect
- 1.2K Connectors
- 300 Workbench
- 6 Cloud Amplifier
- 9 Federated
- 2.9K Transform
- 102 SQL DataFlows
- 626 Datasets
- 2.2K Magic ETL
- 3.9K Visualize
- 2.5K Charting
- 754 Beast Mode
- 61 App Studio
- 41 Variables
- 693 Automate
- 178 Apps
- 456 APIs & Domo Developer
- 49 Workflows
- 10 DomoAI
- 38 Predict
- 16 Jupyter Workspaces
- 22 R & Python Tiles
- 398 Distribute
- 115 Domo Everywhere
- 276 Scheduled Reports
- 7 Software Integrations
- 130 Manage
- 127 Governance & Security
- 8 Domo Community Gallery
- 38 Product Releases
- 11 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 110 Community Announcements
- 4.8K Archive