皆様いつもお世話になっております。
最近Teamsで通知を行う方法を模索しており、メッセージ自体を送信することはできたのですが、メンション機能使うことができませんでした。
使用したアクティビティーは「UiPath.IntegrationService.Activityes」に含まれているmicrosoftTeamsの「チャネル メッセージを送信」
StudioのVerはCommunity版の 2024.10.4です。
メンション機能を使用したいのですが、使えないためどなたかご教授いただければ幸いです。
他に判断材料に必要な情報ありましたら、お教えいただければと思います。
試したこととしては
- メッセージ本文に"<at id=““0"” >”& チームのメンバー情報(2).displayName & ""を使用する
→atタグは消えてdisplayNameのみ表示、メンション機能は付与されなかった - 1の内容に加え、プロパティの管理内にある
「Mensions ID,
Mensions mension text,
Mensions mensioned user displayname,
Mensions mensioned user ID,
Mensions mensioned user identity Type」
に各メンバー情報を入力する
→下記のエラーが表示されデバッグ時に止まる
2024-09-19 10:13:06.694 GMT+9: Error: Newtonsoft.Json.JsonSerializationException: Cannot deserialize the current JSON array (e.g. [1,2,3]) into type 'UiPath.IntegrationService.Activities.SWEntities.C67E0D1C0E8_normalisedminus_signteams_channels_messagesminus_signv2_Create.Bundle.mentions' because the type requires a JSON object (e.g. {"name":"value"}) to deserialize correctly.
To fix this error either change the JSON to a JSON object (e.g. {"name":"value"}) or change the deserialized type to an array or a type that implements a collection interface (e.g. ICollection, IList) like List<T> that can be deserialized from a JSON array. JsonArrayAttribute can also be added to the type to force it to deserialize from a JSON array.
Path 'mentions', line 1, position 845.
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.EnsureArrayContract(JsonReader reader, Type objectType, JsonContract contract)
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateList(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, Object existingValue, String id)
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateValueInternal(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, Object existingValue)
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.SetPropertyValue(JsonProperty property, JsonConverter propertyConverter, JsonContainerContract containerContract, JsonProperty containerProperty, JsonReader reader, Object target)
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.PopulateObject(Object newObject, JsonReader reader, JsonObjectContract contract, JsonProperty member, String id)
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateObject(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, Object existingValue)
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateValueInternal(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, Object existingValue)
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize(JsonReader reader, Type objectType, Boolean checkAdditionalContent)
at Newtonsoft.Json.JsonSerializer.DeserializeInternal(JsonReader reader, Type objectType)
at Newtonsoft.Json.Linq.JToken.ToObject(Type objectType, JsonSerializer jsonSerializer)
at Newtonsoft.Json.Linq.JToken.ToObject(Type objectType)
at UiPath.IntegrationService.Activities.Runtime.Helpers.ConnectorActivityHelpers.SetOutArgumentValues(ActivityContext ctx, Collection`1 fieldObjects, ServiceResponse serviceResponse, ConnectorActivityConfiguration activityConfiguration)
at UiPath.IntegrationService.Activities.Runtime.Activities.ConnectorActivity.SetOutArgumentValues(AsyncCodeActivityContext context, ServiceResponse serviceResponse)
at UiPath.IntegrationService.Activities.Runtime.Activities.ConnectorActivity.<>c__DisplayClass16_0.<ExecuteAsync>b__0(AsyncCodeActivityContext ctx)
at UiPath.IntegrationService.Activities.Runtime.Activities.AsyncTaskCodeActivityImplementation.EndExecute(AsyncCodeActivityContext context, IAsyncResult result)
at UiPath.IntegrationService.Activities.Runtime.Activities.AsyncTaskCodeActivity.EndExecute(AsyncCodeActivityContext context, IAsyncResult result)
at System.Activities.AsyncCodeActivity.CompleteAsyncCodeActivityData.CompleteAsyncCodeActivityWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)