Learn more  » Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Bower components Debian packages RPM packages NuGet packages

skava / @skava-features/header   js

Repository URL to install this package:

Version: 0.1.7 

/ dist / src / state / session / container.apis.d.ts

/// <reference types="react" />
import ObservableContainer from 'src/bootstrapper/connectData/ObservableContainer';
import { Cart as ViewCartResponse, ResetBySecurityQuestionsResponse, UserActivationResponse, ResetPasswordResponse, ServerResponse as CreateSaveForLaterResponse, UserResponse as UserProfileResponse, TwitterAuthTokenResponse, UpdatePasswordResponse, GetSecurityQuestionResponse, AccountRegisterResponse, UserLoginInput, UpdatePasswordParams, RegistrationResponse, SecurityVerificationDetails, AccountRegisterInput, UpdateProfileInput, UpdateSecurityInput, ResetByEmailInput, ValidateByEmailInput, UserActivationInput, ResetBySecurityQuestions as ResetBySecurityQuestionsInput } from '@skava/graphql-bindings';
import { RecursiveRequired } from 'src/typings';
export declare type RegisterGuestResponse = {
    registerGuest: RecursiveRequired<AccountRegisterResponse>;
};
export declare type RegisterUserResponse = {
    registerUser: RecursiveRequired<AccountRegisterResponse>;
};
export declare type RegisterBusinessAccountResponse = {
    registerAccount: RecursiveRequired<AccountRegisterResponse>;
};
export declare type UpdateProfileResponse = {
    updateProfile: RecursiveRequired<AccountRegisterResponse>;
};
export declare type UpdateSecurityResponse = {
    updateSecurity: RecursiveRequired<RegistrationResponse>;
};
export declare type GetSecurityQuestionsResponse = {
    getSecurityQuestions: RecursiveRequired<GetSecurityQuestionResponse>;
};
export declare type UpdatePasswordResponseType = {
    updatePassword: RecursiveRequired<UpdatePasswordResponse>;
};
export declare type UserProfileResponseType = {
    profile: RecursiveRequired<UserProfileResponse>;
};
export declare type CreateSaveForLaterResponseType = {
    createSaveForLater: RecursiveRequired<CreateSaveForLaterResponse>;
};
export declare type TwitterAuthTokenResponseType = {
    twitterAuthToken: RecursiveRequired<TwitterAuthTokenResponse>;
};
export declare type ResetPasswordEmailResponseType = {
    resetByEmail: RecursiveRequired<ResetPasswordResponse>;
};
export declare type ResetPasswordTextResponseType = {
    resetBySms: RecursiveRequired<ResetPasswordResponse>;
};
export declare type ValidateEmailResponseType = {
    validateByEmail: RecursiveRequired<ResetPasswordResponse>;
};
export declare type UserActivationResponseType = {
    userActivation: RecursiveRequired<UserActivationResponse>;
};
export declare type ResetPasswordBySecurityQuestionResponseType = {
    resetPasswordBySecurityQuestions: RecursiveRequired<ResetBySecurityQuestionsResponse>;
};
export declare type SocialLoginResponseType = {
    socialLogin: RecursiveRequired<RegistrationResponse>;
};
export declare type LoginResponseType = {
    login: RecursiveRequired<RegistrationResponse>;
};
export declare type ViewCartResponseDataType = RecursiveRequired<ViewCartResponse>;
export declare type ViewCartResponseType = {
    cart: ViewCartResponseDataType;
};
declare class SessionApis extends ObservableContainer {
    static debugName: string;
    /**
     * @NOTE Temporary while debugginng @michael
     * @todo @FIXME @michael -- nothing is as permenant as temporary code
     *                       -- do it properly
     */
    registerGuestUser: () => Promise<any>;
    registerUser: (data: RegistrationResponse, securityParams: SecurityVerificationDetails) => Promise<any>;
    adminRegisterAccount: (data: AccountRegisterInput) => Promise<any>;
    updateProfile: (data: UpdateProfileInput) => Promise<any>;
    updateSecurity: (data: UpdateSecurityInput, isNewUser: boolean) => Promise<any>;
    getSecurityQuestions: (data: UpdateSecurityInput) => Promise<any>;
    updatePassword: (data: UpdatePasswordParams) => Promise<any>;
    resetPasswordThroughSms: (data: UpdateSecurityInput) => Promise<any>;
    resetPasswordThroughEmail: (data: ResetByEmailInput) => Promise<any>;
    validateByEmail: (data: ValidateByEmailInput) => Promise<any>;
    userActivation: (data: UserActivationInput) => Promise<any>;
    resetPasswordThroughSecurityQuestions: (data: ResetBySecurityQuestionsInput) => Promise<any>;
    logIn: (data: UserLoginInput) => Promise<any>;
    makeLoginCall: (input: UserLoginInput) => Promise<any>;
    loginWithGoogle: (authToken: string) => Promise<any>;
    loginWithTwitter: (authToken: string) => Promise<any>;
    loginWithFacebook: (authToken: string) => Promise<any>;
    fetchUserProfile: (shouldEnablePayment?: boolean, shouldGetAddress?: boolean) => Promise<any>;
    createList: () => Promise<void>;
    createSaveForLater: () => Promise<any>;
    fetchList: () => Promise<void>;
    fetchListItems: (listId: import("react").ReactText) => Promise<void>;
    /**
     * @see https://medium.com/@dai_shi/minimal-example-code-for-apollo-stack-7bd0cd2b7d7d
     */
    viewBag: () => Promise<any>;
    getTwitterAuthToken: () => Promise<any>;
}
declare const sessionApis: SessionApis;
export { sessionApis };
export { SessionApis };