.NET 10 solution for Ping, a Discord style chat app: Domain, Application and Infrastructure projects plus the Api host. SignalR for chat and presence, LiveKit for call tokens, EF Core on Postgres, S3 compatible storage for attachments, and OIDC auth shared with the Musify Zitadel instance. Includes the Compose stack for local development.
13 lines
448 B
C#
13 lines
448 B
C#
using System.Text.Json.Serialization;
|
|
using Ping.Application.Serialization;
|
|
using Ping.Domain.Entities;
|
|
|
|
namespace Ping.Application.Servers.Responses
|
|
{
|
|
public record ServerResponse(Guid Id, string Name, string? IconUrl, [property: JsonConverter(typeof(LongAsStringConverter))] long OwnerId)
|
|
{
|
|
public static ServerResponse FromEntity(Server server) =>
|
|
new(server.Id, server.Name, server.IconUrl, server.OwnerId);
|
|
}
|
|
}
|