mirror of
https://github.com/RedWizardsLab/EchoHub.git
synced 2026-09-06 15:46:03 +02:00
feat: Add invite codes and message replies functionality
- Introduced a new migration to add InviteCodes table and ReplyToMessageId column in Messages. - Updated ChatHub to support replying to messages. - Enhanced ChatService to handle message replies and validate reply targets. - Modified UserService to implement invite-only registration mode with invite code consumption. - Added configuration options for registration modes in appsettings. - Created unit tests for new features including invite code registration and message reply formatting.
This commit is contained in:
@@ -15,8 +15,9 @@ public interface IChatService
|
||||
|
||||
// Messaging. originConnectionId identifies the connection the message came from so
|
||||
// broadcasters can avoid echoing it back to that one connection (IRC convention);
|
||||
// the sender's other sessions still receive it.
|
||||
Task<string?> SendMessageAsync(Guid userId, string username, string channelName, string content, string? originConnectionId = null);
|
||||
// the sender's other sessions still receive it. replyToMessageId references the message
|
||||
// being replied to; it must exist in the same channel.
|
||||
Task<string?> SendMessageAsync(Guid userId, string username, string channelName, string content, string? originConnectionId = null, Guid? replyToMessageId = null);
|
||||
Task<List<MessageDto>> GetChannelHistoryAsync(string channelName, int count, int offset = 0);
|
||||
|
||||
// Presence
|
||||
|
||||
Reference in New Issue
Block a user