diff --git a/internal/config/service.go b/internal/config/service.go index 18d9b62..7e1e6a9 100644 --- a/internal/config/service.go +++ b/internal/config/service.go @@ -129,6 +129,11 @@ func (svc *Service) checkAndFormatInput(types []datatype.T) error { } svc.Query[queryName] = param + } else { + if svc.Form == nil { + svc.Form = make(map[string]*Parameter) + } + svc.Form[paramName] = param } // use param name if no rename diff --git a/internal/config/types.go b/internal/config/types.go index 7ce33c1..25be16b 100644 --- a/internal/config/types.go +++ b/internal/config/types.go @@ -31,6 +31,9 @@ type Service struct { // references to Query parameters // format: 'GET@paranName' Query map[string]*Parameter + + // references for form parameters (all but Captures and Query) + Form map[string]*Parameter } // Parameter represents a parameter definition (from api.json)