import { QueryList, QueryGet } from "../../schema/common";
import { InjectionFieldModuleRef } from "../../services";
import { DefaultServiceProps } from "../../utils";
export type OneTimeCodeModuleRef = InjectionFieldModuleRef;
export type OneTimeCodeServiceProps = DefaultServiceProps & OneTimeCodeModuleRef & {};
export declare const oneTimeCodeTypes: {
    readonly token: "token";
    readonly otp: "otp";
};
export type OneTimeCodeType = typeof oneTimeCodeTypes[keyof typeof oneTimeCodeTypes];
export declare const oneTimeCodeStatus: {
    readonly active: "active";
    readonly used: "used";
    readonly revoked: "revoked";
};
export type OneTimeCodeStatus = typeof oneTimeCodeStatus[keyof typeof oneTimeCodeStatus];
export declare const oneTimeCodePurposeTypes: {
    readonly reset_password: "reset_password";
    readonly signup_account: "signup_account";
};
export type OneTimeCodePurposeType = typeof oneTimeCodePurposeTypes[keyof typeof oneTimeCodePurposeTypes];
export type OneTimeCodeCreateProps = InjectionFieldModuleRef & {
    data: {
        purposeType: OneTimeCodePurposeType;
        codeType: OneTimeCodeType;
        expiredAt?: Date;
        mobileNumber?: string;
        emailAddress?: string;
        userId?: number;
        userType?: string;
    };
};
export type OneTimeCodeGetProps = QueryGet & {
    id: number;
};
export type OneTimeCodeListProps = QueryList & {
    revealCode?: boolean;
};
export type OneTimeCodeConsumeProps = InjectionFieldModuleRef & {
    data: {
        purposeType: OneTimeCodePurposeType;
        oneTimeCode: string;
        userId?: number;
        userType?: string;
    };
};
export declare const OneTimeCodeService: (props: OneTimeCodeServiceProps) => {
    createOneTimeCode: ({ data, field_ref: overrideFieldRef, field_module: overrideFieldModule }: OneTimeCodeCreateProps) => Promise<{
        createdatetime: Date | null;
        createuserid: bigint;
        updatedatetime: Date | null;
        updateuserid: bigint;
        isdelete: boolean | null;
        istrash: boolean | null;
        accountid: bigint;
        code: string;
        user_id: bigint | null;
        user_type: string | null;
        field_ref: string | null;
        field_module: string | null;
        one_time_code_id: bigint;
        code_type: string;
        email_address: string | null;
        mobile_number: string | null;
        expires_at: Date;
        used_at: Date | null;
        code_status: string | null;
        purpose_type: string | null;
    }>;
    getOneTimeCode: ({ id, datatypes }: OneTimeCodeGetProps) => Promise<any>;
    listOneTimeCodes: ({ limit, offset, filters, sortfield, sortorder, datatypes, revealCode }: OneTimeCodeListProps) => Promise<{
        data: any[];
        total: number;
    }>;
    consumeOneTimeCode: ({ data, field_ref: overrideFieldRef, field_module: overrideFieldModule }: OneTimeCodeConsumeProps) => Promise<any>;
};
