Home > @poq/sdk-sfcc > AccountService
IAccountService covers account specific operations such as user registration, login, logout, guest token generation and so.
Signature:
export declare class AccountService implements IAccountService
Implements: IAccountService
Constructor | Modifiers | Description |
---|---|---|
(constructor)(customersClient, sessionsClient, accountClient, profileConverter) | Constructs a new instance of the AccountService class |
Method | Modifiers | Description |
---|---|---|
createGuestToken() | Creates an access token and a refresh token for a guest user. | |
getContent(_appIdentifier, appId, token, platform) | Method returns profile information and My Account page content blocks. | |
getCookies(_appIdentifier, token) | Method returns session cookies. | |
getProfile(token) | Method returns profile for a specific user. | |
login(appIdentifier, loginParams) | Method handles login operation for a user. | |
logout(token) | Method handles user logout. | |
refreshToken(appIdentifier, existingRefreshToken) | Method refreshes the access token and returns a new access token and a new refresh token. | |
register(appIdentifier, guestToken, registerParams) | Method handles registration operation for a specific user. | |
updateProfile(token, profileParams) | Method handles user profile update operation. |