[Issue] Lambda LexEvent returns "null" values from Lex v2 Request


TL;DR: The "OrderFlowers" blueprint for Lex + Lambda on .NET Core 3.1 doesn't seem to work. Instead of populating the values for CurrentIntent and SlotDetails as expected, these values are null instead.

Note: Python and Node.js lambda equivalents seem to work just fine, but work use case requires .NET.


  • Goal: Setup blueprint "OrderFlowers" chatbot with AWS Lex v2 using .NET Core 3.1 and AWS Lambda. (Link)
  • This may be an issue with Lex v2 rather than with Lambda, but this may be unlikely as Python and Node.js work fine when interchanged with the .NET lambda used.


  • When invoking the OrderFlowers blueprint lambda function via AWS Lex, the LexEvent does not populate the expected fields, such as CurrentIntent and SlotDetails.
  • Compare this to using the Python or Node.js blueprints which do populate the expected fields.

Reproduction Steps

  1. Create a new .NET project using the "AWS Lambda Project (.NET Core - C#)" template with the "Order Flowers Chatbot" Blueprint.
  2. Log the lexEvent variable to CloudWatch within the FunctionHandler function: LambdaLogger.Log(JsonSerializer.Serialize(lexEvent));
  3. Publish the solution to AWS Lambda (default settings, arbitrary function name).
  4. Create a new Lex v2 Chatbot with the "Order Flowers Chatbot" Example.
  5. Configure the new chatbot to use the new lambda function you uploaded under Bot > Alias > Language.
  6. Under Intents > OrderFlowers > Fulfillment > Advanced Options, ensure "Use a Lambda function for fulfillment" is checked.
  7. Save the intent, build the bot, and test the conversation.
  8. An error should appear when attempting to fulfill the intent - when you check CloudWatch, the LexEvent body should appear with null values for fields such as CurrentIntent and SlotDetails.



Invalid Lambda Response: Received error response from Lambda: Unhandled


    "CurrentIntent": null,
    "SlotDetails": null,
    "Bot": {
        "Name": "OrderFlowersBot",
        "Alias": null,
        "Version": "DRAFT"
    "UserId": null,
    "InputTranscript": "yes",
    "InvocationSource": "FulfillmentCodeHook",
    "OutputDialogMode": null,
    "MessageVersion": "1.0",
    "SessionAttributes": null,
    "RequestAttributes": null,
    "AlternativeIntents": null,
    "SentimentResponse": null,
    "RecentIntentSummaryView": null,
    "ActiveContexts": null


  • Build Version: Amazon.Lambda.Core 2.1.0, Amazon.Lambda.LexEvents 3.0.0, Amazon.Lambda.Serialization.SystemText 2.2.0
  • OS Info: Windows 10 Enterprise
  • Build Environment: Visual Studio 2019
  • Targeted .NET Platform: .NET Core 3.1


  • There may be an issue serializing the incoming request from Lex v2 based on the configuration laid out in the current Order Flowers .NET 3.1 blueprint. To resolve this, effort will need to be made comparing the expected Lex v2 request payload with the actual payload and the serialization may have to be adjusted accordingly.
No Answers

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions