Class AccountEndpoint
java.lang.Object
com.maplander.backend.controller.endpoint.rv.AccountEndpoint
Endpoint with methods about account of UserML in MapLander application.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionactivateSearchML
(Long id) activeEmailSubs
(Long id) cancelEmailSubs
(Long id) createLead
(Long propertyId, Long userMLId, LeadTypeEnum type, String message, Long userId) createLeadLite
(Long propertyId, LeadTypeEnum type, UserML userML) createUserDefault
(String appleId, UserML userML) createUserML
(String appleId, UserML userML) Create a UserMLcreateUserMlLite
(UserML userML) deleteFavorite
(Long id) deleteSearches
(Long id) deleteSuggest
(Long id) deleteUserRV
(String email, Long userId) fixResendsendRequestInfoLite202307
(Long propertyId, Long userId, String message, UserML userML, boolean test) Deprecated.getCompleteProperty
(javax.servlet.http.HttpServletRequest request, WebSiteEnum webSite, DeviceTypeEnum device, Long id, Long userId, Boolean bot) getUserById
(Long id) listFavoriteByUser
(Long userId, Integer limit, String cursor) listProgress
(Integer maxModDate, Integer limit, String cursor) listSearchByUser
(Long userMLId, Integer limit, String cursor) listSearchByUserId
(Long userMLId, Integer limit, String cursor) listSuggest
(Long id, String cursor, Integer limit) refreshSuggestBySearchesML
(Long userSearchId, String cursor) saveSearch
(Integer limit, String cursor, SearchesML search) Save searchcom.google.api.server.spi.response.CollectionResponse
<PropertyLiteSuggest> searchFirstTime
(Integer limit, String cursor, SearchesML searchesML) sendRequestInfoLite
(Long propertyId, Long userId, String message, UserML userML) sendSignInLink
(String email) Sends an email with the link to enter and change password.signIn
(String email, String password, LanguageTypeEnum language, String token, DeviceTypeEnum type) Returns UserML with correct email and password (optional).signInApple
(String appleId, LanguageTypeEnum language, String token, DeviceTypeEnum type) signInLink
(String hash, String token, DeviceTypeEnum deviceType, LanguageTypeEnum language) signInWithLink
(Long id, String token, DeviceTypeEnum type) Returns UserML with correct valid and active Link with id.Deletes all DeviceML with token passed as a parameter.updateAndCleanSearchesML
(SearchesML searchesML) updateSearch
(SearchesML searchesML) updateSuggest
(PropertyLiteSuggest propertyLiteSuggest) updateUserML
(UserML userML) Update a UserMLviewPropertyEmail
(Long propertyId, Long userId)
-
Constructor Details
-
AccountEndpoint
public AccountEndpoint()
-
-
Method Details
-
createUserML
Create a UserML- Parameters:
userML
- UserML to be created- Returns:
- EntityResponse with UserML created.
HttpStatusCode.OK
,HttpStatusCode.BAD_REQUEST
HttpStatusCode.NOT_EXISTS
,HttpStatusCode.INTERNAL_SERVER_ERROR
-
createUserMlLite
-
createUserDefault
-
updateUserML
Update a UserML- Parameters:
userML
- userML to be updated- Returns:
- EntityResponse with UserML updated.
HttpStatusCode.OK
,HttpStatusCode.BAD_REQUEST
HttpStatusCode.NOT_EXISTS
,HttpStatusCode.INTERNAL_SERVER_ERROR
-
signIn
public EntityResponse<UserML> signIn(String email, String password, LanguageTypeEnum language, String token, DeviceTypeEnum type) Returns UserML with correct email and password (optional). In that case save a DeviceML with token and type passed as parameters.- Parameters:
email
- email of Userpassword
- password of UserML (can be null)language
- language of accounttoken
- token of Device (can be null)type
- type of Device- Returns:
- EntityResponse with User
HttpStatusCode.OK
,HttpStatusCode.BAD_REQUEST
,HttpStatusCode.NOT_EXISTS
,HttpStatusCode.INCORRECT_PASS
-
signInApple
public EntityResponse<UserML> signInApple(String appleId, LanguageTypeEnum language, String token, DeviceTypeEnum type) -
signOut
Deletes all DeviceML with token passed as a parameter.- Parameters:
token
- DeviceML token to be removed- Returns:
- DefaultResponse
HttpStatusCode.OK
,HttpStatusCode.BAD_REQUEST
,HttpStatusCode.NOT_EXISTS
-
sendSignInLink
Sends an email with the link to enter and change password.- Parameters:
email
- email to be sent.- Returns:
- DefaultResponse
HttpStatusCode.OK
,HttpStatusCode.BAD_REQUEST
,HttpStatusCode.NOT_EXISTS
,HttpStatusCode.INTERNAL_SERVER_ERROR
-
signInLink
public EntityResponse<UserML> signInLink(String hash, String token, DeviceTypeEnum deviceType, LanguageTypeEnum language) -
signInWithLink
Returns UserML with correct valid and active Link with id. In that case save a Device with token and type passed as parameters.- Parameters:
id
- id of Link to be validatedtoken
- device tokentype
- device type- Returns:
- EntityResponse with Person
HttpStatusCode.OK
,HttpStatusCode.NOT_EXISTS
-
getUserById
-
getCompleteProperty
public EntityResponse<CompleteProperty> getCompleteProperty(javax.servlet.http.HttpServletRequest request, WebSiteEnum webSite, DeviceTypeEnum device, Long id, Long userId, Boolean bot) -
viewPropertyEmail
-
createLead
public EntityResponse<Lead> createLead(Long propertyId, Long userMLId, LeadTypeEnum type, String message, Long userId) throws ParseException - Throws:
ParseException
-
sendRequestInfoLite
public DefaultResponse sendRequestInfoLite(Long propertyId, Long userId, String message, UserML userML) throws ParseException - Throws:
ParseException
-
fixResendsendRequestInfoLite202307
@Deprecated public DefaultResponse fixResendsendRequestInfoLite202307(Long propertyId, Long userId, String message, UserML userML, boolean test) throws ParseException Deprecated.- Throws:
ParseException
-
deleteFavorite
-
listFavoriteByUser
-
saveSearch
Save search- Parameters:
limit
- max limit of querycursor
- cursor of querysearch
- search to be save with type of property:PropertyTypeEnum
type of offering:OfferingTypeEnum
active for default is true activeEmail for default is true notification for default is true- Returns:
- EntityResponse with search save
HttpStatusCode.OK
,HttpStatusCode.BAD_REQUEST
,HttpStatusCode.INTERNAL_SERVER_ERROR
-
updateSearch
-
updateAndCleanSearchesML
-
listSearchByUser
public EntityCollectionResponse<SearchesML> listSearchByUser(Long userMLId, Integer limit, String cursor) -
archiveSearchesML
-
activateSearchML
-
cancelEmailSubs
-
activeEmailSubs
-
cancelNotifications
-
activeNotification
-
deleteSearches
-
listSearchByUserId
public EntityCollectionResponse<SearchesML> listSearchByUserId(Long userMLId, Integer limit, String cursor) -
listProgress
public EntityCollectionResponse<SearchesML> listProgress(Integer maxModDate, Integer limit, String cursor) -
updateSuggest
-
searchFirstTime
public com.google.api.server.spi.response.CollectionResponse<PropertyLiteSuggest> searchFirstTime(Integer limit, String cursor, SearchesML searchesML) -
listSuggest
public EntityCollectionResponse<PropertyLiteSuggest> listSuggest(Long id, String cursor, Integer limit) -
refreshSuggestBySearchesML
public EntityCollectionResponse<PropertyLiteSuggest> refreshSuggestBySearchesML(Long userSearchId, String cursor) -
deleteSuggest
-
createAdminDashBoard
-
deleteUserRV
-
createLeadLite
-