based-auth
Version:
A Next.js/Node.js authentication and wallet API kit for Ethereum and Solana, with utilities for serialization and contract interaction, designed for serverless and API route usage.
35 lines (34 loc) • 838 B
TypeScript
import { Document, Model, Types } from 'mongoose';
import { NetworkSymbols } from '../../../basedauth/src/networks';
import { UserRole } from '../types';
export interface IUserMetaInfo {
website: string;
twitter: string;
telegram: string;
discord: string;
}
export interface IUser {
network: NetworkSymbols;
address: string;
social: string;
provider: string;
}
export interface IUserProfile extends Document {
_id: Types.ObjectId;
id: string;
name: string;
bio: string;
image: string;
banner: string;
metaInfo: IUserMetaInfo;
role: UserRole;
lastNetwork: string;
lastSignedIn: Date;
lastAddress: string;
followers: {
network: string;
address: string;
}[];
users: IUser[];
}
export declare const UserProfileModel: Model<IUserProfile>;