diff --git a/src/DMAPI/tgs/v5/_defines.dm b/src/DMAPI/tgs/v5/_defines.dm
index 1147817406..2f060b3a76 100644
--- a/src/DMAPI/tgs/v5/_defines.dm
+++ b/src/DMAPI/tgs/v5/_defines.dm
@@ -1,7 +1,7 @@
#define DMAPI5_PARAM_RUNTIME_INFORMATION_FILE "tgs_json"
#define DMAPI5_TOPIC_DATA "data"
-#define DMAPI5_BRIDGE_COMMAND_NEW_PORT 0
+#define DMAPI5_BRIDGE_COMMAND_PORT_UPDATE 0
#define DMAPI5_BRIDGE_COMMAND_VALIDATE 1
#define DMAPI5_BRIDGE_COMMAND_PRIME 2
#define DMAPI5_BRIDGE_COMMAND_REBOOT 3
@@ -10,8 +10,8 @@
#define DMAPI5_PARAMETER_ACCESS_IDENTIFIER "accessIdentifier"
-#define DMAPI5_BRIDGE_PARAMETER_COMMAND "commandType"
-#define DMAPI5_BRIDGE_PARAMETER_NEW_PORT "newPort"
+#define DMAPI5_BRIDGE_PARAMETER_COMMAND_TYPE "commandType"
+#define DMAPI5_BRIDGE_PARAMETER_CURRENT_PORT "currentPort"
#define DMAPI5_BRIDGE_PARAMETER_VERSION "version"
#define DMAPI5_BRIDGE_PARAMETER_CHAT_MESSAGE "chatMessage"
#define DMAPI5_BRIDGE_PARAMETER_MINIMUM_SECURITY_LEVEL "minimumSecurityLevel"
diff --git a/src/Tgstation.Server.Host/Components/Chat/ChatFactory.cs b/src/Tgstation.Server.Host/Components/Chat/ChatFactory.cs
index 15d353e644..83ef08518a 100644
--- a/src/Tgstation.Server.Host/Components/Chat/ChatFactory.cs
+++ b/src/Tgstation.Server.Host/Components/Chat/ChatFactory.cs
@@ -2,6 +2,7 @@
using System;
using System.Collections.Generic;
using Tgstation.Server.Host.Components.Chat.Commands;
+using Tgstation.Server.Host.Components.Chat.Providers;
using Tgstation.Server.Host.Core;
using Tgstation.Server.Host.IO;
diff --git a/src/Tgstation.Server.Host/Components/Chat/ChatUser.cs b/src/Tgstation.Server.Host/Components/Chat/ChatUser.cs
index f74f099fdd..981030528f 100644
--- a/src/Tgstation.Server.Host/Components/Chat/ChatUser.cs
+++ b/src/Tgstation.Server.Host/Components/Chat/ChatUser.cs
@@ -35,7 +35,7 @@ namespace Tgstation.Server.Host.Components.Chat
public string Mention { get; set; }
///
- /// The the user spoke from
+ /// The the user spoke from
///
public ChatChannel Channel { get; set; }
}
diff --git a/src/Tgstation.Server.Host/Components/InstanceFactory.cs b/src/Tgstation.Server.Host/Components/InstanceFactory.cs
index 78366142ee..b064babd4d 100644
--- a/src/Tgstation.Server.Host/Components/InstanceFactory.cs
+++ b/src/Tgstation.Server.Host/Components/InstanceFactory.cs
@@ -68,7 +68,7 @@ namespace Tgstation.Server.Host.Components
readonly IByondInstaller byondInstaller;
///
- /// The for the
+ /// The for the
///
readonly IChatFactory chatFactory;
diff --git a/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeCommandType.cs b/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeCommandType.cs
index 1736fc5b8d..c3b98605f8 100644
--- a/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeCommandType.cs
+++ b/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeCommandType.cs
@@ -1,12 +1,38 @@
namespace Tgstation.Server.Host.Components.Interop.Bridge
{
+ ///
+ /// Represents the .
+ ///
public enum BridgeCommandType
{
- NewPort,
+ ///
+ /// DreamDaemon notifying us of its current port and requesting a change if necessary.
+ ///
+ PortUpdate,
+
+ ///
+ /// DreamDaemon responding to an API validation request.
+ ///
Validate,
+
+ ///
+ /// DreamDaemon notifying the server is primed
+ ///
Prime,
+
+ ///
+ /// DreamDaemon notifiying the server is calling /world/Reboot().
+ ///
Reboot,
+
+ ///
+ /// DreamDaemon requesting the process be terminated.
+ ///
Kill,
+
+ ///
+ /// DreamDaemon requesting a be sent.
+ ///
ChatSend
}
}
diff --git a/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeParameters.cs b/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeParameters.cs
index 7d84cd8fc0..64800b15a0 100644
--- a/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeParameters.cs
+++ b/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeParameters.cs
@@ -3,16 +3,34 @@ using Tgstation.Server.Api.Models;
namespace Tgstation.Server.Host.Components.Interop.Bridge
{
+ ///
+ /// Parameters for a bridge request.
+ ///
public sealed class BridgeParameters : DMApiParameters
{
+ ///
+ /// The .
+ ///
public BridgeCommandType? CommandType { get; set; }
- public ushort? NewPort { get; set; }
+ ///
+ /// The current port for requests.
+ ///
+ public ushort? CurrentPort { get; set; }
+ ///
+ /// The DMAPI for requests.
+ ///
public Version Version { get; set; }
- public ChatMessage ChatMessage { get; set; }
-
+ ///
+ /// The minimum required level for requests.
+ ///
public DreamDaemonSecurity? MinimumSecurityLevel { get; set; }
+
+ ///
+ /// The for requests.
+ ///
+ public ChatMessage ChatMessage { get; set; }
}
}
diff --git a/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeResponse.cs b/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeResponse.cs
index 50c231f3e1..76801de132 100644
--- a/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeResponse.cs
+++ b/src/Tgstation.Server.Host/Components/Interop/Bridge/BridgeResponse.cs
@@ -1,8 +1,13 @@
namespace Tgstation.Server.Host.Components.Interop.Bridge
{
- public sealed class BridgeResponse
+ ///
+ /// A response to a bridge request.
+ ///
+ public sealed class BridgeResponse : DMApiResponse
{
- public string ErrorMessage { get; set; }
+ ///
+ /// The new port for requests.
+ ///
public ushort? NewPort { get; set; }
}
}
diff --git a/src/Tgstation.Server.Host/Components/Interop/ChatMessage.cs b/src/Tgstation.Server.Host/Components/Interop/ChatMessage.cs
index ca13d25ce0..826f0e99ec 100644
--- a/src/Tgstation.Server.Host/Components/Interop/ChatMessage.cs
+++ b/src/Tgstation.Server.Host/Components/Interop/ChatMessage.cs
@@ -2,10 +2,19 @@
namespace Tgstation.Server.Host.Components.Interop
{
+ ///
+ /// Represents a message to send to one or more s.
+ ///
public sealed class ChatMessage
{
+ ///
+ /// The message .
+ ///
public string Text { get; set; }
- public ICollection ChannelIds { get; set; }
+ ///
+ /// The of s to sent the to. Must be safe to parse as s.
+ ///
+ public ICollection ChannelIds { get; set; }
}
}
\ No newline at end of file
diff --git a/src/Tgstation.Server.Host/Components/Interop/DMApiParameters.cs b/src/Tgstation.Server.Host/Components/Interop/DMApiParameters.cs
index 22b8785be8..db63c8393d 100644
--- a/src/Tgstation.Server.Host/Components/Interop/DMApiParameters.cs
+++ b/src/Tgstation.Server.Host/Components/Interop/DMApiParameters.cs
@@ -1,7 +1,13 @@
namespace Tgstation.Server.Host.Components.Interop
{
- public class DMApiParameters
+ ///
+ /// Common base for interop parameters.
+ ///
+ public abstract class DMApiParameters
{
+ ///
+ /// The for interop.
+ ///
public string AccessIdentifier { get; set; }
}
}
diff --git a/src/Tgstation.Server.Host/Components/Interop/DMApiResponse.cs b/src/Tgstation.Server.Host/Components/Interop/DMApiResponse.cs
new file mode 100644
index 0000000000..bb1adf4925
--- /dev/null
+++ b/src/Tgstation.Server.Host/Components/Interop/DMApiResponse.cs
@@ -0,0 +1,13 @@
+namespace Tgstation.Server.Host.Components.Interop
+{
+ ///
+ /// Common base for interop responses.
+ ///
+ public abstract class DMApiResponse
+ {
+ ///
+ /// Any errors in the client's parameters.
+ ///
+ public string ErrorMessage { get; set; }
+ }
+}
diff --git a/src/Tgstation.Server.Host/Components/Interop/IBridgeHandler.cs b/src/Tgstation.Server.Host/Components/Interop/IBridgeHandler.cs
index c7f431a504..ed828ced12 100644
--- a/src/Tgstation.Server.Host/Components/Interop/IBridgeHandler.cs
+++ b/src/Tgstation.Server.Host/Components/Interop/IBridgeHandler.cs
@@ -7,7 +7,7 @@ namespace Tgstation.Server.Host.Components.Interop
interface IBridgeHandler : IBridgeHandlerBase
{
///
- /// The for the .
+ /// The for the .
///
string AccessIdentifier { get; }
diff --git a/src/Tgstation.Server.Host/Components/Interop/Topic/ChatCommand.cs b/src/Tgstation.Server.Host/Components/Interop/Topic/ChatCommand.cs
index ec9a8ea641..63e42f04f9 100644
--- a/src/Tgstation.Server.Host/Components/Interop/Topic/ChatCommand.cs
+++ b/src/Tgstation.Server.Host/Components/Interop/Topic/ChatCommand.cs
@@ -19,7 +19,7 @@ namespace Tgstation.Server.Host.Components.Interop.Topic
public string Params { get; }
///
- /// The that sent the command
+ /// The that sent the command
///
public ChatUser User { get; }
@@ -28,7 +28,7 @@ namespace Tgstation.Server.Host.Components.Interop.Topic
///
/// The value of .
/// The value of .
- /// The value of .
+ /// The value of .
public ChatCommand(ChatUser user, string command, string parameters)
{
User = user ?? throw new ArgumentNullException(nameof(user));
diff --git a/src/Tgstation.Server.Host/Components/Interop/Topic/EventNotification.cs b/src/Tgstation.Server.Host/Components/Interop/Topic/EventNotification.cs
index eb6db4236c..e9183f5787 100644
--- a/src/Tgstation.Server.Host/Components/Interop/Topic/EventNotification.cs
+++ b/src/Tgstation.Server.Host/Components/Interop/Topic/EventNotification.cs
@@ -3,16 +3,30 @@ using System.Linq;
namespace Tgstation.Server.Host.Components.Interop.Topic
{
+ ///
+ /// Data structure for requests.
+ ///
sealed class EventNotification
{
+ ///
+ /// The triggered.
+ ///
public EventType Type { get; }
+ ///
+ /// The set of parameters.
+ ///
public IReadOnlyCollection