Skip to content
Merged
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,28 @@
}
},
"responses": {
"200": {
"body": {
"properties": {
"snapshotTime": "wgujspthevkfo",
"initiatorId": "ghublxbeifhvhwokvhppbw",
"metadata": {
"key9372": "jtc"
}
},
"id": "/subscriptions/11111111-2222-3333-4444-555555555555/resourceGroups/rg1Network/providers/Microsoft.FileShares/fileShares/testfileshare/fileShareSnapshots/testfilesharesnapshot",
"name": "testfilesharesnapshot",
"type": "Microsoft.FileShares/fileShares/fileShareSnapshots",
"systemData": {
"createdBy": "moat",
"createdByType": "User",
"createdAt": "2025-07-23T12:37:53.955Z",
"lastModifiedBy": "dxukcadzapywjcgnxsqchaa",
"lastModifiedByType": "User",
"lastModifiedAt": "2025-07-23T12:37:53.955Z"
}
}
},
"202": {
"headers": {
"location": "https://contoso.com/operationstatus"
Expand Down
13 changes: 11 additions & 2 deletions specification/fileshares/FileShares.Management/fileshares.tsp
Original file line number Diff line number Diff line change
Expand Up @@ -298,14 +298,23 @@ interface FileShareSnapshots {
#suppress "@azure-tools/typespec-azure-resource-manager/arm-put-operation-response-codes" "RP doesn't support 201 Created pattern for proxy resources in public preview. To be addressed in GA."
@operationId("FileShareSnapshot_CreateOrUpdate")
@doc("Create a FileShareSnapshot.")
createOrUpdateFileShareSnapshot is ArmResourceCreateOrReplaceSync<FileShareSnapshot>;
createOrUpdateFileShareSnapshot is ArmResourceCreateOrReplaceAsync<
FileShareSnapshot,
BaseParameters<FileShareSnapshot>,
Response = ArmAcceptedLroResponse<LroHeaders = ArmAsyncOperationHeader &
ArmLroLocationHeader<FinalResult = FileShareSnapshot> &
Azure.Core.Foundations.RetryAfterHeader>
>;

@operationId("FileShareSnapshot_Update")
@doc("Update a FileShareSnapshot.")
updateFileShareSnapshot is ArmCustomPatchAsync<
FileShareSnapshot,
ResourceUpdateModel<FileShareSnapshot, FileShareSnapshotProperties>,
BaseParameters<FileShareSnapshot>
BaseParameters<FileShareSnapshot>,
Response = ArmResponse<FileShareSnapshot> | ArmAcceptedLroResponse<LroHeaders = ArmAsyncOperationHeader &
ArmLroLocationHeader<FinalResult = FileShareSnapshot> &
Azure.Core.Foundations.RetryAfterHeader>
>;

@operationId("FileShareSnapshot_Delete")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,28 @@
}
},
"responses": {
"200": {
"body": {
"properties": {
"snapshotTime": "wgujspthevkfo",
"initiatorId": "ghublxbeifhvhwokvhppbw",
"metadata": {
"key9372": "jtc"
}
},
"id": "/subscriptions/11111111-2222-3333-4444-555555555555/resourceGroups/rg1Network/providers/Microsoft.FileShares/fileShares/testfileshare/fileShareSnapshots/testfilesharesnapshot",
"name": "testfilesharesnapshot",
"type": "Microsoft.FileShares/fileShares/fileShareSnapshots",
"systemData": {
"createdBy": "moat",
"createdByType": "User",
"createdAt": "2025-07-23T12:37:53.955Z",
"lastModifiedBy": "dxukcadzapywjcgnxsqchaa",
"lastModifiedByType": "User",
"lastModifiedAt": "2025-07-23T12:37:53.955Z"
}
}
},
"202": {
"headers": {
"location": "https://contoso.com/operationstatus"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -760,16 +760,22 @@
}
],
"responses": {
"200": {
"description": "Resource 'FileShareSnapshot' update operation succeeded",
"schema": {
"$ref": "#/definitions/FileShareSnapshot"
}
},
"201": {
"description": "Resource 'FileShareSnapshot' create operation succeeded",
"schema": {
"$ref": "#/definitions/FileShareSnapshot"
"202": {
"description": "Resource operation accepted.",
"headers": {
"Azure-AsyncOperation": {
"type": "string",
"description": "A link to the status monitor"
},
"Location": {
"type": "string",
"description": "The Location header contains the URL where the status of the long running operation can be checked."
},
"Retry-After": {
"type": "integer",
"format": "int32",
"description": "The Retry-After header can indicate how long the client should wait before polling the operation status."
}
}
},
"default": {
Expand All @@ -783,7 +789,11 @@
"FileShareSnapshot_CreateOrUpdate_MaximumSet": {
"$ref": "./examples/FileShareSnapshot_CreateOrUpdate_MaximumSet_Gen.json"
}
}
},
"x-ms-long-running-operation-options": {
"final-state-via": "location"
},
"x-ms-long-running-operation": true
},
"patch": {
"operationId": "FileShareSnapshot_Update",
Expand Down Expand Up @@ -835,8 +845,12 @@
}
},
"202": {
"description": "Resource update request accepted.",
"description": "Resource operation accepted.",
"headers": {
"Azure-AsyncOperation": {
"type": "string",
"description": "A link to the status monitor"
},
"Location": {
"type": "string",
"description": "The Location header contains the URL where the status of the long running operation can be checked."
Expand Down
32 changes: 32 additions & 0 deletions specification/fileshares/resource-manager/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,38 @@ directive:

- $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.FileShares/fileShares/{resourceName}/fileShareSnapshots/{name}"].patch.operationId

- suppress: ProvisioningStateSpecifiedForLROPut

reason: "RP doesn't support 201 Created pattern for proxy resources in public preview. To be addressed in GA."

where:

- $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.FileShares/fileShares/{resourceName}/fileShareSnapshots/{name}"].put

- suppress: ProvisioningStateSpecifiedForLROPatch

reason: "RP doesn't support 201 Created pattern for proxy resources in public preview. To be addressed in GA."

where:

- $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.FileShares/fileShares/{resourceName}/fileShareSnapshots/{name}"].patch

- suppress: PutResponseCodes

reason: "RP doesn't support 201 Created pattern for proxy resources in public preview. To be addressed in GA."

where:

- $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.FileShares/fileShares/{resourceName}/fileShareSnapshots/{name}"].put

- suppress: PutGetPatchResponseSchema

reason: "Cannot support same schema object for PUT/GET/PATCH for proxy object due to 202 response"

where:

- $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.FileShares/fileShares/{resourceName}/fileShareSnapshots/{name}"]

```


Expand Down
Loading