Run

sam build -pc && sam local start-api

Caveats

Cannot connect to Docker on localhost aws/aws-sam-cli#4329

To Read

How to connect to MongoDB with Golang

How to handle JSON in Go

Interfaces in Go

DBRef Specs