import "@azure-tools/typespec-azure-core"; import "@azure-tools/typespec-azure-resource-manager"; import "@typespec/openapi"; import "@typespec/rest"; import "@typespec/versioning"; import "./models.tsp"; import "./Site.tsp"; using TypeSpec.Rest; using Azure.ResourceManager; using TypeSpec.Http; using TypeSpec.OpenAPI; using TypeSpec.Versioning; namespace Microsoft.Web; /** * Represents a silo of an App Service site. */ @added(Versions.v2026_06_01_preview) @parentResource(Site) model SiteSilo is Azure.ResourceManager.TrackedResource { ...ResourceNameParameter< Resource = SiteSilo, KeyName = "siloName", SegmentName = "silos", NamePattern = "^[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]$" >; /** Kind of resource. */ #suppress "@azure-tools/typespec-azure-resource-manager/arm-resource-invalid-envelope-property" "Existing pattern in Microsoft.Web" kind?: string; } @added(Versions.v2026_06_01_preview) @armResourceOperations interface SiteSiloOps extends Azure.ResourceManager.Legacy.LegacyOperations< { ...ApiVersionParameter, ...SubscriptionIdParameter, ...ResourceGroupParameter, ...Azure.ResourceManager.Legacy.Provider, /** Name of the app. */ @path @segment("sites") @key name: string, }, { /** Name of the silo. */ @path @segment("silos") @key @pattern("^[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9]$") siloName: string, } > {} @added(Versions.v2026_06_01_preview) @tag("WebApps") @armResourceOperations(#{ omitTags: true }) interface SiteSilos { /** * Returns the details of a specific silo associated with the specified web app. */ @summary("Get a specific silo for a web app.") get is SiteSiloOps.Read; /** * Creates a new silo or updates an existing silo for the specified web app. */ @summary("Create or update a web app silo.") createOrUpdate is SiteSiloOps.CreateOrUpdateAsync; /** * Updates the tags of an existing web app silo. */ @summary("Update a web app silo.") update is SiteSiloOps.CustomPatchSync< SiteSilo, PatchModel = SiteSiloPatchResource, OverrideErrorType = DefaultErrorResponse >; /** * Deletes the specified silo from the web app. */ @summary("Delete a web app silo.") delete is SiteSiloOps.DeleteWithoutOkAsync; /** * Returns a paginated list of all silos associated with the specified web app. */ @summary("Get all silos for a web app.") list is SiteSiloOps.List< SiteSilo, Response = ArmResponse, OverrideErrorType = DefaultErrorResponse >; } @@doc(SiteSilo.name, "Name of the silo."); @@doc(SiteSilo.properties, "SiteSilo resource specific properties"); @@doc(SiteSilos.createOrUpdate::parameters.resource, "Details of the silo."); @@doc(SiteSilos.update::parameters.properties, "Details of the silo update.");