{"id":73426,"library":"hertz-contrib-jwt","title":"Hertz JWT","description":"JWT authentication middleware for the Hertz HTTP framework.","status":"active","version":"1.0.4","language":"go","source_language":null,"source_url":"https://github.com/hertz-contrib/jwt","tags":["jwt","authentication","middleware","hertz"],"install":[{"cmd":"go get github.com/hertz-contrib/jwt","lang":"bash","label":"Install github.com/hertz-contrib/jwt"}],"dependencies":[],"imports":[{"symbol":"jwt","correct":"github.com/hertz-contrib/jwt"}],"quickstart":{"code":"package main\n\nimport (\n\t\"context\"\n\t\"github.com/cloudwego/hertz/pkg/app\"\n\t\"github.com/cloudwego/hertz/pkg/app/server\"\n\t\"github.com/hertz-contrib/jwt\"\n)\n\nfunc main() {\n\th := server.Default()\n\tauthMiddleware, _ := jwt.New(&jwt.HertzJWTMiddleware{\n\t\tRealm:       \"test zone\",\n\t\tKey:         []byte(\"secret key\"),\n\t\tTimeout:     jwt.DefaultTimeout,\n\t\tMaxRefresh:  jwt.DefaultMaxRefresh,\n\t\tAuthenticator: func(ctx context.Context, c *app.RequestContext) (interface{}, error) {\n\t\t\treturn nil, jwt.ErrMissingLoginValues\n\t\t},\n\t})\n\th.POST(\"/login\", authMiddleware.LoginHandler)\n\th.Spin()\n}","lang":"go","description":"Basic setup of JWT middleware for Hertz."},"warnings":[],"env_vars":null,"search_vec":"'authent':4,12 'framework':10 'hertz':1,8,14 'http':9 'jwt':2,3,11 'middlewar':5,13","created_at":"2026-06-17T18:51:02.392861+00:00","updated_at":"2026-06-17T18:51:02.392861+00:00","problems":[],"ecosystem":"go","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/hertz-contrib/jwt","github":"https://github.com/hertz-contrib/jwt","docs":"https://pkg.go.dev/github.com/hertz-contrib/jwt#section-documentation","changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["auth"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-17","next_check":"2026-12-14","install_tag":null}}