diff --git a/specification/computeschedule/ComputeSchedule.Management/routes.tsp b/specification/computeschedule/ComputeSchedule.Management/routes.tsp index dc309ab475e6..248798f1ef03 100644 --- a/specification/computeschedule/ComputeSchedule.Management/routes.tsp +++ b/specification/computeschedule/ComputeSchedule.Management/routes.tsp @@ -127,7 +127,13 @@ interface ScheduledActions { createOrUpdate is ArmResourceCreateOrReplaceAsync; @added(Microsoft.ComputeSchedule.Versions.`2025-04-15-preview`) - update is ArmResourcePatchSync; + update is ArmCustomPatchSync< + ScheduledAction, + Azure.ResourceManager.Foundations.ResourceUpdateModel< + ScheduledAction, + ScheduledActionProperties + > + >; @added(Microsoft.ComputeSchedule.Versions.`2025-04-15-preview`) delete is ArmResourceDeleteWithoutOkAsync; diff --git a/specification/computeschedule/ComputeSchedule.Management/tspconfig.yaml b/specification/computeschedule/ComputeSchedule.Management/tspconfig.yaml index c7d445cf25a4..fd9d108b6200 100644 --- a/specification/computeschedule/ComputeSchedule.Management/tspconfig.yaml +++ b/specification/computeschedule/ComputeSchedule.Management/tspconfig.yaml @@ -16,8 +16,6 @@ options: generate-test: true generate-sample: true "@azure-tools/typespec-ts": - # TODO: remove this once issue resolved: https://github.com/Azure/autorest.typescript/issues/3228 - generate-sample: false experimental-extensible-enums: true package-dir: "arm-computeschedule" flavor: azure diff --git a/specification/computeschedule/resource-manager/Microsoft.ComputeSchedule/preview/2025-04-15-preview/computeschedule.json b/specification/computeschedule/resource-manager/Microsoft.ComputeSchedule/preview/2025-04-15-preview/computeschedule.json index d8e3f40f767b..a17b2846aa52 100644 --- a/specification/computeschedule/resource-manager/Microsoft.ComputeSchedule/preview/2025-04-15-preview/computeschedule.json +++ b/specification/computeschedule/resource-manager/Microsoft.ComputeSchedule/preview/2025-04-15-preview/computeschedule.json @@ -1838,25 +1838,6 @@ "type": "string", "description": "Represents an Azure geography region where supported resource providers live." }, - "Azure.ResourceManager.CommonTypes.TrackedResourceUpdate": { - "type": "object", - "title": "Tracked Resource", - "description": "The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location'", - "properties": { - "tags": { - "type": "object", - "description": "Resource tags.", - "additionalProperties": { - "type": "string" - } - } - }, - "allOf": [ - { - "$ref": "../../../../../common-types/resource-management/v6/types.json#/definitions/Resource" - } - ] - }, "Azure.ResourceManager.ResourceProvisioningState": { "type": "string", "description": "The provisioning state of a resource type.", @@ -3695,49 +3676,6 @@ "notificationSettings" ] }, - "ScheduledActionPropertiesUpdate": { - "type": "object", - "description": "Scheduled action properties", - "properties": { - "resourceType": { - "$ref": "#/definitions/ResourceType", - "description": "The type of resource the scheduled action is targeting" - }, - "actionType": { - "$ref": "#/definitions/ActionType", - "description": "The action the scheduled action should perform in the resources" - }, - "startTime": { - "type": "string", - "format": "date-time", - "description": "The time which the scheduled action is supposed to start running" - }, - "endTime": { - "type": "string", - "format": "date-time", - "description": "The time when the scheduled action is supposed to stop scheduling" - }, - "schedule": { - "$ref": "#/definitions/ScheduledActionsScheduleUpdate", - "description": "The schedule the scheduled action is supposed to follow" - }, - "notificationSettings": { - "type": "array", - "description": "The notification settings for the scheduled action", - "items": { - "$ref": "#/definitions/NotificationProperties" - }, - "x-ms-identifiers": [ - "destination" - ] - }, - "disabled": { - "type": "boolean", - "description": "Tell if the scheduled action is disabled or not", - "default": false - } - } - }, "ScheduledActionResource": { "type": "object", "description": "Represents an scheduled action resource metadata.", @@ -3842,18 +3780,63 @@ }, "ScheduledActionUpdate": { "type": "object", - "description": "The scheduled action resource", + "description": "The type used for update operations of the ScheduledAction.", "properties": { + "tags": { + "type": "object", + "description": "Resource tags.", + "additionalProperties": { + "type": "string" + } + }, "properties": { - "$ref": "#/definitions/ScheduledActionPropertiesUpdate", + "$ref": "#/definitions/ScheduledActionUpdateProperties", "description": "The resource-specific properties for this resource." } - }, - "allOf": [ - { - "$ref": "#/definitions/Azure.ResourceManager.CommonTypes.TrackedResourceUpdate" + } + }, + "ScheduledActionUpdateProperties": { + "type": "object", + "description": "The updatable properties of the ScheduledAction.", + "properties": { + "resourceType": { + "$ref": "#/definitions/ResourceType", + "description": "The type of resource the scheduled action is targeting" + }, + "actionType": { + "$ref": "#/definitions/ActionType", + "description": "The action the scheduled action should perform in the resources" + }, + "startTime": { + "type": "string", + "format": "date-time", + "description": "The time which the scheduled action is supposed to start running" + }, + "endTime": { + "type": "string", + "format": "date-time", + "description": "The time when the scheduled action is supposed to stop scheduling" + }, + "schedule": { + "$ref": "#/definitions/ScheduledActionsScheduleUpdate", + "description": "The schedule the scheduled action is supposed to follow" + }, + "notificationSettings": { + "type": "array", + "description": "The notification settings for the scheduled action", + "items": { + "$ref": "#/definitions/NotificationProperties" + }, + "x-ms-identifiers": [ + "destination" + ] + }, + "disabled": { + "type": "boolean", + "description": "Tell if the scheduled action is disabled or not", + "default": false } - ] + } }, "ScheduledActionsId": { "type": "string",