···6969 * @param newEmail {string} - The new email for the new account
7070 * @param inviteCode {string|null} - The invite code for the new PDS if it requires one
7171 * @param cidToRestoreTo {string|null} - The cid of the plc op to restore to, used mostly to revert a fraudulent plc op. Want to give it the last valid operations cid
7272+ * @param verificationCode {string|null} - The verification code from the captcha/gate flow, required if the new PDS has phoneVerificationRequired
7273 * @param onStatus {function|null} - A function that takes a string used to update the UI. Like (status) => console.log(status)
7374 * @returns {Promise<void>} If there is a failure during restoring the back up (after the status Success! Restoring your repo...) then your account is most likely
7475 * recovered and future runs need to have the RestoreFromBackup flag set to true and AccountRecovery set to false.
···8384 newEmail,
8485 inviteCode,
8586 cidToRestoreTo = null,
8787+ verificationCode = null,
8688 onStatus = null,
8789 ) {
8890 if (onStatus) onStatus('Resolving your handle...')
···205207 }
206208 if (inviteCode) {
207209 createAccountRequest.inviteCode = inviteCode
210210+ }
211211+ if (verificationCode) {
212212+ createAccountRequest.verificationCode = verificationCode
208213 }
209214 const _ = await this.atpAgent.com.atproto.server.createAccount(createAccountRequest, {
210215 headers: { authorization: `Bearer ${serviceAuthToken}` },
···5454 * @param newEmail {string} - The new email for the new account
5555 * @param inviteCode {string|null} - The invite code for the new PDS if it requires one
5656 * @param cidToRestoreTo {string|null} - The cid of the plc op to restore to, used mostly to revert a fraudulent plc op. Want to give it the last valid operations cid
5757+ * @param verificationCode {string|null} - The verification code from the captcha/gate flow, required if the new PDS has phoneVerificationRequired
5758 * @param onStatus {function|null} - A function that takes a string used to update the UI. Like (status) => console.log(status)
5859 * @returns {Promise<void>} If there is a failure during restoring the back up (after the status Success! Restoring your repo...) then your account is most likely
5960 * recovered and future runs need to have the RestoreFromBackup flag set to true and AccountRecovery set to false.
6061 */
6161- recover(rotationKey: string, rotationKeyType: string, currentHandleOrDid: string, newPDS: string, newHandle: string, newPassword: string, newEmail: string, inviteCode: string | null, cidToRestoreTo?: string | null, onStatus?: Function | null): Promise<void>;
6262+ recover(rotationKey: string, rotationKeyType: string, currentHandleOrDid: string, newPDS: string, newHandle: string, newPassword: string, newEmail: string, inviteCode: string | null, cidToRestoreTo?: string | null, verificationCode?: string | null, onStatus?: Function | null): Promise<void>;
6263 /**
6364 * This method signs the plc operation over to the new PDS and activates the account
6465 * Assumes you have already created a new account during the recovery process and logged in