12 references to McpApiKeyAuthenticationHandler
Aspire.Dashboard (9)
Components\Dialogs\McpServerDialog.razor.cs (2)
86
_mcpConfigProperties.Add(new McpConfigPropertyViewModel { Name = $"{
McpApiKeyAuthenticationHandler
.ApiKeyHeaderName} (header)", Value = DashboardOptions.Value.Mcp.PrimaryApiKey! });
114
[
McpApiKeyAuthenticationHandler
.ApiKeyHeaderName] = "${input:aspire_mcp_api_key}"
DashboardEndpointsBuilder.cs (1)
98
builder = endpoints.MapMcp("/mcp").RequireAuthorization(
McpApiKeyAuthenticationHandler
.PolicyName);
DashboardWebApplication.cs (4)
704
.AddScheme<McpApiKeyAuthenticationHandlerOptions,
McpApiKeyAuthenticationHandler
>(
McpApiKeyAuthenticationHandler
.AuthenticationScheme, o => { })
848
name:
McpApiKeyAuthenticationHandler
.PolicyName,
850
.RequireClaim(
McpApiKeyAuthenticationHandler
.McpClaimName, [bool.TrueString])
Mcp\McpCompositeAuthenticationHandler.cs (2)
34
var id = new ClaimsIdentity([new Claim(
McpApiKeyAuthenticationHandler
.McpClaimName, bool.TrueString)]);
44
yield return
McpApiKeyAuthenticationHandler
.AuthenticationScheme;
Aspire.Dashboard.Tests (3)
Integration\McpConfigurationTests.cs (2)
39
[
McpApiKeyAuthenticationHandler
.ApiKeyHeaderName] = "${input:x_mcp_api_key}"
103
[
McpApiKeyAuthenticationHandler
.ApiKeyHeaderName] = "${input:x_mcp_api_key}"
Integration\McpServiceTests.cs (1)
109
requestMessage.Headers.TryAddWithoutValidation(
McpApiKeyAuthenticationHandler
.ApiKeyHeaderName, apiKey);