Signup delegates to service.SignUp, applies session/MFA cookie side-effects to the outgoing stream (grpc-gateway lifts them to Set-Cookie for REST callers), and projects the AuthResponse. Proto3 scalars carry no presence, so optional string inputs collapse empty -> nil via optionalString to match th
(ctx context.Context, req *authorizerv1.SignupRequest)
| 36 | // the GraphQL "field omitted" semantics. Signup is intentionally NOT MCP- |
| 37 | // exposed (it returns credentials). |
| 38 | func (h *AuthorizerHandler) Signup(ctx context.Context, req *authorizerv1.SignupRequest) (*authorizerv1.AuthResponse, error) { |
| 39 | res, side, err := h.Service.SignUp(ctx, transport.MetaFromGRPC(ctx), &model.SignUpRequest{ |
| 40 | Email: optionalString(req.Email), |
| 41 | PhoneNumber: optionalString(req.PhoneNumber), |
| 42 | Password: req.Password, |
| 43 | ConfirmPassword: req.ConfirmPassword, |
| 44 | GivenName: optionalString(req.GivenName), |
| 45 | FamilyName: optionalString(req.FamilyName), |
| 46 | MiddleName: optionalString(req.MiddleName), |
| 47 | Nickname: optionalString(req.Nickname), |
| 48 | Gender: optionalString(req.Gender), |
| 49 | Birthdate: optionalString(req.Birthdate), |
| 50 | Picture: optionalString(req.Picture), |
| 51 | Roles: req.Roles, |
| 52 | Scope: req.Scope, |
| 53 | RedirectURI: optionalString(req.RedirectUri), |
| 54 | IsMultiFactorAuthEnabled: &req.IsMultiFactorAuthEnabled, |
| 55 | State: optionalString(req.State), |
| 56 | AppData: appDataToMap(req.AppData), |
| 57 | }) |
| 58 | if err != nil { |
| 59 | return nil, err |
| 60 | } |
| 61 | _ = transport.ApplyToGRPC(ctx, side) |
| 62 | return projectAuthResponse(res), nil |
| 63 | } |
| 64 | |
| 65 | // Revoke delegates to service.Revoke and projects the result. |
| 66 | func (h *AuthorizerHandler) Revoke(ctx context.Context, req *authorizerv1.RevokeRequest) (*authorizerv1.RevokeResponse, error) { |
nothing calls this directly
no test coverage detected