in the event of lambda i am getting new and old images for any update in dynamo db .now in my new image have one property names as sourceDetails which can vary eg.(please note the string mentioned below is json
{'M': {'bucketName': {'S': 'postote-offers-bucket'}}}
or it be like for eg.
{'M': {'streamName': {'S': 'someStream'},{'limit': {'N': 10}}}
How can i parse this result in best possible way