{"record":{"id":"42dabbd7d4e382cc","repo":"microsoft/semantic-kernel","slug":"the-proxy-step-can-only-handle-1-parameter-object-42dabb","errorCode":null,"errorMessage":"The proxy step can only handle 1 parameter object","messagePattern":"The proxy step can only handle 1 parameter object","errorType":"exception","errorClass":"KernelException","httpStatus":null,"severity":"error","filePath":"dotnet/src/Experimental/Process.Runtime.Dapr/Actors/ProxyActor.cs","lineNumber":41,"sourceCode":"    /// </summary>\n    /// <param name=\"host\">The Dapr host actor</param>\n    /// <param name=\"kernel\">An instance of <see cref=\"Kernel\"/></param>\n    public ProxyActor(ActorHost host, Kernel kernel)\n        : base(host, kernel)\n    {\n        this._logger = this._kernel.LoggerFactory?.CreateLogger(typeof(KernelProxyStep)) ?? new NullLogger<ProxyActor>();\n    }\n\n    internal override void AssignStepFunctionParameterValues(ProcessMessage message)\n    {\n        if (this._functions is null || this._inputs is null || this._initialInputs is null)\n        {\n            throw new KernelException(\"The step has not been initialized.\").Log(this._logger);\n        }\n\n        if (message.Values.Count != 1)\n        {\n            throw new KernelException(\"The proxy step can only handle 1 parameter object\").Log(this._logger);\n        }\n\n        // Add the message values to the inputs for the function\n        var kvp = message.Values.Single();\n        if (this._inputs.TryGetValue(message.FunctionName, out Dictionary<string, object?>? functionName) && functionName != null && functionName.TryGetValue(kvp.Key, out object? parameterName) && parameterName != null)\n        {\n            this._logger?.LogWarning(\"Step {StepName} already has input for {FunctionName}.{Key}, it is being overwritten with a message from Step named '{SourceId}'.\", this.Name, message.FunctionName, kvp.Key, message.SourceId);\n        }\n\n        if (!this._inputs.TryGetValue(message.FunctionName, out Dictionary<string, object?>? functionParameters))\n        {\n            this._inputs[message.FunctionName] = [];\n            functionParameters = this._inputs[message.FunctionName];\n        }\n\n        if (this._daprProxyInfo?.ProxyMetadata != null && message.SourceEventId != null && this._daprProxyInfo.ProxyMetadata.EventMetadata.TryGetValue(message.SourceEventId, out var metadata) && metadata != null)\n        {\n            functionParameters![kvp.Key] = KernelProcessProxyMessageFactory.CreateProxyMessage(this.ParentProcessId!, message.SourceEventId, metadata.TopicName, kvp.Value);","sourceCodeStart":23,"sourceCodeEnd":59,"githubUrl":"https://github.com/microsoft/semantic-kernel/blob/c028a0c7dc4f0814cdcbaba9d998f187a41197bf/dotnet/src/Experimental/Process.Runtime.Dapr/Actors/ProxyActor.cs#L23-L59","documentation":"ProxyActor.AssignStepFunctionParameterValues enforces that the incoming ProcessMessage carries exactly one value entry. The proxy step's single function (KernelProxyStep.EmitExternalEvent) accepts one parameter object, so messages with zero or multiple values are rejected as a contract violation.","triggerScenarios":"A ProcessMessage arrives at the ProxyActor with message.Values.Count != 1. The proxy step is designed to forward a single payload to an external topic, so any edge that maps multiple parameters to the EmitExternalEvent function, or sends an empty message, triggers this.","commonSituations":"An edge targeting the proxy step was configured with a function target whose parameter mapping produces multiple values. Also occurs when a custom step or test sends a manually-constructed ProcessMessage to the proxy with the wrong number of values.","solutions":["Ensure edges targeting the proxy step map exactly one parameter to the EmitExternalEvent function.","When constructing ProcessMessage objects for a proxy step manually, include exactly one key-value pair in the Values dictionary.","Review the ProxyMetadata.EventMetadata configuration to confirm each proxied event carries a single data payload."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// Ensure edges targeting the proxy step carry exactly one value:\n// The proxy step's EmitExternalEvent function takes one parameter.\n// When building edges, use OnEvent(...).SendToProxy(proxy, parameterName) or equivalent\n// that maps a single parameter.\n\n// If constructing messages manually:\nif (message.Values.Count != 1)\n{\n    throw new ArgumentException(\"Proxy step messages must contain exactly one value.\");\n}","typeGuard":null,"tryCatchPattern":"try\n{\n    await proxyStep.ProcessIncomingMessagesAsync();\n}\ncatch (KernelException ex) when (ex.Message.Contains(\"only handle 1 parameter\"))\n{\n    logger.LogError(\"Proxy step received a message with != 1 values. Check edge parameter mapping.\");\n}","preventionTips":["Configure edges to the proxy step with a single parameter mapping.","Never send multi-value or empty messages to a proxy step.","Review ProxyMetadata.EventMetadata to ensure each proxied event carries a single payload."],"tags":["dapr","process-runtime","proxy-step","message-contract","semantic-kernel"],"backgroundTag":null,"analyzedSha":"c028a0c7dc4f0814cdcbaba9d998f187a41197bf","analyzedAt":"2026-08-13T13:48:05.040Z","schemaVersion":2},"datasetVersion":"2026-08-13T14:17:21.547Z"}