Welcome to the Alteryx Knowledge Base
Created/Edited -
Below is a step-by-step to set up Azure Key Vault as an external vault in Alteryx, using DCM Generic External Vault. Note that Azure Key Vault isn’t a built-in External Vault option in DCM.
Important: This is a proof of concept example only. Although the python code sample below could be copy/pasted into your solution, modification and assistance with custom code is out side of Support scope
Please reach out to your Accounts Team to discuss Professional Services Entitlements to assist with this solution.
Alteryx Designer
Alteryx Server
Azure setup (Key Vault + App Registration)
Create your key vault and add the secret(s) you want Alteryx to use (for example: user name, password).
Create an app registration (Service Principal) in Entra ID (Azure AD) and generate a Client Secret (you’ll use this for authentication from the Alteryx Generic Vault script).
Give required app permission to read secrets from the Key Vault using one of these access models:
-
- If your Key Vault uses Azure RBAC: assign the app the Key Vault Secrets User role (or equivalent least-privilege role for reading secrets).
If your Key Vault uses Vault access policy: grant Secret Get/List permissions to the app.
Add role assignment to the user "service principal" to the Key Vault.
You should now have:
- Tenant ID (Get from the App registration overview page of the service principal)
- Client ID (Get from the App registration overview page of the service principal)
Client Secret (Get the Value from the Certificates & Secrets page ).
Key Vault URL “https://mysql-test.vault.azure.net/”
Create the "Generic Vault" script / executable
DCM Generic Vault works by calling your executable/script and passing parameters like:
- Vault Path
- Value ID
- Vault credential username/password
…and it expects your script to return the secret as plain text.
Build a Script or Executable
Before building a script, it’s good to understand how DCM retrieves secrets from the vault. When executing a workflow using a DCM connection with secrets stored in the vault, one request is sent to the vault for each secret. For example, if you’re storing both your username and password in the vault, one “fetch secret” request will be sent for the username and another for the password. Each request then contains authentication if the vault is set so. Create a python script to extract the credentials from Azure key vault. In this example, a script called "dcm_azure_keyvault.py" was created. Verify the code below. This code should be placed in C:\Data\python directory.
Install Azure Identities
pip install azure-identity azure-keyvault secrets.
Enable DCM + Generic Vaults (Designer and/or Server)
If using Alteryx Server:
- Open Alteryx System Settings → DCM
- Enable DCM
- Check Enable Generic Vaults
If using Alteryx Designer
- Go to Options → User Settings → Edit User Settings → DCM
- Enable DCM (and ensure access mode allows the connections you need—some environments require “Allow All”).
Add the External Vault in DCM (Generic Vault)
In Designer
- File → Manage Connections
- Go to External Vaults
- Click + New
- Choose Technology = Generic
- Fill in:
- Vault name: e.g.,
AzureKeyVault-Prod - URL: your Key Vault URL (or any valid URL if your script doesn’t require it)
- Executable Path: point to Python (or a wrapper .bat/.ps1) and your script path
- Additional Parameters: JSON array passed to the executable (example format below)
- Vault name: e.g.,
Create the Vault "Credential" (used by the Generic Vault script)
In DCM, link a credential to authenticate to the vault.
Recommended mapping:
- Vault Username = Azure Client ID (this is the Azure application (client) ID, NOT the Secret ID)
- Vault Password = Azure Client Secret (this is the client "Secret VALUE")
Create a DCM Connection and Credential that Retrieves the Secret
Examples used is MySQL database connection.
- Create/Update a Data Source (MYSQL.)
Create a New Credential
- Select Vault = your Generic Vault
- Set:
- Vault Path: use this as your vault name
- Value ID (username and password): set this to the Key Vault secret name (example: from Azure key vault secret (
username and password))
DCM will pass Vault Path + Value ID to your script at runtime.
Test the connection
To learn more, visit the Community page below:
How To Configure a Generic Vault in Data Connection Manager