package dto // The customer app has no password and no PIN: it authenticates on a 4-digit // code sent to a phone or an email address, and its request shapes are declared // inline in controllers/cxAuthController.go alongside the handlers that read // them. The PIN register/login/verify/reset request types that used to live // here went with that flow. type MilerLoginRequest struct { Phone string `json:"phone" xml:"phone" form:"phone"` Configid int `json:"configid"` } type MilerPinVerifyRequest struct { Phone string `json:"phone" xml:"phone" form:"phone"` Pin string `json:"pin" xml:"pin" form:"pin"` Configid int `json:"configid"` DeviceToken string `json:"device_token"` } type MilerResetPinRequest struct { Phone string `json:"phone" xml:"phone" form:"phone"` NewPin string `json:"new_pin" xml:"new_pin" form:"new_pin"` Configid int `json:"configid"` } // MilerSetPinRequest is the self-service first-login PIN creation payload // (SetMilerPin). DeviceToken is accepted so the rider is fully logged in the // moment they set their PIN, without a second verify-pin round trip. type MilerSetPinRequest struct { Phone string `json:"phone" xml:"phone" form:"phone"` NewPin string `json:"new_pin" xml:"new_pin" form:"new_pin"` Configid int `json:"configid"` DeviceToken string `json:"device_token"` } type AdminLoginRequest struct { Email string `json:"email" xml:"email" form:"email"` Password string `json:"password" xml:"password" form:"password"` } type LoginResponse struct { Token string `json:"token"` User interface{} `json:"user"` }