Using APIGatewayCustomAuthorizerResponse and related objects from Amazon.Lambda.APIGatewayEvents would greatly simplify the dotnet example.
https://github.com/aws/aws-lambda-dotnet/blob/master/Libraries/src/Amazon.Lambda.APIGatewayEvents/APIGatewayCustomAuthorizerResponse.cs