diff --git a/openapi.yaml b/openapi.yaml index 4cd86ec..e2124ca 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -557,7 +557,7 @@ components: cookieAuth: type: apiKey in: cookie - name: SESSIONID + name: session_id schemas: Id: required: diff --git a/pkg/api/oas_security_gen.go b/pkg/api/oas_security_gen.go index a9749fa..5f1eac3 100644 --- a/pkg/api/oas_security_gen.go +++ b/pkg/api/oas_security_gen.go @@ -35,7 +35,7 @@ func findAuthorization(h http.Header, prefix string) (string, bool) { func (s *Server) securityCookieAuth(ctx context.Context, operationName OperationName, req *http.Request) (context.Context, bool, error) { var t CookieAuth - const parameterName = "SESSIONID" + const parameterName = "session_id" var value string switch cookie, err := req.Cookie(parameterName); { case err == nil: // if NO error @@ -67,7 +67,7 @@ func (s *Client) securityCookieAuth(ctx context.Context, operationName Operation return errors.Wrap(err, "security source \"CookieAuth\"") } req.AddCookie(&http.Cookie{ - Name: "SESSIONID", + Name: "session_id", Value: t.APIKey, }) return nil