authApi: {
    register: (
        username: string,
        email: string,
        password: string,
        password2: string,
    ) => Promise<AxiosResponse<any, any, {}>>;
    login: (
        username: string,
        password: string,
    ) => Promise<AxiosResponse<any, any, {}>>;
    logout: () => Promise<AxiosResponse<any, any, {}>>;
    getCurrentUser: () => Promise<AxiosResponse<any, any, {}>>;
    getProfile: () => Promise<AxiosResponse<any, any, {}>>;
    updateProfile: (data: any) => Promise<AxiosResponse<any, any, {}>>;
    changePassword: (
        old_password: string,
        new_password: string,
        new_password2: string,
    ) => Promise<AxiosResponse<any, any, {}>>;
    getPreferences: () => Promise<AxiosResponse<any, any, {}>>;
    updatePreferences: (data: any) => Promise<AxiosResponse<any, any, {}>>;
} = ...

Type declaration

  • register: (
        username: string,
        email: string,
        password: string,
        password2: string,
    ) => Promise<AxiosResponse<any, any, {}>>
  • login: (username: string, password: string) => Promise<AxiosResponse<any, any, {}>>
  • logout: () => Promise<AxiosResponse<any, any, {}>>
  • getCurrentUser: () => Promise<AxiosResponse<any, any, {}>>
  • getProfile: () => Promise<AxiosResponse<any, any, {}>>
  • updateProfile: (data: any) => Promise<AxiosResponse<any, any, {}>>
  • changePassword: (
        old_password: string,
        new_password: string,
        new_password2: string,
    ) => Promise<AxiosResponse<any, any, {}>>
  • getPreferences: () => Promise<AxiosResponse<any, any, {}>>
  • updatePreferences: (data: any) => Promise<AxiosResponse<any, any, {}>>