Skip to content
Permalink
Browse files

change RequestContext Authorizer to a map[string]interface{}

  • Loading branch information...
tj committed May 13, 2018
1 parent b1d5f35 commit 831d3bfc76b738a72d0b596d26dea9062ddddeb9
Showing with 9 additions and 9 deletions.
  1. +9 −9 internal/proxy/event.go
@@ -18,15 +18,15 @@ type Identity struct {

// RequestContext is the contextual information provided by API Gateway.
type RequestContext struct {
APIID string `json:"apiId"`
ResourceID string `json:"resourceId"`
RequestID string `json:"requestId"`
HTTPMethod string `json:"-"`
ResourcePath string `json:"-"`
AccountID string `json:"accountId"`
Stage string `json:"stage"`
Identity Identity `json:"identity"`
Authorizer map[string]string `json:"authorizer"`
APIID string `json:"apiId"`
ResourceID string `json:"resourceId"`
RequestID string `json:"requestId"`
HTTPMethod string `json:"-"`
ResourcePath string `json:"-"`
AccountID string `json:"accountId"`
Stage string `json:"stage"`
Identity Identity `json:"identity"`
Authorizer map[string]interface{} `json:"authorizer"`
}

// Input is the input provided by API Gateway.

2 comments on commit 831d3bf

@kaihendry

This comment has been minimized.

Copy link

replied May 17, 2018

What is this used for or useful for ?

@tj

This comment has been minimized.

Copy link
Member Author

replied May 17, 2018

It's for the "Custom Authorizer" stuff, I just use custom JWT personally but for people who use API Gateway's I guess this map of values isn't always strings, I can't find decent docs on it though haha

Please sign in to comment.
You can’t perform that action at this time.