How to export Artifacts ARM Template for a Azure Synapse Workspace?

Napsty Dev 20 Reputation points
2025-04-21T16:58:39.59+00:00

Is there a possible way to export an "Artifacts ARM Template" from a specific resource?

I have been trying to implement an Azure devops CI/CD Pipeline that migrates artifacts (Pipeline, dataflows and datasets) between Synpase workspaces (i.e. dev, qa, prod) across multiple workspaces without using any Git configuration.

Screenshot 2025-04-21 at 12.17.32 PM

I have already set up this CI/CD system with Git configuration, where I use both TemplateForWorkspace.json and ParametersTemplateForWorkspace.json to deploy into a different Synapse workspace. These files are auto-generated by Synapse’s workspace publish branch feature.

So far, I haven’t been able to replicate these two files, which are absolutely necessary to perform a deployment. I am attempting this because I prefer to use only Synapse Live mode, without enabling Git integration.

The only thing I've managed to obtain so far is a template fetched via an HTTPS request using Azure's REST API. However, this ARM template does NOT include any artifacts, meaning that even if deployed, the Synapse workspace won’t contain the original resource content/artifacts.

ARM Template fetched via HTTPS request:

{
    "template": {
        "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
        "contentVersion": "1.0.0.0",
        "parameters": {
            "vulnerabilityAssessments_Default_storageContainerPath": {
                "type": "SecureString"
            },
            "workspaces_synapse_dev_napsty_name": {
                "defaultValue": "synapse-dev-napsty",
                "type": "String"
            },
            "storageAccounts_napdatalake_externalid": {
                "defaultValue": "/subscriptions/8be7d968-ce5d-402f-84f0-ba21765d77c1/resourceGroups/devrg/providers/Microsoft.Storage/storageAccounts/napdatalake",
                "type": "String"
            }
        },
        "variables": {},
        "resources": [
            {
                "type": "Microsoft.Synapse/workspaces",
                "apiVersion": "2021-06-01",
                "name": "[parameters('workspaces_synapse_dev_napsty_name')]",
                "location": "australiaeast",
                "identity": {
                    "type": "SystemAssigned"
                },
                "properties": {
                    "defaultDataLakeStorage": {
                        "resourceId": "[parameters('storageAccounts_napdatalake_externalid')]",
                        "createManagedPrivateEndpoint": false,
                        "accountUrl": "https://napdatalake.dfs.core.windows.net",
                        "filesystem": "napdatalakefs"
                    },
                    "encryption": {},
                    "managedResourceGroupName": "synapseworkspace-managedrg-22275c84-71ba-412c-ac0c-90b1a6f93b4b",
                    "sqlAdministratorLogin": "sqladminuser",
                    "privateEndpointConnections": [],
                    "workspaceRepositoryConfiguration": {
                        "accountName": "napstyy0227",
                        "collaborationBranch": "dev",
                        "lastCommitId": "d2c9d624ec8fd345ef2f8acc84ab64ecfd6c3d79",
                        "projectName": "AzureSynapse",
                        "repositoryName": "AzureSynapse",
                        "rootFolder": "/synapse",
                        "tenantId": "63ec89f0-780b-4349-8a65-b8c44dddc8dd",
                        "type": "WorkspaceVSTSConfiguration"
                    },
                    "publicNetworkAccess": "Enabled",
                    "cspWorkspaceAdminProperties": {
                        "initialWorkspaceAdminObjectId": "94888bea-0df0-4bda-8c43-988d03fb0323"
                    },
                    "azureADOnlyAuthentication": false,
                    "trustedServiceBypassEnabled": false
                }
            },
            {
                "type": "Microsoft.Synapse/workspaces/auditingSettings",
                "apiVersion": "2021-06-01",
                "name": "[concat(parameters('workspaces_synapse_dev_napsty_name'), '/Default')]",
                "dependsOn": [
                    "[resourceId('Microsoft.Synapse/workspaces', parameters('workspaces_synapse_dev_napsty_name'))]"
                ],
                "properties": {
                    "retentionDays": 0,
                    "auditActionsAndGroups": [],
                    "isStorageSecondaryKeyInUse": false,
                    "isAzureMonitorTargetEnabled": false,
                    "state": "Disabled",
                    "storageAccountSubscriptionId": "00000000-0000-0000-0000-000000000000"
                }
            },
            {
                "type": "Microsoft.Synapse/workspaces/azureADOnlyAuthentications",
                "apiVersion": "2021-06-01",
                "name": "[concat(parameters('workspaces_synapse_dev_napsty_name'), '/default')]",
                "dependsOn": [
                    "[resourceId('Microsoft.Synapse/workspaces', parameters('workspaces_synapse_dev_napsty_name'))]"
                ],
                "properties": {
                    "azureADOnlyAuthentication": false
                }
            },
            {
                "type": "Microsoft.Synapse/workspaces/dedicatedSQLminimalTlsSettings",
                "apiVersion": "2021-06-01",
                "name": "[concat(parameters('workspaces_synapse_dev_napsty_name'), '/default')]",
                "location": "australiaeast",
                "dependsOn": [
                    "[resourceId('Microsoft.Synapse/workspaces', parameters('workspaces_synapse_dev_napsty_name'))]"
                ],
                "properties": {
                    "minimalTlsVersion": "1.2"
                }
            },
            {
                "type": "Microsoft.Synapse/workspaces/extendedAuditingSettings",
                "apiVersion": "2021-06-01",
                "name": "[concat(parameters('workspaces_synapse_dev_napsty_name'), '/Default')]",
                "dependsOn": [
                    "[resourceId('Microsoft.Synapse/workspaces', parameters('workspaces_synapse_dev_napsty_name'))]"
                ],
                "properties": {
                    "retentionDays": 0,
                    "auditActionsAndGroups": [],
                    "isStorageSecondaryKeyInUse": false,
                    "isAzureMonitorTargetEnabled": false,
                    "state": "Disabled",
                    "storageAccountSubscriptionId": "00000000-0000-0000-0000-000000000000"
                }
            },
            {
                "type": "Microsoft.Synapse/workspaces/firewallRules",
                "apiVersion": "2021-06-01",
                "name": "[concat(parameters('workspaces_synapse_dev_napsty_name'), '/allowAll')]",
                "dependsOn": [
                    "[resourceId('Microsoft.Synapse/workspaces', parameters('workspaces_synapse_dev_napsty_name'))]"
                ],
                "properties": {
                    "startIpAddress": "0.0.0.0",
                    "endIpAddress": "255.255.255.255"
                }
            },
            {
                "type": "Microsoft.Synapse/workspaces/integrationruntimes",
                "apiVersion": "2021-06-01",
                "name": "[concat(parameters('workspaces_synapse_dev_napsty_name'), '/AutoResolveIntegrationRuntime')]",
                "dependsOn": [
                    "[resourceId('Microsoft.Synapse/workspaces', parameters('workspaces_synapse_dev_napsty_name'))]"
                ],
                "properties": {
                    "type": "Managed",
                    "typeProperties": {
                        "computeProperties": {
                            "location": "AutoResolve"
                        }
                    }
                }
            },
            {
                "type": "Microsoft.Synapse/workspaces/securityAlertPolicies",
                "apiVersion": "2021-06-01",
                "name": "[concat(parameters('workspaces_synapse_dev_napsty_name'), '/Default')]",
                "dependsOn": [
                    "[resourceId('Microsoft.Synapse/workspaces', parameters('workspaces_synapse_dev_napsty_name'))]"
                ],
                "properties": {
                    "state": "Disabled",
                    "disabledAlerts": [
                        ""
                    ],
                    "emailAddresses": [
                        ""
                    ],
                    "emailAccountAdmins": false,
                    "retentionDays": 0
                }
            },
            {
                "type": "Microsoft.Synapse/workspaces/vulnerabilityAssessments",
                "apiVersion": "2021-06-01",
                "name": "[concat(parameters('workspaces_synapse_dev_napsty_name'), '/Default')]",
                "dependsOn": [
                    "[resourceId('Microsoft.Synapse/workspaces', parameters('workspaces_synapse_dev_napsty_name'))]"
                ],
                "properties": {
                    "recurringScans": {
                        "isEnabled": false,
                        "emailSubscriptionAdmins": true
                    },
                    "storageContainerPath": "[parameters('vulnerabilityAssessments_Default_storageContainerPath')]"
                }
            }
        ]
    }
}
Azure Synapse Analytics
Azure Synapse Analytics
An Azure analytics service that brings together data integration, enterprise data warehousing, and big data analytics. Previously known as Azure SQL Data Warehouse.
5,318 questions
0 comments No comments
{count} votes

Accepted answer
  1. J N S S Kasyap 1,715 Reputation points Microsoft External Staff
    2025-04-21T18:35:29.6133333+00:00

    Hi @Napsty Dev

    In Azure Synapse, without Git integration, there is currently no built-in way to export all workspace artifacts (pipelines, datasets, data flows, etc.) as a full ARM template like the TemplateForWorkspace.json you get from a publish branch.

    The Export ARM template option (via REST API or Azure Portal) only exports infrastructure-level settings (workspace configuration, firewall rules, etc.), not artifacts.

    Another alternative is to use Synapse REST APIs to extract individual artifacts like pipelines, datasets, and notebooks from your live workspace. This approach is more manual and involves calling different endpoints for each artifact type, then storing the JSON definitions yourself. While this method doesn't give you a full ARM template, you could potentially script a process to package these definitions and deploy them using the Synapse SDK or management APIs. However, it lacks the automation and structure of the Git-based publish process and is not recommended for large or complex projects unless Git integration is not an option.

    Using Git integration also enables version control, collaboration, rollback, and audit capabilities, which are essential for managing complex data solutions in a team environment. While alternatives like REST API extraction exist, they lack the automation, structure, and full artifact coverage that Git + Publish provides. If you're aiming for reliability, scalability, and maintainability in your CI/CD process, Git integration is the most robust and production-ready choice.

    I hope this information helps. Please do let us know if you have any further queries.

    Kindly consider upvoting the comment if the information provided is helpful. This can assist other community members in resolving similar issues.

    Thank you.

    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.