Bicep Machine Learning Workspace Codes doesn't work

Guilherme Matheus 120 Reputation points Microsoft Employee
2025-10-21T01:32:52.7433333+00:00

I am getting error when trying to create or reference an existing Codes and there is not a single place or documentation that I found and tells this is not possible, so this must be a bug, since all the other services that has versions is working fine, such as: environments, models, etc. This is Bicep documentation for this service.

If I define this resource:

resource machineLearningWorkspaceCodes 'Microsoft.MachineLearningServices/workspaces/codes@2025-09-01' existing = {
    name: 'test'
    parent: mlWorkspace
}

I get this error:

Status: Failed Error: Code: UserError Message: CodeContainers_Get is not supported

If I do not use existing word, like this:

resource machineLearningWorkspaceCodes 'Microsoft.MachineLearningServices/workspaces/codes@2025-09-01' = {
    name: 'test'
    parent: mlWorkspace
    properties: {description: 'test', isArchived: false}
}

I get this error:

Status: Failed Error: Code: UserError Message: CodeContainers_CreateOrUpdate is not supported

Azure Machine Learning
{count} votes

1 answer

Sort by: Most helpful
  1. Aryan Parashar 1,850 Reputation points Microsoft External Staff Moderator
    2025-10-21T08:17:03+00:00

    Hi Guilherme:
    Yes Azure Machine Learning currently doesn’t support creating or updating code containers via ARM or Bicep templates.

    The documentation exist, but the functionality isn’t implemented in practice.

    I’ve tried this multiple times on my end, and each time it returns the error: CodeContainers_CreateOrUpdate is not supported

    Also note that Azure Bicep operates as an abstraction layer over ARM and ARM templates.

    You can share feedback on this issue here:
    https://feedback.azure.com/d365community/

    Alternatively, you can create an Azure support ticket here:
    https://azure.microsoft.com/en-us/support/create-ticket

    Feel free to accept this as an answer.
    Thankyou for reaching out to The Microsoft QNA Portal.


Your answer

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