microsoft/teams.net

Public

mirrored fromhttps://github.com/microsoft/teams.netAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
733a37f2b7310e6fd954187427f2af0e713dc286

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

Libraries/Microsoft.Teams.AI/Messages/DeveloperMessage.cs

34lines · modecode

1// Copyright (c) Microsoft Corporation. All rights reserved.
2// Licensed under the MIT License.
3
4using System.Text.Json;
5using System.Text.Json.Serialization;
6
7namespace Microsoft.Teams.AI.Messages;
8
9[Obsolete("Microsoft.Teams.AI is deprecated and will be removed by end of summer 2026.")]
10public class DeveloperMessage : IMessage
11{
12 [JsonPropertyName("role")]
13 [JsonPropertyOrder(0)]
14 public Role Role => Role.Developer;
15
16 [JsonPropertyName("content")]
17 [JsonPropertyOrder(1)]
18 public string Content { get; set; }
19
20 [JsonConstructor]
21 public DeveloperMessage(string content)
22 {
23 Content = content;
24 }
25
26 public override string ToString()
27 {
28 return JsonSerializer.Serialize(this, new JsonSerializerOptions()
29 {
30 WriteIndented = true,
31 DefaultIgnoreCondition = JsonIgnoreCondition.WhenWritingNull
32 });
33 }
34}