Implement XAiMcpServer Stuffs ...
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using xAiModels.Constants;
|
||||
using xDataService.GraphQL;
|
||||
using xAiModels.Models.Entities;
|
||||
using xAiModels.Interfaces.Entities;
|
||||
|
||||
namespace xAiModels.Providers.GraphQL
|
||||
{
|
||||
public class XAiMcpServerGraphQLTypeHelper : XBaseGraphQLTypeHelper<XAiMcpServer, Guid>, IXAiMcpServerGraphQLTypeHelper
|
||||
{
|
||||
public override string GetInQueryCollectionName()
|
||||
{
|
||||
return XAiModelsConstants.XAiMcpServerCollectionName;
|
||||
}
|
||||
|
||||
public override string GetInQuerySingleName()
|
||||
{
|
||||
return XAiModelsConstants.XAiMcpServerSingleName;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using GraphQL.Types;
|
||||
using xDataService.GraphQL;
|
||||
using xAiModels.Models.Entities;
|
||||
using xDataService.Configuration;
|
||||
using xAiModels.Interfaces.Entities;
|
||||
|
||||
namespace xAiModels.Providers.GraphQL
|
||||
{
|
||||
public class XAiMcpServerGraphQuery : XBaseGraphQLQuery<XAiMcpServer, Guid, XAiMcpServerGraphType, GuidGraphType>
|
||||
{
|
||||
public XAiMcpServerGraphQuery(
|
||||
XDataServiceConfiguration configuration,
|
||||
IXAiMcpServerRepository repository,
|
||||
IXAiMcpServerGraphQLTypeHelper helper
|
||||
) : base(
|
||||
configuration,
|
||||
repository,
|
||||
helper
|
||||
)
|
||||
{ }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
using System;
|
||||
using GraphQL.Types;
|
||||
|
||||
namespace xAiModels.Providers.GraphQL
|
||||
{
|
||||
public class XAiMcpServerGraphSchema : Schema
|
||||
{
|
||||
public XAiMcpServerGraphSchema(IServiceProvider services) : base(services)
|
||||
{
|
||||
Query = (XAiMcpServerGraphQuery)services.GetService(typeof(XAiMcpServerGraphQuery));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using xDataService.GraphQL;
|
||||
using xAiModels.Models.Entities;
|
||||
|
||||
namespace xAiModels.Providers.GraphQL
|
||||
{
|
||||
public class XAiMcpServerGraphType: XBaseGraphObjectType<XAiMcpServer, Guid>
|
||||
{
|
||||
public XAiMcpServerGraphType() : base()
|
||||
{
|
||||
Field(x => x.Name);
|
||||
Field(x => x.Enabled);
|
||||
Field(x => x.OwnerId);
|
||||
Field(x => x.Headers);
|
||||
Field(x => x.Endpoint);
|
||||
Field(x => x.CreatedOn);
|
||||
Field(x => x.UpdatedAt);
|
||||
Field(x => x.Description);
|
||||
Field(x => x.TimeoutSeconds);
|
||||
Field(x => x.EnvironmentVariables);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user