tgstation-server 5.12.7
The /tg/station 13 server suite
Loading...
Searching...
No Matches
ChatBot.cs
Go to the documentation of this file.
1using System.Collections.Generic;
2using System.ComponentModel.DataAnnotations;
3using System.Linq;
4
6
8{
10 public sealed class ChatBot : Api.Models.Internal.ChatBotSettings, IApiTransformable<ChatBotResponse>
11 {
15 public const ushort DefaultChannelLimit = 100;
16
20 public long InstanceId { get; set; }
21
25 [Required]
26 public Instance Instance { get; set; }
27
31 public ICollection<ChatChannel> Channels { get; set; }
32
35 {
36 Channels = Channels.Select(x => x.ToApi(Provider.Value)).ToList(),
40 Id = Id,
41 Name = Name,
44 };
45 }
46}
virtual ? long Id
The ID of the entity.
Definition: EntityId.cs:13
ushort? ChannelLimit
The maximum number of ChatChannels the ChatBotSettings may contain.
bool? Enabled
If the connection is enabled.
string? ConnectionString
The information used to connect to the Provider.
ChatProvider? Provider
The ChatProvider used for the connection.
uint? ReconnectionInterval
The time interval in minutes the chat bot attempts to reconnect if Enabled and disconnected....
virtual ? string Name
The name of the entity represented by the NamedEntity.
Definition: NamedEntity.cs:16
ICollection< ChatChannel > Channels
See Api.Models.Internal.ChatBotApiBase.Channels.
Definition: ChatBot.cs:31
long InstanceId
The instance Api.Models.EntityId.Id.
Definition: ChatBot.cs:20
const ushort DefaultChannelLimit
Default for Api.Models.Internal.ChatBotSettings.ChannelLimit.
Definition: ChatBot.cs:15
Represents an Api.Models.Instance in the database.
Definition: Instance.cs:11
Represents a host-side model that may be transformed into a TApiModel .