Skip to content

Commit

Permalink
Added Metadata to chat thread and user level events (#26347)
Browse files Browse the repository at this point in the history
* Added Metadata to chat thread and user level events

* Updated examples for each event which has new metadata fields

* Apply suggestions for example user metadata

* Update example metadata

* Fix typo

* Remove description from examples and add additional properties value for metadata dictionary to denote type string

* Updated remaining examples in cloud-events-schema and event-grid-schema

* Removed extra metadata properties
  • Loading branch information
mbutowicz authored and jnlycklama committed Nov 8, 2023
1 parent e47b5ad commit 66c27c4
Show file tree
Hide file tree
Showing 16 changed files with 110 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -964,6 +964,13 @@
"type": "object"
}
},
"metadata": {
"description": "The thread metadata",
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"participants": {
"description": "The list of properties of participants who are part of the thread",
"type": "array",
Expand Down Expand Up @@ -1060,6 +1067,13 @@
"format": "date-time",
"type": "string"
},
"metadata": {
"description": "The thread metadata",
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"properties": {
"description": "The updated thread properties",
"type": "object",
Expand Down Expand Up @@ -1093,6 +1107,13 @@
"additionalProperties": {
"type": "object"
}
},
"metadata": {
"description": "The thread metadata",
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
},
Expand Down Expand Up @@ -1655,6 +1676,13 @@
"participantCommunicationIdentifier": {
"description": "The communication identifier of the user",
"$ref": "../../../../../communication/data-plane/Common/stable/2021-03-07/common.json#/definitions/CommunicationIdentifierModel"
},
"metadata": {
"description": "The metadata of the user",
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@
"communicationUser": {
"id": "8:acs:0a420b29-555c-4f6b-841e-de8059893bb9_00000008-77c9-8785-1655-373a0d00885f"
}
},
"metadata": {
"key": "value"
}
},
"recipientCommunicationIdentifier": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@
"communicationUser": {
"id": "8:acs:0a420b29-555c-4f6b-841e-de8059893bb9_00000008-77c9-8785-1655-373a0d00885f"
}
},
"metadata": {
"key": "value"
}
},
"recipientCommunicationIdentifier": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38a0-88f7-084822002453"
}
},
"metadata": {
"key": "value"
}
},
{
Expand All @@ -31,6 +34,10 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38e6-07fd-084822002467"
}
},
"metadata": {
"key": "value",
"description": "A map of data associated with the participant"
}
},
{
Expand All @@ -40,6 +47,9 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38f6-83fe-084822002337"
}
},
"metadata": {
"key": "value"
}
},
{
Expand All @@ -49,9 +59,15 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38e3-e1fe-084822002c35"
}
},
"metadata": {
"key": "value"
}
}
],
"metadata": {
"key": "value"
},
"createTime": "2021-02-19T16:31:54.365-08:00",
"version": 1613781114365,
"threadId": "19:e07c8ddc5bab4c059ea9f11d29b544b6@thread.v2",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@
"communicationUser": {
"id": "8:acs:3d703c91-9657-4b3f-b19c-ef9d53f99710_00000008-576c-286d-e1fe-0848220013b9"
}
},
"metadata": {
"key": "value"
}
},
{
Expand All @@ -42,9 +45,15 @@
"communicationUser": {
"id": "8:acs:3d703c91-9657-4b3f-b19c-ef9d53f99710_00000008-576c-289b-07fd-0848220015ea"
}
},
"metadata": {
"key": "value"
}
}
],
"metadata": {
"key": "value"
},
"createTime": "2021-02-18T23:47:26.91Z",
"version": 1613692046910,
"recipientId": "8:acs:3d703c91-9657-4b3f-b19c-ef9d53f99710_00000008-576c-286e-84f5-08482200181c",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38f3-88f7-084822002454"
}
},
"metadata": {
"key": "value"
}
},
"createTime": "2021-02-19T16:31:54.365-08:00",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38e6-07fd-084822002467"
}
},
"metadata": {
"key": "value"
}
},
"createTime": "2021-02-19T16:31:54.365-08:00",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@
"properties": {
"topic": "Communication in Azure"
},
"metadata": {
"key": "value"
},
"createTime": "2021-02-19T00:28:25.864Z",
"version": 1613694508719,
"recipientId": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-578d-7caf-07fd-084822001724",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
"communicationUser": {
"id": "8:acs:0a420b29-555c-4f6b-841e-de8059893bb9_00000008-77c9-8785-1655-373a0d00885f"
}
},
"metadata": {
"key": "value"
}
},
"recipientCommunicationIdentifier": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
"communicationUser": {
"id": "8:acs:0a420b29-555c-4f6b-841e-de8059893bb9_00000008-77c9-8785-1655-373a0d00885f"
}
},
"metadata": {
"key": "value"
}
},
"recipientCommunicationIdentifier": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38a0-88f7-084822002453"
}
},
"metadata": {
"key": "value"
}
},
{
Expand All @@ -29,6 +32,9 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38e6-07fd-084822002467"
}
},
"metadata": {
"key": "value"
}
},
{
Expand All @@ -38,6 +44,9 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38f6-83fe-084822002337"
}
},
"metadata": {
"key": "value"
}
},
{
Expand All @@ -47,9 +56,15 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38e3-e1fe-084822002c35"
}
},
"metadata": {
"key": "value"
}
}
],
"metadata": {
"key": "value"
},
"createTime": "2021-02-20T00:31:54.365+00:00",
"version": 1613781114365,
"threadId": "19:e07c8ddc5bab4c059ea9f11d29b544b6@thread.v2",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@
"communicationUser": {
"id": "8:acs:3d703c91-9657-4b3f-b19c-ef9d53f99710_00000008-576c-286d-e1fe-0848220013b9"
}
},
"metadata": {
"key": "value"
}
},
{
Expand All @@ -40,9 +43,15 @@
"communicationUser": {
"id": "8:acs:3d703c91-9657-4b3f-b19c-ef9d53f99710_00000008-576c-289b-07fd-0848220015ea"
}
},
"metadata": {
"key": "value"
}
}
],
"metadata": {
"key": "value"
},
"createTime": "2021-02-18T23:47:26.91Z",
"version": 1613692046910,
"recipientId": "8:acs:3d703c91-9657-4b3f-b19c-ef9d53f99710_00000008-576c-286e-84f5-08482200181c",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38f3-88f7-084822002454"
}
},
"metadata": {
"key": "value"
}
},
"createTime": "2021-02-20T00:31:54.365+00:00",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
"communicationUser": {
"id": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-5cbb-38e6-07fd-084822002467"
}
},
"metadata": {
"key": "value"
}
},
"createTime": "2021-02-20T00:31:54.365+00:00",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
"properties": {
"topic": "Talk about new Thread Events in commuication services"
},
"metadata": {
"key": "value"
},
"createTime": "2021-02-20T00:00:40.126+00:00",
"version": 1613779447695,
"threadId": "19:9e8eefe67b3c470a8187b4c2b00240bc@thread.v2",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@
"properties": {
"topic": "Communication in Azure"
},
"metadata": {
"key": "value"
},
"createTime": "2021-02-19T00:28:25.864Z",
"version": 1613694508719,
"recipientId": "8:acs:109f0644-b956-4cd9-87b1-71024f6e2f44_00000008-578d-7caf-07fd-084822001724",
Expand Down

0 comments on commit 66c27c4

Please sign in to comment.