### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Configuration\Entities\XBotUserEntityConfiguration.cs using xBotService.Constants; using xDataService.Providers; using xBotService.Models.Entities; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Metadata.Builders; namespace xBotService.Configuration.Entities { public class XBotUserEntityConfiguration: XBaseEntityTypeConfiguration { public override void Configure(EntityTypeBuilder builder) { builder.ToTable(XBotServiceConstants.XBotUserTable); } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Constants\ConfigurationNodeNames.cs namespace xBotService.Constants { public partial struct ConfigurationNodeNames { public const string BOT_SERVICE_NODE = "BotServiceConfiguration"; } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Constants\XBotServiceConstants.cs namespace xBotService.Constants { public struct XBotServiceConstants { // // Bot Service Log Tag ... public const string XBotServiceDILogTag = "XBotService"; // // Table Mapping ... public const string XBotUserTable = "BotUsers"; // // GraphQL Mappings ... public const string XBotUserSingleName = "botUser"; public const string XBotUserCollectionName = "botUsers"; // // Hubs ... public const string XBotUserDtoHub = "botUserDto"; public const string XBotUserEntityHub = "botUserEntity"; // // Helper Method Names ... public const string GetXBotUserEFRepositoryDescriptor = "GetXBotUserEFRepositoryDescriptor"; } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\DI\XDIHelperExtension.cs using System; using xDataService.Db; using xDataService.DI; using xCommons.Helpers; using xCommons.Extensions; using xDataService.Models; using xExceptions.Constants; using xBotService.Constants; using xDataService.Constants; using XBotUserService.Helpers; using xHttpService.Interfaces; using xBotService.Providers.Dtos; using Microsoft.AspNetCore.Builder; using xBotService.Interfaces.Entities.Dtos; using Microsoft.Extensions.DependencyInjection; namespace xBotService.DI { public static class XDIHelperExtension { /// /// Register XBotService /// public static void AddXBotService( this IServiceCollection services, XRepositoryType repositoryType, ServiceLifetime lifeTime = ServiceLifetime.Scoped ) { AddBotService( contextType: null, services: services, lifeTime: lifeTime, repositoryType: repositoryType ); } /// /// Register XBotService with Context /// public static void AddXBotService( this IServiceCollection services, XRepositoryType repositoryType, ServiceLifetime lifeTime = ServiceLifetime.Scoped ) where TContext : XDbContext { AddBotService( services: services, lifeTime: lifeTime, contextType: typeof(TContext), repositoryType: repositoryType ); } /// /// Use XBotService Middleware /// public static void UseXBotService( this IApplicationBuilder app, bool isDevelopmentEnvironment = false ) { // Using XBot Repository Descriptor if (!descriptor.IsNull()) { app.UseXRepository( descriptor: descriptor, isDevelopmentEnvironment: isDevelopmentEnvironment ); } } // #region Private ... private static XRepositoryDescriptor descriptor = null; private static string XLogTag = XBotServiceConstants.XBotServiceDILogTag; private static void Log(string message) { Console.WriteLine($"{XLogTag} => {message}"); } private static void AddBotService( IServiceCollection services, XRepositoryType repositoryType, Type contextType = null, ServiceLifetime lifeTime = ServiceLifetime.Scoped ) { // var exception = XException.InvalidArgs.ToException(); // // Validate Services if (services.IsNull()) { // Log("Service Registration failed, services not provided ..."); throw exception; } // // Check Requirements ... var httpService = services.GetRegisteredService(); if (httpService.IsNull()) { // Log("Service Registration failed, HttpService not provided ..."); throw exception; } // // Validate Repository Type var isRepositoryTypeValid = (repositoryType == XRepositoryType.EF && !contextType.IsNull()) || ((repositoryType == XRepositoryType.Mongo || repositoryType == XRepositoryType.InMemory) && contextType.IsNull()); if (!isRepositoryTypeValid) { Log("Service Registration failed, Invalid Repository Type and Context Type ..."); throw exception; } // // Make Instance of Repository Descriptor switch (repositoryType) { case XRepositoryType.EF: descriptor = typeof(XBotServiceHelper) .InvokeGenericMethod( args: null, runtimeType: contextType, methodName: XBotServiceConstants.GetXBotUserEFRepositoryDescriptor ); break; case XRepositoryType.Mongo: // descriptor = XBotServiceHelper.GetXBotUserMongoRepositoryDescriptor(); Log("MongoDB support not implemented yet for XBotService."); break; case XRepositoryType.InMemory: // descriptor = XBotServiceHelper.GetXBotUserInMemoryRepositoryDescriptor(); Log("InMemory support not implemented yet for XBotService."); break; } // // Register XBotUser Repository Descriptor if (!descriptor.IsNull()) { services.AddXRepository(lifeTime: lifeTime, descriptor: descriptor); } // // Register Dto Services services.Add(new ServiceDescriptor(typeof(IXBotUserRepositoryService), typeof(XBotUserRepositoryService), lifeTime)); Log("XBotService Registration Succeed ..."); } #endregion } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Helper\XBotServiceHelper.cs using GraphQL.Types; using xDataService.Db; using xDataService.Models; using xDataService.Providers; using xBotService.Models.Entities; using xBotService.Providers.GraphQL; using xBotService.Providers.Entities; using xBotService.Interfaces.Entities; namespace XBotUserService.Helpers { public static class XBotServiceHelper { // #region EF Repository Descriptor Provider(s) ... public static XEFRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserEFRepository, TContext > GetXBotUserEFRepositoryDescriptor() where TContext : XDbContext { // var result = new XEFRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserEFRepository, TContext >(); // return result; } public static XEFRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserEFRepository, TContext, IXBotUserSeeder, TSeederImplementation > GetXBotUserEFRepositoryDescriptor() where TContext : XDbContext where TSeederImplementation : XBaseDbSeeder { // var result = new XEFRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserEFRepository, TContext, IXBotUserSeeder, TSeederImplementation >(); // return result; } #endregion // #region Mongo Repository Descriptor Provider(s) ... public static XMongoRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserMongoRepository > GetXBotUserMongoRepositoryDescriptor() { // var result = new XMongoRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserMongoRepository >(); // return result; } public static XMongoRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserMongoRepository, IXBotUserSeeder, TSeederImplementation > GetXBotUserMongoRepositoryDescriptor() where TSeederImplementation : XBaseDbSeeder { // var result = new XMongoRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserMongoRepository, IXBotUserSeeder, TSeederImplementation >(); // return result; } #endregion // #region InMemory Repository Descriptor Provider(s) ... public static XInMemoryRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserInMemoryRepository > GetXBotUserInMemoryRepositoryDescriptor() { // var result = new XInMemoryRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserInMemoryRepository >(); // return result; } public static XInMemoryRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserInMemoryRepository, IXBotUserSeeder, TSeederImplementation > GetXBotUserInMemoryRepositoryDescriptor() where TSeederImplementation : XBaseDbSeeder { // var result = new XInMemoryRepositoryDescriptor< XBotUser, int, IXBotUserKeyGenerator, XBotUserKeyGenerator, IXBotUserRepositoryEvents, XBotUserRepositoryEvents, XBotUserGraphType, IntGraphType, XBotUserGraphQuery, IXBotUserGraphQLTypeHelper, XBotUserGraphQLTypeHelper, XBotUserGraphSchema, IXBotUserRepository, XBotUserInMemoryRepository, IXBotUserSeeder, TSeederImplementation >(); // return result; } #endregion } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Interfaces\Dtos\IXBotUserDtoHub.cs using xBotService.Models.Dtos; using xPushService.Interfaces; using xBotService.Models.Entities; namespace xBotService.Interfaces.Dtos { public interface IXBotUserDtoHub : IXBaseDtoHub { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Interfaces\Dtos\IXBotUserRepositoryService.cs using xBotService.Models.Dtos; using xDataService.Interfaces; using xBotService.Models.Entities; namespace xBotService.Interfaces.Entities.Dtos { public interface IXBotUserRepositoryService : IXBaseRepositoryService { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Interfaces\Dtos\IXBotUserServiceProvider.cs using xBotService.Models.Dtos; using xPushService.Interfaces; using xBotService.Models.Entities; using xBotService.Providers.Dtos; namespace xBotService.Interfaces.Dtos { public interface IXBotUserServiceProvider : IXBaseDtoProvider { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Interfaces\Entities\IXBotUserEntityHub.cs using xPushService.Interfaces; using xBotService.Models.Entities; namespace xBotService.Interfaces.Entities { public interface IXBotUserEntityHub : IXBaseEntityHub { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Interfaces\Entities\IXBotUserGraphQLTypeHelper.cs using xDataService.Interfaces; using xBotService.Models.Entities; namespace xBotService.Interfaces.Entities { public interface IXBotUserGraphQLTypeHelper : IXBaseGraphQLTypeHelper { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Interfaces\Entities\IXBotUserKeyGenerator.cs using xDataService.Interfaces; using xBotService.Models.Entities; namespace xBotService.Interfaces.Entities { public interface IXBotUserKeyGenerator : IXKeyGenerator { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Interfaces\Entities\IXBotUserRepository.cs using xDataService.Interfaces; using xBotService.Models.Entities; namespace xBotService.Interfaces.Entities { public interface IXBotUserRepository : IXBaseRepository { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Interfaces\Entities\IXBotUserRepositoryEvents.cs using xDataService.Interfaces; using xBotService.Models.Entities; namespace xBotService.Interfaces.Entities { public interface IXBotUserRepositoryEvents : IXBaseRepositoryEvents { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Interfaces\Entities\IXBotUserRepositoryProvider.cs using xPushService.Interfaces; using xBotService.Models.Entities; using xBotService.Providers.Entities; namespace xBotService.Interfaces.Entities { public interface IXBotUserRepositoryProvider : IXBaseEntityProvider { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Interfaces\Entities\IXBotUserSeeder.cs using xDataService.Interfaces; using xBotService.Models.Entities; namespace xBotService.Interfaces.Entities { public interface IXBotUserSeeder: IXBaseDbSeeder { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Models\Dtos\XBotUserDto.cs using xModels.Base; using xModels.Dtos; namespace xBotService.Models.Dtos { /// /// Bot User / System User Relation ... /// public class XBotUserDto : XBaseIntIDEntityDto { /// /// User Id ... /// /// public string UserId { get; set; } /// /// System Person Information ... /// /// public virtual XPersonDto User { get; set; } = null; /// /// Chat Bot User Name ... /// /// public string BotUserName { get; set; } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Models\Entities\XBotUser.cs using xModels.Base; namespace xBotService.Models.Entities { /// /// Bot User / System User Relation ... /// public class XBotUser : XBaseIntIDEntity { /// /// User Id ... /// /// public string UserId { get; set; } /// /// Chat Bot User Name ... /// /// public string BotUserName { get; set; } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\XBotUserEntityRegisterar.cs using xDataService.Providers; using xDataService.Interfaces; using xBotService.Models.Entities; using Microsoft.EntityFrameworkCore; using xBotService.Configuration.Entities; namespace xBotService.Providers { public class XBotUserEntityRegisterar : XBaseEntityRegisterar, IXEntityRegisterar { public XBotUserEntityRegisterar() : base(nameof(XBotUserEntityRegisterar)) { // // Add XBotUser Entity ... AddEntity(); } /// /// Configure Entities ... /// /// public override void ConfigureEntities(ModelBuilder modelBuilder) { // // Configure Entity Using Provided ... modelBuilder .ApplyConfigurationsFromAssembly(typeof(XBotUserEntityConfiguration).Assembly); // base.ConfigureEntities(modelBuilder); } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\Dtos\XBotUserDtoHub.cs using xPushService.Base; using xBotService.Models.Dtos; using xBotService.Interfaces.Dtos; using xBotService.Models.Entities; using Microsoft.Extensions.Logging; namespace xBotService.Providers.Dtos { public class XBotUserDtoHub : XBaseDtoHub, IXBotUserDtoHub { public XBotUserDtoHub( ILogger logger ) : base(logger) { } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\Dtos\XBotUserRepositoryService.cs using AutoMapper; using xDataService.Providers; using xBotService.Models.Dtos; using xBotService.Models.Entities; using System.Collections.Generic; using xBotService.Interfaces.Entities; using xBotService.Interfaces.Entities.Dtos; namespace xBotService.Providers.Dtos { public class XBotUserRepositoryService : XBaseRepositoryService, IXBotUserRepositoryService { public XBotUserRepositoryService( IXBotUserRepository repository, IEnumerable mapperProfiles = null ) : base(repository, mapperProfiles) { } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\Dtos\XBotUserServiceProvider.cs using xPushService.Base; using xBotService.Models.Dtos; using xDataService.Configuration; using xBotService.Interfaces.Dtos; using xBotService.Models.Entities; using xIdentityService.Interfaces; using Microsoft.AspNetCore.SignalR; using xBotService.Interfaces.Entities.Dtos; namespace xBotService.Providers.Dtos { public class XBotUserServiceProvider : XBaseDtoProvider, IXBotUserServiceProvider { public XBotUserServiceProvider( IHubContext hub, XDataServiceConfiguration dataConfiguration, IXBotUserRepositoryService service, IXIdentityProvider identityProvider = null ) : base( hub, dataConfiguration, service, identityProvider ) { } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\Entities\XBotUserEFRepository.cs using xDataService.Db; using xDataService.Providers; using xDataService.Interfaces; using xDataService.Configuration; using xBotService.Models.Entities; using xBotService.Interfaces.Entities; namespace xBotService.Providers.Entities { public class XBotUserEFRepository : XBaseEFRepository, IXBotUserRepository where TContext : XDbContext { public XBotUserEFRepository( IXUnitOfWorks unitOfWorks, XDataServiceConfiguration configuration, IXBotUserKeyGenerator keyGenerator = null, IXBotUserRepositoryEvents baseRepositoryEvents = null ) : base(unitOfWorks, configuration, keyGenerator, baseRepositoryEvents) { } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\Entities\XBotUserEntityHub.cs using xPushService.Base; using xBotService.Models.Entities; using Microsoft.Extensions.Logging; using xBotService.Interfaces.Entities; namespace xBotService.Providers.Entities { public class XBotUserEntityHub : XBaseEntityHub, IXBotUserEntityHub { public XBotUserEntityHub( ILogger logger ) : base(logger) { } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\Entities\XBotUserInMemoryRepository.cs using xDataService.Providers; using xDataService.Configuration; using xBotService.Models.Entities; using xBotService.Interfaces.Entities; namespace xBotService.Providers.Entities { public class XBotUserInMemoryRepository : XBaseInMemoryRepository, IXBotUserRepository { public XBotUserInMemoryRepository( XDataServiceConfiguration configuration, IXBotUserKeyGenerator keyGenerator = null, IXBotUserRepositoryEvents baseRepositoryEvents = null ) : base( configuration, keyGenerator, baseRepositoryEvents ) { } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\Entities\XBotUserKeyGenerator.cs using xDataService.Providers; using xBotService.Models.Entities; using xBotService.Interfaces.Entities; namespace xBotService.Providers.Entities { public class XBotUserKeyGenerator : XIntKeyGenerator, IXBotUserKeyGenerator { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\Entities\XBotUserMongoRepository.cs using xDataService.Providers; using xDataService.Configuration; using xBotService.Models.Entities; using xBotService.Interfaces.Entities; namespace xBotService.Providers.Entities { public class XBotUserMongoRepository : XBaseMongoRepository, IXBotUserRepository { public XBotUserMongoRepository( XDataBaseConfiguration dbConfiguration, XDataServiceConfiguration configuration, string collectionName = null, IXBotUserKeyGenerator keyGenerator = null, IXBotUserRepositoryEvents baseRepositoryEvents = null ) : base( dbConfiguration, configuration, collectionName, keyGenerator, baseRepositoryEvents ) { } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\Entities\XBotUserRepositoryEvents.cs using xDataService.Providers; using xBotService.Models.Entities; using xBotService.Interfaces.Entities; namespace xBotService.Providers.Entities { public class XBotUserRepositoryEvents : XBaseRepositoryEvents, IXBotUserRepositoryEvents { } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\Entities\XBotUserSeederBase.cs using xDataService.Providers; using xDataService.Configuration; using xBotService.Models.Entities; using xBotService.Interfaces.Entities; namespace xBotService.Providers.Entities { public abstract class XBotUserSeederBase : XBaseDbSeeder, IXBotUserSeeder { protected XBotUserSeederBase( string entity, string database, IXBotUserRepository repository, XDataServiceConfiguration dataServiceConfiguration ) : base( entity, database, repository, dataServiceConfiguration ) { } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\GraphQL\XBotUserGraphQLTypeHelper.cs using xDataService.GraphQL; using xDataService.Configuration; using xBotService.Models.Entities; using xBotService.Interfaces.Entities; using xBotService.Constants; namespace xBotService.Providers.GraphQL { public class XBotUserGraphQLTypeHelper : XBaseGraphQLTypeHelper, IXBotUserGraphQLTypeHelper { public XBotUserGraphQLTypeHelper( XDataServiceConfiguration configuration ) : base(configuration) { } public override string GetInQueryCollectionName() { return XBotServiceConstants.XBotUserCollectionName; } public override string GetInQuerySingleName() { return XBotServiceConstants.XBotUserSingleName; } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\GraphQL\XBotUserGraphQuery.cs using GraphQL.Types; using xDataService.GraphQL; using xDataService.Configuration; using xBotService.Models.Entities; using xBotService.Interfaces.Entities; namespace xBotService.Providers.GraphQL { public class XBotUserGraphQuery : XBaseGraphQLQuery { public XBotUserGraphQuery( XDataServiceConfiguration configuration, IXBotUserRepository repository, IXBotUserGraphQLTypeHelper helper ) : base(configuration, repository, helper) { } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\GraphQL\XBotUserGraphSchema.cs using System; using GraphQL.Types; namespace xBotService.Providers.GraphQL { public class XBotUserGraphSchema : Schema { public XBotUserGraphSchema(IServiceProvider services) : base(services) { Query = (XBotUserGraphQuery)services.GetService(typeof(XBotUserGraphQuery)); } } } ### FILE: C:\Users\saherelm\Documents\Projects\xSaherelmWorkspace\Modules\xBotService\Providers\GraphQL\XBotUserGraphType.cs using xDataService.GraphQL; using xBotService.Models.Entities; namespace xBotService.Providers.GraphQL { public class XBotUserGraphType : XBaseGraphObjectType { public XBotUserGraphType() : base() { Field(x => x.UserId); Field(x => x.BotUserName); } } }