import { EnumBooleanStringified, JSONString } from "../../@types"; import { EnumProductId, usrKeyType } from "../channel"; import { ACTION } from "../command/action"; import { baseParamsType } from "../command/baseparams"; import { ICOMMAND, IKeyMaybeValue, IKeyValue, IRESPONSE, RESULT } from "../command/icommand"; /** * user information and abilities */ interface IUserInfo extends IKeyValue { /** product id readonly*/ productId?: EnumProductId; /** user Login/Name to show */ ualias?: string; /** user language, 2-symbol code lower case. "de", "en" */ language?: string; /** avatar url */ imgSrc?: string; /** avatar url sourceSet, ignored in SET-Commands */ imgSrcSet?: string; /** any json encoded string for client software */ payload?: JSONString; /** age verification status */ avs?: EnumBooleanStringified; /** abilities */ canSendMessage?: EnumBooleanStringified; canReceiveMessage?: EnumBooleanStringified; /** deprecated */ canSendImage?: EnumBooleanStringified; /** deprecated */ canReceiveImage?: EnumBooleanStringified; /** deprecated */ canSendAudio?: EnumBooleanStringified; /** deprecated */ canReceiveAudio?: EnumBooleanStringified; /** deprecated */ canSendVideo?: EnumBooleanStringified; /** deprecated */ canReceiveVideo?: EnumBooleanStringified; canSendMedia?: EnumBooleanStringified; canReceiveMedia?: EnumBooleanStringified; /** * @deprecated/obsolete */ canReceiveTicket?: EnumBooleanStringified; canOfferMedia?: EnumBooleanStringified; canPurchaseMedia?: EnumBooleanStringified; } export declare type translationType = { title: string; description: string; }; export declare type collectibleType = { id: number; imageUrl?: string; translations: Map; }; export declare type profileType = { name: string; signupDate: string; avatarUrl?: string; isVip: boolean; isVerified: boolean; selectedFrame?: collectibleType; selectedBadges?: collectibleType[]; }; /** * product "VOne" extra information and abilities */ export interface IUserInfoVOne extends IUserInfo { isVIP?: EnumBooleanStringified; canCall0900?: EnumBooleanStringified; canSingleSession?: EnumBooleanStringified; canBuyShopContent?: EnumBooleanStringified; canBeDiscounted?: EnumBooleanStringified; canSendGifts?: EnumBooleanStringified; canControlToy?: EnumBooleanStringified; canBeBan?: EnumBooleanStringified; profile?: JSONString; } /** * B2B basic user information */ export declare type IB2BUserInfo = IUserInfo; /** * B2B Vone user information */ export declare type IB2BUserInfoVOne = IUserInfoVOne; /** * user information transport object */ export declare class CMDC_USERINFO implements ICOMMAND { action: ACTION; params: { usrId: string; usrKey: string; } & (IB2BUserInfo | IB2BUserInfoVOne); } /** * B2B only * Create/Update user information in messenger system */ export declare class CMDP_SETUSERINFO implements ICOMMAND { action: ACTION; params: baseParamsType & usrKeyType & (IUserInfo | IUserInfoVOne); } /** * Response for CMDP_SETUSERINFO */ export declare class CMDP_SETUSERINFO_RESPONSE extends CMDP_SETUSERINFO implements IRESPONSE { result: RESULT; /** unused */ values: IKeyMaybeValue; /** unused */ commands: ICOMMAND[]; } /** * B2B only * Get user information in messenger system */ export declare class CMDP_GETUSERINFO implements ICOMMAND { action: ACTION; params: baseParamsType & { /** userKey */ usrKey: string; }; } /** * Response CMDP_GETUSERINFO */ export declare class CMDP_GETUSERINFO_RESPONSE extends CMDP_GETUSERINFO implements IRESPONSE { result: RESULT; /** unused */ values: IKeyMaybeValue; /** user info */ commands: CMDC_USERINFO[]; } export {};