Skip to content
ibrtPublic

About

Go framework for AWS Lambda.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Repository files navigation

mbd Build Status Go Report Card Test Coverage Go Docs

MBD is a Go framework for AWS Lambda, currently focused on the API Gateway integration. It wraps the official AWS Lambda framework and provides a simplified handler signature, case-insensitive access to headers, query string parameters, and other types of request metadata. It interoperates well with the ibrt/errors package to return configurable, rich error responses, optionally complete with debug information.

Basic Usage

package main

import (
  "github.com/ibrt/mbd"
)

type echoRequest struct {
  Value string `json:"value"`
}

type echoResponse struct {
  Value string `json:"value"`
} 

func main() {
  mbd.NewFunction(echoRequest{}, echoHandler).Start()
}

func(ctx context.Context, req interface{}) (interface{}, error) {
  echoRequest := req.(*echoRequest)
  return &echoResponse{Value: echoRequest.Value}, nil  
}

About

Go framework for AWS Lambda.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages

⌂ 换网址