Handle Authentication and Authorization in xAiMcpServer ...
This commit is contained in:
@@ -20,6 +20,18 @@ namespace xAiModels.Attributes
|
||||
/// <value></value>
|
||||
public string Description { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Specify it's Required to Authenticated or not ...
|
||||
/// </summary>
|
||||
/// <value></value>
|
||||
public bool RequiresAuthentication { get; set; } = false;
|
||||
|
||||
/// <summary>
|
||||
/// Authorization and Policiy ...
|
||||
/// </summary>
|
||||
/// <value></value>
|
||||
public string RequiredPolicy { get; set; } = string.Empty;
|
||||
|
||||
public XAiMcpToolAttribute(string name = null)
|
||||
{
|
||||
Name = name;
|
||||
|
||||
@@ -10,6 +10,8 @@ namespace xAiModels.Models
|
||||
public string Name { get; set; }
|
||||
public string Description { get; set; }
|
||||
public JObject InputSchema { get; set; }
|
||||
public string RequiredPolicy { get; set; }
|
||||
public bool RequiresAuthentication { get; set; } = false;
|
||||
public Func<JObject, CancellationToken, Task<string>> Execute { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user