1 write to FunctionCall
Microsoft.Extensions.AI.Abstractions (1)
Contents\FunctionApprovalResponseContent.cs (1)
29FunctionCall = Throw.IfNull(functionCall);
14 references to FunctionCall
Microsoft.Extensions.AI (7)
ChatCompletion\FunctionInvokingChatClient.cs (7)
1318_ = approvalRequestCallIds?.Remove(farc.FunctionCall.CallId); 1377if (functionResultCallIds?.Contains(approvalResponse.FunctionCall.CallId) is true) 1386_ = allApprovalRequestsMessages?.TryGetValue(approvalResponse.FunctionCall.CallId, out requestMessage); 1402rejections.ConvertAll(static m => (AIContent)new FunctionResultContent(m.Response.FunctionCall.CallId, "Error: Tool call invocation was rejected by user.")) : 1443currentMessage.Contents.Add(resultWithRequestMessage.Response.FunctionCall); 1472functionCallMessage.Contents = [resultWithRequestMessage.Response.FunctionCall]; 1628originalMessages, options, toolMap, notInvokedApprovals.Select(x => x.Response.FunctionCall).ToList(), 0, consecutiveErrorCount, isStreaming, cancellationToken);
Microsoft.Extensions.AI.Abstractions.Tests (7)
Contents\FunctionApprovalRequestContentTests.cs (1)
54Assert.Same(functionCall, response.FunctionCall);
Contents\FunctionApprovalResponseContentTests.cs (6)
35Assert.Same(functionCall, content.FunctionCall); 49Assert.NotNull(deserializedContent.FunctionCall); 50Assert.Equal(content.FunctionCall.CallId, deserializedContent.FunctionCall.CallId); 51Assert.Equal(content.FunctionCall.Name, deserializedContent.FunctionCall.Name);