From 39d4db105a3ec26018a34d2ffa626c5863d55c0a Mon Sep 17 00:00:00 2001 From: jolov Date: Tue, 2 Jul 2024 11:54:25 -0700 Subject: [PATCH 1/5] Fix casing of timestamp properties --- .../AzureCommunicationServices.tsp | 4 ++-- .../stable/2018-01-01/AzureCommunicationServices.json | 10 ++++------ 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.Communication/AzureCommunicationServices.tsp b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.Communication/AzureCommunicationServices.tsp index 69b9b1966ffb..634f85970444 100644 --- a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.Communication/AzureCommunicationServices.tsp +++ b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.Communication/AzureCommunicationServices.tsp @@ -252,7 +252,7 @@ model AcsEmailDeliveryReportReceivedEventData { deliveryStatusDetails: AcsEmailDeliveryReportStatusDetails; /** The time at which the email delivery report received timestamp */ - deliveryAttemptTimeStamp: utcDateTime; + deliveryAttemptTimestamp: utcDateTime; } /** Schema of the Data property of an EventGridEvent for a Microsoft.Communication.EmailEngagementTrackingReportReceived event. */ @@ -267,7 +267,7 @@ model AcsEmailEngagementTrackingReportReceivedEventData { messageId?: string; /** The time at which the user interacted with the email */ - userActionTimeStamp: utcDateTime; + userActionTimestamp: utcDateTime; /** The context of the type of engagement user had with email */ engagementContext?: string; diff --git a/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/AzureCommunicationServices.json b/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/AzureCommunicationServices.json index 8cbf69a50d02..4228c52100eb 100644 --- a/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/AzureCommunicationServices.json +++ b/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/AzureCommunicationServices.json @@ -1480,11 +1480,10 @@ "description": "Detailed information about the status if any", "$ref": "#/definitions/AcsEmailDeliveryReportStatusDetails" }, - "deliveryAttemptTimeStamp": { + "deliveryAttemptTimestamp": { "description": "The time at which the email delivery report received timestamp", "format": "date-time", - "type": "string", - "x-ms-client-name": "deliveryAttemptTimestamp" + "type": "string" } } }, @@ -1504,11 +1503,10 @@ "description": "The Id of the email that has been sent", "type": "string" }, - "userActionTimeStamp": { + "userActionTimestamp": { "description": "The time at which the user interacted with the email", "format": "date-time", - "type": "string", - "x-ms-client-name": "userActionTimestamp" + "type": "string" }, "engagementContext": { "description": "The context of the type of engagement user had with email", From f626c222b831bfc20d03c60ea3d9340081977410 Mon Sep 17 00:00:00 2001 From: jolov Date: Tue, 2 Jul 2024 12:00:05 -0700 Subject: [PATCH 2/5] Fix examples --- .../cloud-events-schema/email_delivery_report_received.json | 2 +- .../email_engagement_tracking_report_received.json | 2 +- .../event-grid-schema/email_delivery_report_received.json | 2 +- .../email_engagement_tracking_report_received.json | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/cloud-events-schema/email_delivery_report_received.json b/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/cloud-events-schema/email_delivery_report_received.json index cefae0de0469..73732b719478 100644 --- a/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/cloud-events-schema/email_delivery_report_received.json +++ b/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/cloud-events-schema/email_delivery_report_received.json @@ -7,7 +7,7 @@ "recipient": "test1@contoso.com", "messageId": "950850f5-bcdf-4315-b77a-6447cf56fac9", "status": "delivered", - "deliveryAttemptTimeStamp": "2023-02-09T19:46:12.2480265+00:00" + "deliveryAttemptTimestamp": "2023-02-09T19:46:12.2480265+00:00" }, "type": "Microsoft.Communication.EmailDeliveryReportReceived", "time": "2023-02-09T19:46:12.2478002Z", diff --git a/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/cloud-events-schema/email_engagement_tracking_report_received.json b/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/cloud-events-schema/email_engagement_tracking_report_received.json index a3f80e9ec99f..aeff3ea6ff26 100644 --- a/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/cloud-events-schema/email_engagement_tracking_report_received.json +++ b/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/cloud-events-schema/email_engagement_tracking_report_received.json @@ -5,7 +5,7 @@ "data": { "sender": "test2@contoso.org", "messageId": "fe26a737-6941-410c-b126-7eacbe4035d1", - "userActionTimeStamp": "2023-02-09T20:07:22.745555+00:00", + "userActionTimestamp": "2023-02-09T20:07:22.745555+00:00", "engagementContext": "www.example.com", "userAgent": "Desktop", "engagementType": "click" diff --git a/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/event-grid-schema/email_delivery_report_received.json b/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/event-grid-schema/email_delivery_report_received.json index cd033a72e70a..47d4fc8b7d68 100644 --- a/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/event-grid-schema/email_delivery_report_received.json +++ b/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/event-grid-schema/email_delivery_report_received.json @@ -7,7 +7,7 @@ "recipient": "test1@contoso.com", "messageId": "950850f5-bcdf-4315-b77a-6447cf56fac9", "status": "delivered", - "deliveryAttemptTimeStamp": "2023-02-09T19:46:12.2480265+00:00", + "deliveryAttemptTimestamp": "2023-02-09T19:46:12.2480265+00:00", "deliveryStatusDetails": { "statusMessage": "DestinationMailboxFull" } diff --git a/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/event-grid-schema/email_engagement_tracking_report_received.json b/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/event-grid-schema/email_engagement_tracking_report_received.json index 7b543b7e3444..65bc2f04746e 100644 --- a/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/event-grid-schema/email_engagement_tracking_report_received.json +++ b/specification/eventgrid/data-plane/Microsoft.Communication/stable/2018-01-01/examples/event-grid-schema/email_engagement_tracking_report_received.json @@ -5,7 +5,7 @@ "data": { "sender": "test2@contoso.org", "messageId": "fe26a737-6941-410c-b126-7eacbe4035d1", - "userActionTimeStamp": "2023-02-09T20:07:22.745555+00:00", + "userActionTimestamp": "2023-02-09T20:07:22.745555+00:00", "engagementContext": "www.example.com", "userAgent": "Desktop", "engagementType": "click" From 0524b94e1bc9f25f4abd9befde7b94f0298212c3 Mon Sep 17 00:00:00 2001 From: jolov Date: Tue, 2 Jul 2024 12:01:06 -0700 Subject: [PATCH 3/5] more examples --- .../examples/2024-01-01/email_delivery_report_received.json | 2 +- .../2024-01-01/email_engagement_tracking_report_received.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/examples/2024-01-01/email_delivery_report_received.json b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/examples/2024-01-01/email_delivery_report_received.json index bf96f5e6b66f..51dddcbc6d56 100644 --- a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/examples/2024-01-01/email_delivery_report_received.json +++ b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/examples/2024-01-01/email_delivery_report_received.json @@ -7,7 +7,7 @@ "recipient": "test1@contoso.com", "messageId": "950850f5-bcdf-4315-b77a-6447cf56fac9", "status": "delivered", - "deliveryAttemptTimeStamp": "2023-02-09T19:46:12.2480265+00:00" + "deliveryAttemptTimestamp": "2023-02-09T19:46:12.2480265+00:00" }, "type": "Microsoft.Communication.EmailDeliveryReportReceived", "time": "2023-02-09T19:46:12.2478002Z", diff --git a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/examples/2024-01-01/email_engagement_tracking_report_received.json b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/examples/2024-01-01/email_engagement_tracking_report_received.json index 85f10a93a965..f45a02148908 100644 --- a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/examples/2024-01-01/email_engagement_tracking_report_received.json +++ b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/examples/2024-01-01/email_engagement_tracking_report_received.json @@ -5,7 +5,7 @@ "data": { "sender": "test2@contoso.org", "messageId": "fe26a737-6941-410c-b126-7eacbe4035d1", - "userActionTimeStamp": "2023-02-09T20:07:22.745555+00:00", + "userActionTimestamp": "2023-02-09T20:07:22.745555+00:00", "engagementContext": "www.example.com", "userAgent": "Desktop", "engagementType": "click" From 23f3d2bd28357fe561f93b68b91a8946281c26c1 Mon Sep 17 00:00:00 2001 From: jolov Date: Tue, 9 Jul 2024 09:09:21 -0700 Subject: [PATCH 4/5] property overrides --- .../propertyNameOverride.tsp | 8 -------- .../propertyNameOverrideCsharp.tsp | 8 -------- .../propertyNameOverrideGo.tsp | 8 -------- .../propertyNameOverrideJs.tsp | 10 ++-------- 4 files changed, 2 insertions(+), 32 deletions(-) diff --git a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverride.tsp b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverride.tsp index 1b2b2247d318..afce376662a8 100644 --- a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverride.tsp +++ b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverride.tsp @@ -25,14 +25,6 @@ using Azure.ClientGenerator.Core; ); @@clientName(AcsRouterWorkerSelector.value, "labelValue", "autorest"); -@@clientName(AcsEmailDeliveryReportReceivedEventData.deliveryAttemptTimeStamp, - "deliveryAttemptTimestamp", - "autorest" -); -@@clientName(AcsEmailEngagementTrackingReportReceivedEventData.userActionTimeStamp, - "userActionTimestamp", - "autorest" -); @@clientName(AcsEmailEngagementTrackingReportReceivedEventData.engagementType, "engagement", "autorest" diff --git a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideCsharp.tsp b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideCsharp.tsp index 60933e665420..5bb8dea15e6d 100644 --- a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideCsharp.tsp +++ b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideCsharp.tsp @@ -23,14 +23,6 @@ using Microsoft.EventGrid.SystemEvents; "csharp" ); -@@clientName(AcsEmailDeliveryReportReceivedEventData.deliveryAttemptTimeStamp, - "deliveryAttemptTimestamp", - "csharp" -); -@@clientName(AcsEmailEngagementTrackingReportReceivedEventData.userActionTimeStamp, - "userActionTimestamp", - "csharp" -); @@clientName(AcsEmailEngagementTrackingReportReceivedEventData.engagementType, "engagement", "csharp" diff --git a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideGo.tsp b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideGo.tsp index 3f1332b43f72..67d69823970f 100644 --- a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideGo.tsp +++ b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideGo.tsp @@ -333,10 +333,6 @@ using Microsoft.EventGrid.SystemEvents; "ACSEmailDeliveryReportReceivedEventData", "go" ); -@@clientName(AcsEmailDeliveryReportReceivedEventData.deliveryAttemptTimeStamp, - "DeliveryAttemptTimestamp", - "go" -); @@clientName(AcsEmailDeliveryReportStatus, "ACSEmailDeliveryReportStatus", @@ -355,10 +351,6 @@ using Microsoft.EventGrid.SystemEvents; "Engagement", "go" ); -@@clientName(AcsEmailEngagementTrackingReportReceivedEventData.userActionTimeStamp, - "UserActionTimestamp", - "go" -); @@clientName(AcsIncomingCallCustomContext, "ACSIncomingCallCustomContext", diff --git a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideJs.tsp b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideJs.tsp index aae89181bef8..b729151e8e59 100644 --- a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideJs.tsp +++ b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/propertyNameOverrideJs.tsp @@ -45,10 +45,7 @@ using Microsoft.EventGrid.SystemEvents; "toCommunicationIdentifier", "javascript" ); -@@clientName(AcsEmailEngagementTrackingReportReceivedEventData.userActionTimeStamp, - "userActionTimestamp", - "javascript" -); + @@clientName(AcsEmailEngagementTrackingReportReceivedEventData.engagementType, "engagement", "javascript" @@ -65,10 +62,7 @@ using Microsoft.EventGrid.SystemEvents; "summaryReportBlobUri", "javascript" ); -@@clientName(AcsEmailDeliveryReportReceivedEventData.deliveryAttemptTimeStamp, - "deliveryAttemptTimestamp", - "javascript" -); + @@clientName(ResourceNotificationsResourceUpdatedEventData.resourceInfo, "resourceDetails", "javascript" From e53bab1cc6667de3f36bcd9e0f83b3063464e275 Mon Sep 17 00:00:00 2001 From: jolov Date: Tue, 9 Jul 2024 09:11:48 -0700 Subject: [PATCH 5/5] regen swagger --- .../stable/2024-01-01/SystemEvents.json | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2024-01-01/SystemEvents.json b/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2024-01-01/SystemEvents.json index 292cc198dde2..3de7019fb636 100644 --- a/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2024-01-01/SystemEvents.json +++ b/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2024-01-01/SystemEvents.json @@ -718,17 +718,16 @@ "$ref": "#/definitions/AcsEmailDeliveryReportStatusDetails", "description": "Detailed information about the status if any" }, - "deliveryAttemptTimeStamp": { + "deliveryAttemptTimestamp": { "type": "string", "format": "date-time", - "description": "The time at which the email delivery report received timestamp", - "x-ms-client-name": "deliveryAttemptTimestamp" + "description": "The time at which the email delivery report received timestamp" } }, "required": [ "status", "deliveryStatusDetails", - "deliveryAttemptTimeStamp" + "deliveryAttemptTimestamp" ] }, "AcsEmailDeliveryReportStatus": { @@ -805,11 +804,10 @@ "type": "string", "description": "The Id of the email that has been sent" }, - "userActionTimeStamp": { + "userActionTimestamp": { "type": "string", "format": "date-time", - "description": "The time at which the user interacted with the email", - "x-ms-client-name": "userActionTimestamp" + "description": "The time at which the user interacted with the email" }, "engagementContext": { "type": "string", @@ -826,7 +824,7 @@ } }, "required": [ - "userActionTimeStamp", + "userActionTimestamp", "engagementType" ] },