InvocationWebSocketHandler.HandleAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before itβs released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Handles a POST /invocations request. Returns 404 Not Found
by default β override to add HTTP support alongside the WebSocket
endpoint.
public override System.Threading.Tasks.Task HandleAsync(Microsoft.AspNetCore.Http.HttpRequest request, Microsoft.AspNetCore.Http.HttpResponse response, Azure.AI.AgentServer.Invocations.InvocationContext context, System.Threading.CancellationToken cancellationToken);
override this.HandleAsync : Microsoft.AspNetCore.Http.HttpRequest * Microsoft.AspNetCore.Http.HttpResponse * Azure.AI.AgentServer.Invocations.InvocationContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overrides Function HandleAsync (request As HttpRequest, response As HttpResponse, context As InvocationContext, cancellationToken As CancellationToken) As Task
Parameters
- request
- HttpRequest
The incoming HTTP request.
- response
- HttpResponse
The outgoing HTTP response.
- context
- InvocationContext
Per-request context with resolved invocation/session IDs, headers, and query parameters.
- cancellationToken
- CancellationToken
A token to observe for cancellation.
Returns
A task representing the async operation.