Hello /r/aws, I just open-sourced my framework for developing APIs with lambda, will appreciate your feedback.

Thanks a lot for taking time to look into it and Happy Cake Day!!

why single function

Having a single lambda function also helps me to keep redundancy at a minimum and IMO keeps the project much more organized. All endpoints often need the same kind of db models and it feels quite useless to separate them into isolated blocks of code. The traditional resource based code structure feel more familiar.

Swagger export

This actually started the traditional way when I was writing swagger file to create API end-points in gateway console. Even without custom auth, it requires at least 1000 clicks on one API !! Importing swagger seems like a better option. I am still using swagger for API design. Just that now, I do not import it to Gateway and use swagger-codegen for generating client libraries. Swagger codegen supports oauth2 authentication and generates appropriate libraries unlike APIG codegen which only supports IAM auth and just three libraries.

custom authorization

The authorization features of APIG can be quite limited in its present state. API users are going to be from users table in mysql not AWS users. I needed an Oauth2 authorization which populates user information so that actual API code can use the user information.

Throttling per endpoint is a downside with cloudhopper. Isn't throttling per IP the only valid means of preventing abuse? With a regular rate-limit, any abuser will be able to reach the simple 2k per second rate and affect all other users.

different 'success' HTTP status codes for different methods

Custom HTTP status code are supported in current version. Just like in in express. The main code in this

res.status(404).json()

or

res.status(201).json({newObject})
/r/aws Thread Parent Link - github.com