PATCH /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/?api-version=2023-08-01-preview

Patches a Container App using JSON Merge Patch

Servers

Path parameters

Name Type Required Description
subscriptionId String Yes

The ID of the target subscription. The value must be an UUID.

containerAppName String Yes

Name of the Container App.

resourceGroupName String Yes

The name of the resource group. The name is case insensitive.

Request headers

Name Type Required Description
Content-Type String Yes The media type of the request body.

Default value: "application/json"

Request body fields

Name Type Required Description
extendedLocation Object No

The complex type of the extended location.

extendedLocation.name String No

The name of the extended location.

extendedLocation.type String No

The type of extendedLocation.

Possible values:

  • "CustomLocation"
location String No

The geo-location where the resource lives

properties Object No

ContainerApp resource specific properties

properties.latestRevisionName String No

Name of the latest revision of the Container App.

properties.latestRevisionFqdn String No

Fully Qualified Domain Name of the latest revision of the Container App.

properties.template Object No

Container App versioned application definition. Defines the desired state of an immutable revision. Any changes to this section Will result in a new revision being created

properties.template.terminationGracePeriodSeconds Integer No

Optional duration in seconds the Container App Instance needs to terminate gracefully. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). If this value is nil, the default grace period will be used instead. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds.

properties.template.revisionSuffix String No

User friendly suffix that is appended to the revision name

properties.template.initContainers[] Array No

List of specialized containers that run before app containers.

properties.template.initContainers[].volumeMounts[] Array No

Container volume mounts.

properties.template.initContainers[].volumeMounts[].subPath String No

Path within the volume from which the container's volume should be mounted. Defaults to "" (volume's root).

properties.template.initContainers[].volumeMounts[].volumeName String No

This must match the Name of a Volume.

properties.template.initContainers[].volumeMounts[].mountPath String No

Path within the container at which the volume should be mounted.Must not contain ':'.

properties.template.initContainers[].name String No

Custom container name.

properties.template.initContainers[].env[] Array No

Container environment variables.

properties.template.initContainers[].env[].name String No

Environment variable name.

properties.template.initContainers[].env[].secretRef String No

Name of the Container App secret from which to pull the environment variable value.

properties.template.initContainers[].env[].value String No

Non-secret environment variable value.

properties.template.initContainers[].command[] Array No

Container start command.

properties.template.initContainers[].resources Object No

Container App container resource requirements.

properties.template.initContainers[].resources.memory String No

Required memory, e.g. "250Mb"

properties.template.initContainers[].resources.cpu Number No

Required CPU in cores, e.g. 0.5

properties.template.initContainers[].resources.ephemeralStorage String No

Ephemeral Storage, e.g. "1Gi"

properties.template.initContainers[].image String No

Container image tag.

properties.template.initContainers[].args[] Array No

Container start command arguments.

properties.template.scale Object No

Container App scaling configurations.

properties.template.scale.rules[] Array No

Scaling rules.

properties.template.scale.rules[].custom Object No

Container App container Custom scaling rule.

properties.template.scale.rules[].custom.auth[] Array No

Authentication secrets for the custom scale rule.

properties.template.scale.rules[].custom.auth[].triggerParameter String No

Trigger Parameter that uses the secret

properties.template.scale.rules[].custom.auth[].secretRef String No

Name of the secret from which to pull the auth params.

properties.template.scale.rules[].custom.type String No

Type of the custom scale rule eg: azure-servicebus, redis etc.

properties.template.scale.rules[].custom.metadata Object No

Metadata properties to describe custom scale rule.

properties.template.scale.rules[].azureQueue Object No

Container App container Azure Queue based scaling rule.

properties.template.scale.rules[].azureQueue.auth[] Array No

Authentication secrets for the queue scale rule.

properties.template.scale.rules[].azureQueue.auth[].triggerParameter String No

Trigger Parameter that uses the secret

properties.template.scale.rules[].azureQueue.auth[].secretRef String No

Name of the secret from which to pull the auth params.

properties.template.scale.rules[].azureQueue.queueLength Integer No

Queue length.

properties.template.scale.rules[].azureQueue.queueName String No

Queue name.

properties.template.scale.rules[].name String No

Scale Rule Name

properties.template.scale.rules[].tcp Object No

Container App container Tcp scaling rule.

properties.template.scale.rules[].tcp.auth[] Array No

Authentication secrets for the tcp scale rule.

properties.template.scale.rules[].tcp.auth[].triggerParameter String No

Trigger Parameter that uses the secret

properties.template.scale.rules[].tcp.auth[].secretRef String No

Name of the secret from which to pull the auth params.

properties.template.scale.rules[].tcp.metadata Object No

Metadata properties to describe tcp scale rule.

properties.template.scale.rules[].http Object No

Container App container Http scaling rule.

properties.template.scale.rules[].http.auth[] Array No

Authentication secrets for the custom scale rule.

properties.template.scale.rules[].http.auth[].triggerParameter String No

Trigger Parameter that uses the secret

properties.template.scale.rules[].http.auth[].secretRef String No

Name of the secret from which to pull the auth params.

properties.template.scale.rules[].http.metadata Object No

Metadata properties to describe http scale rule.

properties.template.scale.maxReplicas Integer No

Optional. Maximum number of container replicas. Defaults to 10 if not set.

Default value: 10

properties.template.scale.minReplicas Integer No

Optional. Minimum number of container replicas.

properties.template.serviceBinds[] Array No

List of container app services bound to the app

properties.template.serviceBinds[].name String No

Name of the service bind

properties.template.serviceBinds[].customizedKeys Object No

Customized keys for customizing injected values to the app

properties.template.serviceBinds[].serviceId String No

Resource id of the target service

properties.template.serviceBinds[].clientType String No

Type of the client to be used to connect to the service

properties.template.containers[] Array No

List of container definitions for the Container App.

properties.template.containers[].probes[] Array No

List of probes for the container.

properties.template.containers[].probes[].failureThreshold Integer No

Minimum consecutive failures for the probe to be considered failed after having succeeded. Defaults to 3. Minimum value is 1. Maximum value is 10.

properties.template.containers[].probes[].httpGet Object No

HTTPGet specifies the http request to perform.

properties.template.containers[].probes[].httpGet.port Integer Yes

Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.

properties.template.containers[].probes[].httpGet.httpHeaders[] Array No

Custom headers to set in the request. HTTP allows repeated headers.

properties.template.containers[].probes[].httpGet.httpHeaders[].name String Yes

The header field name

properties.template.containers[].probes[].httpGet.httpHeaders[].value String Yes

The header field value

properties.template.containers[].probes[].httpGet.scheme String No

Scheme to use for connecting to the host. Defaults to HTTP.

Possible values:

  • "HTTP"
  • "HTTPS"
properties.template.containers[].probes[].httpGet.host String No

Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead.

properties.template.containers[].probes[].httpGet.path String No

Path to access on the HTTP server.

properties.template.containers[].probes[].periodSeconds Integer No

How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1. Maximum value is 240.

properties.template.containers[].probes[].tcpSocket Object No

TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported.

properties.template.containers[].probes[].tcpSocket.port Integer Yes

Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.

properties.template.containers[].probes[].tcpSocket.host String No

Optional: Host name to connect to, defaults to the pod IP.

properties.template.containers[].probes[].terminationGracePeriodSeconds Integer No

Optional duration in seconds the pod needs to terminate gracefully upon probe failure. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. If this value is nil, the pod's terminationGracePeriodSeconds will be used. Otherwise, this value overrides the value provided by the pod spec. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). This is an alpha field and requires enabling ProbeTerminationGracePeriod feature gate. Maximum value is 3600 seconds (1 hour)

properties.template.containers[].probes[].timeoutSeconds Integer No

Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. Maximum value is 240.

properties.template.containers[].probes[].initialDelaySeconds Integer No

Number of seconds after the container has started before liveness probes are initiated. Minimum value is 1. Maximum value is 60.

properties.template.containers[].probes[].type String No

The type of probe.

Possible values:

  • "Startup"
  • "Readiness"
  • "Liveness"
properties.template.containers[].probes[].successThreshold Integer No

Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness and startup. Minimum value is 1. Maximum value is 10.

properties.template.containers[].volumeMounts[] Array No

Container volume mounts.

properties.template.containers[].volumeMounts[].subPath String No

Path within the volume from which the container's volume should be mounted. Defaults to "" (volume's root).

properties.template.containers[].volumeMounts[].volumeName String No

This must match the Name of a Volume.

properties.template.containers[].volumeMounts[].mountPath String No

Path within the container at which the volume should be mounted.Must not contain ':'.

properties.template.containers[].name String No

Custom container name.

properties.template.containers[].env[] Array No

Container environment variables.

properties.template.containers[].env[].name String No

Environment variable name.

properties.template.containers[].env[].secretRef String No

Name of the Container App secret from which to pull the environment variable value.

properties.template.containers[].env[].value String No

Non-secret environment variable value.

properties.template.containers[].command[] Array No

Container start command.

properties.template.containers[].resources Object No

Container App container resource requirements.

properties.template.containers[].resources.memory String No

Required memory, e.g. "250Mb"

properties.template.containers[].resources.cpu Number No

Required CPU in cores, e.g. 0.5

properties.template.containers[].resources.ephemeralStorage String No

Ephemeral Storage, e.g. "1Gi"

properties.template.containers[].image String No

Container image tag.

properties.template.containers[].args[] Array No

Container start command arguments.

properties.template.volumes[] Array No

List of volume definitions for the Container App.

properties.template.volumes[].storageName String No

Name of storage resource. No need to provide for EmptyDir and Secret.

properties.template.volumes[].name String No

Volume name.

properties.template.volumes[].storageType String No

Storage type for the volume. If not provided, use EmptyDir.

Possible values:

  • "EmptyDir"
  • "AzureFile"
  • "Secret"
properties.template.volumes[].secrets[] Array No

List of secrets to be added in volume. If no secrets are provided, all secrets in collection will be added to volume.

properties.template.volumes[].secrets[].secretRef String No

Name of the Container App secret from which to pull the secret value.

properties.template.volumes[].secrets[].path String No

Path to project secret to. If no path is provided, path defaults to name of secret listed in secretRef.

properties.template.volumes[].mountOptions String No

Mount options used while mounting the AzureFile. Must be a comma-separated string.

properties.provisioningState String No

Provisioning state of the Container App.

Possible values:

  • "Succeeded"
  • "Deleting"
  • "Canceled"
  • "InProgress"
  • "Failed"
properties.workloadProfileName String No

Workload profile name for container apps to execute on.

properties.managedEnvironmentId String No

Deprecated. Resource ID of the Container App's environment.

properties.configuration Object No

Non versioned Container App configuration properties that define the mutable settings of a Container app

properties.configuration.registries[] Array No

Collection of private container registry credentials for containers used by the Container app

properties.configuration.registries[].passwordSecretRef String No

The name of the Secret that contains the registry login password

properties.configuration.registries[].username String No

Container Registry Username

properties.configuration.registries[].server String No

Container Registry Server

properties.configuration.registries[].identity String No

A Managed Identity to use to authenticate with Azure Container Registry. For user-assigned identities, use the full user-assigned identity Resource ID. For system-assigned identities, use 'system'

properties.configuration.secrets[] Array No

Collection of secrets used by a Container app

properties.configuration.secrets[].name String No

Secret Name.

properties.configuration.secrets[].keyVaultUrl String No

Azure Key Vault URL pointing to the secret referenced by the container app.

properties.configuration.secrets[].value String No

Secret Value.

properties.configuration.secrets[].identity String No

Resource ID of a managed identity to authenticate with Azure Key Vault, or System to use a system-assigned identity.

properties.configuration.activeRevisionsMode String No

ActiveRevisionsMode controls how active revisions are handled for the Container app: Multiple: multiple revisions can be active.Single: Only one revision can be active at a time. Revision weights can not be used in this mode. If no value if provided, this is the default.

Possible values:

  • "Single"
  • "Multiple"

Default value: "Single"

properties.configuration.service Object No

Container App to be a dev service

properties.configuration.service.type String Yes

Dev ContainerApp service type

properties.configuration.dapr Object No

Container App Dapr configuration.

properties.configuration.dapr.appProtocol String No

Tells Dapr which protocol your application is using. Valid options are http and grpc. Default is http

Possible values:

  • "grpc"
  • "http"

Default value: "http"

properties.configuration.dapr.httpReadBufferSize Integer No

Dapr max size of http header read buffer in KB to handle when sending multi-KB headers. Default is 65KB.

properties.configuration.dapr.logLevel String No

Sets the log level for the Dapr sidecar. Allowed values are debug, info, warn, error. Default is info.

Possible values:

  • "warn"
  • "error"
  • "debug"
  • "info"
properties.configuration.dapr.httpMaxRequestSize Integer No

Increasing max size of request body http and grpc servers parameter in MB to handle uploading of big files. Default is 4 MB.

properties.configuration.dapr.enabled Boolean No

Boolean indicating if the Dapr side car is enabled

Default value: false

properties.configuration.dapr.appId String No

Dapr application identifier

properties.configuration.dapr.appPort Integer No

Tells Dapr which port your application is listening on

properties.configuration.dapr.enableApiLogging Boolean No

Enables API logging for the Dapr sidecar

properties.configuration.maxInactiveRevisions Integer No

Optional. Max inactive revisions a Container App can have.

properties.configuration.ingress Object No

Container App Ingress configuration.

properties.configuration.ingress.allowInsecure Boolean No

Bool indicating if HTTP connections to is allowed. If set to false HTTP connections are automatically redirected to HTTPS connections

Default value: false

properties.configuration.ingress.stickySessions Object No

Sticky Sessions for Single Revision Mode

properties.configuration.ingress.stickySessions.affinity String No

Sticky Session Affinity

Possible values:

  • "sticky"
  • "none"
properties.configuration.ingress.corsPolicy Object No

Cross-Origin-Resource-Sharing policy

properties.configuration.ingress.corsPolicy.allowCredentials Boolean No

Specifies whether the resource allows credentials

properties.configuration.ingress.corsPolicy.exposeHeaders[] Array No

Specifies the content for the access-control-expose-headers header

properties.configuration.ingress.corsPolicy.allowedHeaders[] Array No

Specifies the content for the access-control-allow-headers header

properties.configuration.ingress.corsPolicy.allowedOrigins[] Array Yes

Specifies the content for the access-control-allow-origins header

properties.configuration.ingress.corsPolicy.allowedMethods[] Array No

Specifies the content for the access-control-allow-methods header

properties.configuration.ingress.corsPolicy.maxAge Integer No

Specifies the content for the access-control-max-age header

properties.configuration.ingress.traffic[] Array No

Traffic weights for app's revisions

properties.configuration.ingress.traffic[].label String No

Associates a traffic label with a revision

properties.configuration.ingress.traffic[].latestRevision Boolean No

Indicates that the traffic weight belongs to a latest stable revision

Default value: false

properties.configuration.ingress.traffic[].weight Integer No

Traffic weight assigned to a revision

properties.configuration.ingress.traffic[].revisionName String No

Name of a revision

properties.configuration.ingress.exposedPort Integer No

Exposed Port in containers for TCP traffic from ingress

properties.configuration.ingress.clientCertificateMode String No

Client certificate mode for mTLS authentication. Ignore indicates server drops client certificate on forwarding. Accept indicates server forwards client certificate but does not require a client certificate. Require indicates server requires a client certificate.

Possible values:

  • "ignore"
  • "require"
  • "accept"
properties.configuration.ingress.targetPort Integer No

Target Port in containers for traffic from ingress

properties.configuration.ingress.customDomains[] Array No

custom domain bindings for Container Apps' hostnames.

properties.configuration.ingress.customDomains[].certificateId String No

Resource Id of the Certificate to be bound to this hostname. Must exist in the Managed Environment.

properties.configuration.ingress.customDomains[].name String Yes

Hostname.

properties.configuration.ingress.customDomains[].bindingType String No

Custom Domain binding type.

Possible values:

  • "Disabled"
  • "SniEnabled"
properties.configuration.ingress.external Boolean No

Bool indicating if app exposes an external http endpoint

Default value: false

properties.configuration.ingress.fqdn String No

Hostname.

properties.configuration.ingress.additionalPortMappings[] Array No

Settings to expose additional ports on container app

properties.configuration.ingress.additionalPortMappings[].exposedPort Integer No

Specifies the exposed port for the target port. If not specified, it defaults to target port

properties.configuration.ingress.additionalPortMappings[].targetPort Integer Yes

Specifies the port user's container listens on

properties.configuration.ingress.additionalPortMappings[].external Boolean Yes

Specifies whether the app port is accessible outside of the environment

properties.configuration.ingress.transport String No

Ingress transport protocol

Possible values:

  • "auto"
  • "tcp"
  • "http"
  • "http2"

Default value: "auto"

properties.configuration.ingress.ipSecurityRestrictions[] Array No

Rules to restrict incoming IP address.

properties.configuration.ingress.ipSecurityRestrictions[].name String Yes

Name for the IP restriction rule.

properties.configuration.ingress.ipSecurityRestrictions[].ipAddressRange String Yes

CIDR notation to match incoming IP address

properties.configuration.ingress.ipSecurityRestrictions[].description String No

Describe the IP restriction rule that is being sent to the container-app. This is an optional field.

properties.configuration.ingress.ipSecurityRestrictions[].action String Yes

Allow or Deny rules to determine for incoming IP. Note: Rules can only consist of ALL Allow or ALL Deny

Possible values:

  • "Deny"
  • "Allow"
properties.outboundIpAddresses[] Array No

Outbound IP Addresses for container app.

properties.latestReadyRevisionName String No

Name of the latest ready revision of the Container App.

properties.customDomainVerificationId String No

Id used to verify domain name ownership

properties.environmentId String No

Resource ID of environment.

properties.eventStreamEndpoint String No

The endpoint of the eventstream of the container app.

tags Object No

Resource tags.

managedBy String No

The fully qualified resource ID of the resource that manages this resource. Indicates if this resource is managed by another Azure resource. If this is present, complete mode deployment will not delete the resource if it is removed from the template since it is managed by another resource.

identity Object No

Managed service identity (system assigned and/or user assigned identities)

identity.tenantId String No

The tenant ID of the system assigned identity. This property will only be provided for a system assigned identity.

identity.type String Yes

Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed).

Possible values:

  • "SystemAssigned"
  • "SystemAssigned,UserAssigned"
  • "UserAssigned"
  • "None"
identity.userAssignedIdentities Object No

The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. The dictionary values can be empty objects ({}) in requests.

identity.principalId String No

The service principal ID of the system assigned identity. This property will only be provided for a system assigned identity.

How to start integrating

  1. Add HTTP Task to your workflow definition.
  2. Search for the API you want to integrate with and click on the name.
    • This loads the API reference documentation and prepares the Http request settings.
  3. Click Test request to test run your request to the API and see the API's response.