protected override async Task ExecuteCoreAsync(IExecutionContext executionContext, CancellationToken cancellationToken) { var functionId = _behavior.FunctionId; //Create an instance of the function to be called if (functionId == null) { throw new InvalidOperationException("No function was selected."); } //Get the values from the parameters... var parameters = await _behavior.GetParameterValuesAsync(executionContext, cancellationToken); //Execute the function await executionContext.ExecuteFunctionAsync(functionId.Value, parameters, cancellationToken); }