PUT /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/staticSites/{name}/?api-version=2023-01-01

Description for Creates a new static site in an existing resource group, or updates an existing static site.

Servers

Path parameters

Name Type Required Description
name String Yes

Name of the static site to create or update.

subscriptionId String Yes

Your Azure subscription ID. This is a GUID-formatted string (e.g. 00000000-0000-0000-0000-000000000000).

resourceGroupName String Yes

Name of the resource group to which the resource belongs.

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
id String No

Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"

name String No

The name of the resource

sku Object No

Description of a SKU for a scalable resource.

sku.tier String No

Service tier of the resource SKU.

sku.family String No

Family code of the resource SKU.

sku.name String No

Name of the resource SKU.

sku.size String No

Size specifier of the resource SKU.

sku.locations[] Array No

Locations of the SKU.

sku.skuCapacity Object No

Description of the App Service plan scale options.

sku.skuCapacity.minimum Integer No

Minimum number of workers for this App Service plan SKU.

sku.skuCapacity.elasticMaximum Integer No

Maximum number of Elastic workers for this App Service plan SKU.

sku.skuCapacity.default Integer No

Default number of workers for this App Service plan SKU.

sku.skuCapacity.scaleType String No

Available scale configurations for an App Service plan.

sku.skuCapacity.maximum Integer No

Maximum number of workers for this App Service plan SKU.

sku.capacity Integer No

Current number of instances assigned to the resource.

sku.capabilities[] Array No

Capabilities of the SKU, e.g., is traffic manager enabled?

sku.capabilities[].name String No

Name of the SKU capability.

sku.capabilities[].value String No

Value of the SKU capability.

sku.capabilities[].reason String No

Reason of the SKU capability.

systemData Object No

Metadata pertaining to creation and last modification of the resource.

systemData.createdByType String No

The type of identity that created the resource.

Possible values:

  • "ManagedIdentity"
  • "Key"
  • "Application"
  • "User"
systemData.lastModifiedAt String No

The timestamp of resource last modification (UTC)

systemData.createdAt String No

The timestamp of resource creation (UTC).

systemData.lastModifiedBy String No

The identity that last modified the resource.

systemData.lastModifiedByType String No

The type of identity that last modified the resource.

Possible values:

  • "ManagedIdentity"
  • "Key"
  • "Application"
  • "User"
systemData.createdBy String No

The identity that created the resource.

properties Object No

A static site.

properties.repositoryToken String No

A user's github repository token. This is used to setup the Github Actions workflow file and API secrets.

properties.allowConfigFileUpdates Boolean No

false if config file is locked for this static web app; otherwise, true.

properties.provider String No

The provider that submitted the last deployment to the primary environment of the static site.

properties.templateProperties Object No

Template Options for the static site.

properties.templateProperties.repositoryName String No

Name of the newly generated repository.

properties.templateProperties.description String No

Description of the newly generated repository.

properties.templateProperties.owner String No

Owner of the newly generated repository.

properties.templateProperties.templateRepositoryUrl String No

URL of the template repository. The newly generated repository will be based on this one.

properties.templateProperties.isPrivate Boolean No

Whether or not the newly generated repository is a private repository. Defaults to false (i.e. public).

properties.contentDistributionEndpoint String No

The content distribution endpoint for the static site.

properties.databaseConnections[] Array No

Database connections for the static site

properties.databaseConnections[].connectionIdentity String No

If present, the identity is used in conjunction with connection string to connect to the database. Use of the system-assigned managed identity is indicated with the string 'SystemAssigned', while use of a user-assigned managed identity is indicated with the resource id of the managed identity resource.

properties.databaseConnections[].region String No

The region of the database resource.

properties.databaseConnections[].name String No

If present, the name of this database connection resource.

properties.databaseConnections[].resourceId String No

The resource id of the database.

properties.databaseConnections[].configurationFiles[] Array No

A list of configuration files associated with this database connection.

properties.databaseConnections[].configurationFiles[].contents String No

The Base64 encoding of the file contents.

properties.databaseConnections[].configurationFiles[].fileName String No

The name of the configuration file.

properties.databaseConnections[].configurationFiles[].type String No

The type of configuration file.

properties.userProvidedFunctionApps[] Array No

User provided function apps registered with the static site

properties.userProvidedFunctionApps[].id String No

Resource Id.

properties.userProvidedFunctionApps[].name String No

Resource Name.

properties.userProvidedFunctionApps[].properties Object No

StaticSiteUserProvidedFunctionApp resource specific properties

properties.userProvidedFunctionApps[].properties.functionAppRegion String No

The region of the function app registered with the static site

properties.userProvidedFunctionApps[].properties.createdOn String No

The date and time on which the function app was registered with the static site.

properties.userProvidedFunctionApps[].properties.functionAppResourceId String No

The resource id of the function app registered with the static site

properties.userProvidedFunctionApps[].type String No

Resource type.

properties.userProvidedFunctionApps[].kind String No

Kind of resource.

properties.defaultHostname String No

The default autogenerated hostname for the static site.

properties.repositoryUrl String No

URL for the repository of the static site.

properties.enterpriseGradeCdnStatus String No

State indicating the status of the enterprise grade CDN serving traffic to the static web app.

Possible values:

  • "Disabled"
  • "Enabled"
  • "Disabling"
  • "Enabling"
properties.linkedBackends[] Array No

Backends linked to the static side

properties.linkedBackends[].backendResourceId String No

The resource id of the backend linked to the static site

properties.linkedBackends[].region String No

The region of the backend linked to the static site

properties.linkedBackends[].createdOn String No

The date and time on which the backend was linked to the static site.

properties.linkedBackends[].provisioningState String No

The provisioning state of the linking process.

properties.stagingEnvironmentPolicy String No

State indicating whether staging environments are allowed or not allowed for a static web app.

Possible values:

  • "Disabled"
  • "Enabled"
properties.publicNetworkAccess String No

State indicating whether public traffic are allowed or not for a static web app. Allowed Values: 'Enabled', 'Disabled' or an empty string.

properties.buildProperties Object No

Build properties for the static site.

properties.buildProperties.apiLocation String No

The path to the api code within the repository.

properties.buildProperties.appBuildCommand String No

A custom command to run during deployment of the static content application.

properties.buildProperties.apiBuildCommand String No

A custom command to run during deployment of the Azure Functions API application.

properties.buildProperties.skipGithubActionWorkflowGeneration Boolean No

Skip Github Action workflow generation.

properties.buildProperties.appLocation String No

The path to the app code within the repository.

properties.buildProperties.githubActionSecretNameOverride String No

Github Action secret name override.

properties.buildProperties.appArtifactLocation String No

Deprecated: The path of the app artifacts after building (deprecated in favor of OutputLocation)

properties.buildProperties.outputLocation String No

The output path of the app after building.

properties.branch String No

The target branch in the repository.

properties.customDomains[] Array No

The custom domains associated with this static site.

properties.keyVaultReferenceIdentity String No

Identity to use for Key Vault Reference authentication.

properties.privateEndpointConnections[] Array No

Private endpoint connections

properties.privateEndpointConnections[].id String No

Resource Id. Typically ID is populated only for responses to GET requests. Caller is responsible for passing in this value for GET requests only. For example: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupId}/providers/Microsoft.Web/sites/{sitename}

properties.privateEndpointConnections[].name String No

Name of resource.

properties.privateEndpointConnections[].sku Object No

Description of a SKU for a scalable resource.

properties.privateEndpointConnections[].sku.tier String No

Service tier of the resource SKU.

properties.privateEndpointConnections[].sku.family String No

Family code of the resource SKU.

properties.privateEndpointConnections[].sku.name String No

Name of the resource SKU.

properties.privateEndpointConnections[].sku.size String No

Size specifier of the resource SKU.

properties.privateEndpointConnections[].sku.locations[] Array No

Locations of the SKU.

properties.privateEndpointConnections[].sku.skuCapacity Object No

Description of the App Service plan scale options.

properties.privateEndpointConnections[].sku.skuCapacity.minimum Integer No

Minimum number of workers for this App Service plan SKU.

properties.privateEndpointConnections[].sku.skuCapacity.elasticMaximum Integer No

Maximum number of Elastic workers for this App Service plan SKU.

properties.privateEndpointConnections[].sku.skuCapacity.default Integer No

Default number of workers for this App Service plan SKU.

properties.privateEndpointConnections[].sku.skuCapacity.scaleType String No

Available scale configurations for an App Service plan.

properties.privateEndpointConnections[].sku.skuCapacity.maximum Integer No

Maximum number of workers for this App Service plan SKU.

properties.privateEndpointConnections[].sku.capacity Integer No

Current number of instances assigned to the resource.

properties.privateEndpointConnections[].sku.capabilities[] Array No

Capabilities of the SKU, e.g., is traffic manager enabled?

properties.privateEndpointConnections[].sku.capabilities[].name String No

Name of the SKU capability.

properties.privateEndpointConnections[].sku.capabilities[].value String No

Value of the SKU capability.

properties.privateEndpointConnections[].sku.capabilities[].reason String No

Reason of the SKU capability.

properties.privateEndpointConnections[].location String No

Geographical region resource belongs to e.g. SouthCentralUS, SouthEastAsia.

properties.privateEndpointConnections[].properties Object No

A remote private endpoint connection

properties.privateEndpointConnections[].properties.id String No

Resource Id.

properties.privateEndpointConnections[].properties.name String No

Resource Name.

properties.privateEndpointConnections[].properties.properties Object No

RemotePrivateEndpointConnection resource specific properties

properties.privateEndpointConnections[].properties.properties.ipAddresses[] Array No

Private IPAddresses mapped to the remote private endpoint

properties.privateEndpointConnections[].properties.properties.provisioningState String No
properties.privateEndpointConnections[].properties.properties.privateLinkServiceConnectionState Object No

The state of a private link connection

properties.privateEndpointConnections[].properties.properties.privateLinkServiceConnectionState.description String No

Description of a private link connection

properties.privateEndpointConnections[].properties.properties.privateLinkServiceConnectionState.actionsRequired String No

ActionsRequired for a private link connection

properties.privateEndpointConnections[].properties.properties.privateLinkServiceConnectionState.status String No

Status of a private link connection

properties.privateEndpointConnections[].properties.properties.privateEndpoint Object No

A wrapper for an ARM resource id

properties.privateEndpointConnections[].properties.properties.privateEndpoint.id String No
properties.privateEndpointConnections[].properties.type String No

Resource type.

properties.privateEndpointConnections[].properties.kind String No

Kind of resource.

properties.privateEndpointConnections[].zones[] Array No

Logical Availability Zones the service is hosted in

properties.privateEndpointConnections[].tags Object No

Tags associated with resource.

properties.privateEndpointConnections[].type String No

Type of resource e.g "Microsoft.Web/sites".

properties.privateEndpointConnections[].error Object No

Body of the error response returned from the API.

properties.privateEndpointConnections[].error.extendedCode String No

Type of error.

properties.privateEndpointConnections[].error.message String No

Any details of the error.

properties.privateEndpointConnections[].error.parameters[] Array No

Parameters for the template.

properties.privateEndpointConnections[].error.target String No

The error target.

properties.privateEndpointConnections[].error.messageTemplate String No

Message template.

properties.privateEndpointConnections[].error.code String No

Basic error code.

properties.privateEndpointConnections[].error.innerErrors[] Array No

Inner errors.

properties.privateEndpointConnections[].error.details[] Array No

Error Details.

properties.privateEndpointConnections[].plan Object No

The plan object in Azure Resource Manager, represents a marketplace plan.

properties.privateEndpointConnections[].plan.name String No

The name.

properties.privateEndpointConnections[].plan.publisher String No

The publisher.

properties.privateEndpointConnections[].plan.version String No

Version of product.

properties.privateEndpointConnections[].plan.product String No

The product.

properties.privateEndpointConnections[].plan.promotionCode String No

The promotion code.

properties.privateEndpointConnections[].status String No

Azure-AsyncOperation Status info.

properties.privateEndpointConnections[].identity Object No

Managed service identity.

properties.privateEndpointConnections[].identity.tenantId String No

Tenant of managed service identity.

properties.privateEndpointConnections[].identity.type String No

Type of managed service identity.

Possible values:

  • "SystemAssigned"
  • "UserAssigned"
  • "None"
  • "SystemAssigned, UserAssigned"
properties.privateEndpointConnections[].identity.userAssignedIdentities Object No

The list of user assigned identities associated with the resource. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}

properties.privateEndpointConnections[].identity.userAssignedIdentities.name Object No

User Assigned identity.

properties.privateEndpointConnections[].identity.userAssignedIdentities.name.principalId String No

Principal Id of user assigned identity

properties.privateEndpointConnections[].identity.userAssignedIdentities.name.clientId String No

Client Id of user assigned identity

properties.privateEndpointConnections[].identity.principalId String No

Principal Id of managed service identity.

type String No

The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"

identity Object No

Managed service identity.

identity.tenantId String No

Tenant of managed service identity.

identity.type String No

Type of managed service identity.

Possible values:

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

The list of user assigned identities associated with the resource. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}

identity.userAssignedIdentities.name Object No

User Assigned identity.

identity.userAssignedIdentities.name.principalId String No

Principal Id of user assigned identity

identity.userAssignedIdentities.name.clientId String No

Client Id of user assigned identity

identity.principalId String No

Principal Id of managed service 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.