Sign up to take part
Registered users can ask their own questions, contribute to discussions, and be part of the Community!
Is it possible to use the dataiku API to set the details of a " Salesforce login with Username-password" preset?
Thanks in advance.
you can indeed use the Dataiku Python API to set a plugin settings if you have the appropriate authorizations. You can find more information about it here : https://doc.dataiku.com/dss/latest/python-api/plugins.html#handling-settings
To modify the sales force settings you can probably use the following code
import dataiku client = dataiku.api_client() plugin = client.get_plugin("salesforce") # Obtain the current settings settings = plugin.get_settings() raw_settings = settings.get_raw() # Modify the settings (in your case presets) raw_settings['presets'] = [...] # And save them back settings.save()
Hope this helps !
Thanks for that.
I'm particularly interested in setting the password programmatically (i.e. fetching the password from central safe storage and inserting it in the connection with no human involvement). How would that play out here? E.g. If the system over-writes the value of password in the 'config' dict with with the plain text fetched from the central sore, will it get encrypted by DSS?.
Yes, if you modify the config via the API all secret fields are encrypted internally by DSS the same way they are when you save it manually from the UI.
You can test that by changing the password via the API and fetching the settings again. The password field is encrypted in the response.