import { Http } from '../utils/http'; import { InfobipAuth } from '../utils/auth'; import { TwoFAApplication, TwoFAMessageTemplate, TwoFAPinCode, Pin, TwoFAVerificationStatus } from '../models/2fa-models'; declare class TwoFA { http: Http; username?: string; password?: string; constructor(credentials: InfobipAuth); /** * An application is a container for 2FA message templates * Use this method to list your applications * * @return { AxiosResponse } response - Return Axios Response */ getApplications(): Promise; /** * Create and configure a new 2FA application * * @param { TwoFAApplication | any } reqBody - Create 2FA application * request body * @return { AxiosResponse } response - Return Axios Response */ createApplication(reqBody: TwoFAApplication | any): Promise; /** * Get a single 2FA application to see its configuration details * * @param { string } appId - ID of the 2FA application * @return { AxiosResponse } response - Return Axios Response */ getApplication(appId: string): Promise; /** * Change configuration options for your existing 2FA application * * @param { string } appId - ID of the 2FA application * @param { TwoFAApplication | any } reqBody - Change 2FA application * request body * @return { AxiosResponse } response - Return Axios Response */ updateApplication(appId: string, reqBody: TwoFAApplication | any): Promise; /** * List all message templates in a 2FA application * * @param { string } appId - ID of the 2FA application * @return { AxiosResponse } response - Return Axios Response */ getMessageTemplates(appId: string): Promise; /** * Once you have your 2FA application, create one or more message templates * where your PIN will be dynamically included when you send the PIN message. * * @param { string } appId - ID of the 2FA application * @param { TwoFAMessageTemplate | any } reqBody - Create message template * request body * @return { AxiosResponse } response - Return Axios Response */ createMessageTemplate(appId: string, reqBody: TwoFAMessageTemplate | any): Promise; /** * Get a single 2FA message template from an application to see its * configuration details. * * @param { string } appId - ID of the 2FA application * @param { string } messageId - ID of the message template * @return { AxiosResponse } response - Return Axios Response */ getMessageTemplate(appId: string, messageId: string): Promise; /** * Change configuration options for your existing 2FA application message * template. * * @param { string } appId - ID of the 2FA application * @param { string } messageId - ID of the message template * @param { TwoFAMessageTemplate | any } reqBody - Update message template * request body * @return { AxiosResponse } response - Return Axios Response */ updateMessageTemplate(appId: string, messageId: string, reqBody: TwoFAMessageTemplate | any): Promise; /** * Send a PIN code over SMS using a previously created message template * * @param { string } ncNeededQuery - Indicates if Number Lookup is needed * before sending the 2FA message. * @param { TwoFAPinCode | any } reqBody - Send PIN over SMS request body * @return { AxiosResponse } response - Return Axios Response */ sendPINCodeSMS(reqBody: TwoFAPinCode | any, ncNeededQuery?: boolean): Promise; /** * If needed, you can resend the same (previously sent) PIN code over SMS * * @param { string } pinId - ID of the pin code that has to be verified * @param { object | any } reqBody - Resend PIN over SMS request body * @return { AxiosResponse } response - Return Axios Response */ resendPINCodeSMS(pinId: string, reqBody?: object | any): Promise; /** * Send a PIN code over Voice using previously created message template * * @param { TwoFAPinCode | any } reqBody - Send PIN over Voice request body * @return { AxiosResponse } response - Return Axios Response */ sendPINCodeVoice(reqBody: TwoFAPinCode | any): Promise; /** * If needed, you can resend the same (previously sent) PIN code over Voice * * @param { string } pinId - ID of the pin code that has to be verified * @param { object | any } reqBody - Resend PIN over Voice request body * @return { AxiosResponse } response - Return Axios Response */ resendPINCodeVoice(pinId: string, reqBody?: object | any): Promise; /** * Verify a phone number to confirm successful 2FA authentication * * @param { string } pinId - ID of the pin code that has to be verified * @param { Pin | any } reqBody - Verify a phone number request body * The PIN code to verify * @return { AxiosResponse } response - Return Axios Response */ verifyPhoneNumber(pinId: string, reqBody: Pin | any): Promise; /** * Check if a phone number is already verified for a specific 2FA application * * @param { string } appId - ID of 2-FA application for which phone number * verification status is requested. * @param { TwoFAVerificationStatus | any } queryParameters - Get verification * status request query parameters. * @return { AxiosResponse } response - Return Axios Response */ getVerificationStatus(appId: string, queryParameters: TwoFAVerificationStatus | any): Promise; } export { TwoFA }; //# sourceMappingURL=2fa.d.ts.map