Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ public static class AGUIEndpointRouteBuilderExtensions
/// <param name="pattern">The URL pattern for the endpoint.</param>
/// <param name="aiAgent">The agent instance.</param>
/// <returns>An <see cref="IEndpointConventionBuilder"/> for the mapped endpoint.</returns>
// Workaround: dotnet format does not respect IL2026/IL3050 with interceptors configuration. See https://github.com/dotnet/sdk/issues/51136
#pragma warning disable IL2026, IL3050
public static IEndpointConventionBuilder MapAGUI(
this IEndpointRouteBuilder endpoints,
[StringSyntax("route")] string pattern,
Expand Down Expand Up @@ -80,4 +82,5 @@ public static IEndpointConventionBuilder MapAGUI(
return new AGUIServerSentEventsResult(events, sseLogger);
});
}
#pragma warning restore IL2026, IL3050
}
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ public static IEndpointConventionBuilder MapOpenAIChatCompletions(this IEndpoint
/// <param name="endpoints">The <see cref="IEndpointRouteBuilder"/> to add the OpenAI ChatCompletions endpoints to.</param>
/// <param name="agent">The <see cref="AIAgent"/> instance to map the OpenAI ChatCompletions endpoints for.</param>
/// <param name="path">Custom route path for the chat completions endpoint.</param>
// Workaround: dotnet format does not respect IL2026/IL3050 with interceptors configuration. See https://github.com/dotnet/sdk/issues/51136
#pragma warning disable IL2026, IL3050
public static IEndpointConventionBuilder MapOpenAIChatCompletions(
this IEndpointRouteBuilder endpoints,
AIAgent agent,
Expand All @@ -69,4 +71,5 @@ public static IEndpointConventionBuilder MapOpenAIChatCompletions(

return group;
}
#pragma warning restore IL2026, IL3050
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ public static partial class MicrosoftAgentAIHostingOpenAIEndpointRouteBuilderExt
/// Maps OpenAI Conversations API endpoints to the specified <see cref="IEndpointRouteBuilder"/>.
/// </summary>
/// <param name="endpoints">The <see cref="IEndpointRouteBuilder"/> to add the OpenAI Conversations endpoints to.</param>
// Workaround: dotnet format does not respect IL2026/IL3050 with interceptors configuration. See https://github.com/dotnet/sdk/issues/51136
#pragma warning disable IL2026, IL3050
public static IEndpointConventionBuilder MapOpenAIConversations(this IEndpointRouteBuilder endpoints)
{
ArgumentNullException.ThrowIfNull(endpoints);
Expand Down Expand Up @@ -70,4 +72,5 @@ public static IEndpointConventionBuilder MapOpenAIConversations(this IEndpointRo

return group;
}
#pragma warning restore IL2026, IL3050
}
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ public static IEndpointConventionBuilder MapOpenAIResponses(this IEndpointRouteB
/// <param name="endpoints">The <see cref="IEndpointRouteBuilder"/> to add the OpenAI Responses endpoints to.</param>
/// <param name="agent">The <see cref="AIAgent"/> instance to map the OpenAI Responses endpoints for.</param>
/// <param name="responsesPath">Custom route path for the responses endpoint.</param>
// Workaround: dotnet format does not respect IL2026/IL3050 with interceptors configuration. See https://github.com/dotnet/sdk/issues/51136
#pragma warning disable IL2026, IL3050
public static IEndpointConventionBuilder MapOpenAIResponses(
this IEndpointRouteBuilder endpoints,
AIAgent agent,
Expand Down Expand Up @@ -105,6 +107,7 @@ public static IEndpointConventionBuilder MapOpenAIResponses(

return group;
}
#pragma warning restore IL2026, IL3050

/// <summary>
/// Maps OpenAI Responses API endpoints to the specified <see cref="IEndpointRouteBuilder"/>.
Expand All @@ -118,6 +121,8 @@ public static IEndpointConventionBuilder MapOpenAIResponses(this IEndpointRouteB
/// </summary>
/// <param name="endpoints">The <see cref="IEndpointRouteBuilder"/> to add the OpenAI Responses endpoints to.</param>
/// <param name="responsesPath">Custom route path for the responses endpoint.</param>
// Workaround: dotnet format does not respect IL2026/IL3050 with interceptors configuration. See https://github.com/dotnet/sdk/issues/51136
#pragma warning disable IL2026, IL3050
public static IEndpointConventionBuilder MapOpenAIResponses(
this IEndpointRouteBuilder endpoints,
[StringSyntax("Route")] string? responsesPath)
Expand Down Expand Up @@ -158,6 +163,7 @@ public static IEndpointConventionBuilder MapOpenAIResponses(

return group;
}
#pragma warning restore IL2026, IL3050

private static void ValidateAgentName([NotNull] string agentName)
{
Expand Down
Loading