daimon3332/OutlookRegister
Outlook/Hotmail account batch registration tool. Outlook / Hotmail 账号批量注册工具,支持自动获取 OAuth2 refresh_token
Featured achievements
The project's latest awards
#1 Repository of the week
#1 Repository of the week
#1 Repository of the week
OutlookRegister
Automated Outlook / Hotmail registration and Microsoft Graph OAuth2 refresh_token collection (browser automation via patchright).
Companion Projects
- Easy Proxies (Strongly recommended companion!!!!!!) — required for multi-port mode. Provides the local proxy pool consumed by OutlookRegister when
proxy.modeis set tomultiple. Start and configure Easy Proxies before running OutlookRegister in this mode. - OutlookManage — account management. Imports and manages registered Outlook accounts and their OAuth2 credentials.
- Outlook OAuth GetToken — standalone token retrieval. Obtains an OAuth2
refresh_tokenfor an existing Microsoft mailbox without running the registration workflow.
Community fork based on LainsNL/OutlookRegister.
This fork focuses on registration + OAuth2 hardening: recovery-email binding (optional), multi-stage login challenges, cookie-first OAuth, batching, and interrupt-safe summaries.
Getting started
1. Requirements
- Python 3.10+ recommended
- A working HTTP/SOCKS proxy (strongly recommended)
- Optional: a temp-mail / CF Temp Mail compatible API if you enable recovery-email binding
2. Install
git clone <this-repo-url>
cd OutlookRegister
pip install -r requirements.txt
patchright install chromium
3. Configure
# Windows
copy config.example.json config.json
# Linux / macOS
cp config.example.json config.json
Edit config.json: set proxy at minimum. Leave secrets empty in any copy you publish.
4. Run
python main.py
Successful tokens are appended to Results/oauth2.txt:
email----password----client_id----refresh_token
Logs are written under log/. Press Ctrl+C to stop; the process writes a summary, then cleans browsers/profiles.
config.json field reference
Ship template: config.example.json (same shape as the empty config.json).
Top-level
| Field | Type | Description |
|---|---|---|
email_suffix | string | Mail domain suffix used when generating accounts, e.g. @outlook.com or @hotmail.com. |
headless | bool | false = show browser windows; true = headless. |
bot_protection_wait | number | Base pacing for form fill (seconds). Code multiplies by 1000 for delays. |
max_captcha_retries | number | Extra press/retry rounds for the press-and-hold captcha (about max_captcha_retries + 1 hold attempts). |
captcha_strategy | number | Captcha / handoff mode (see table below). |
concurrent_flows | number | Concurrent worker threads (parallel browsers). |
tasks | number | Global cap on submitted tasks. Stops when this or success_tasks is reached (whichever first). |
success_tasks | number | null | Global success cap. null = no success cap (still limited by tasks). |
batch_success_limit | number | Successes per batch before resetting in-process proxy weights / stats and starting the next batch. Cumulative success/time keep counting. Does not change a fixed proxy’s real exit IP. |
proxy | object | Proxy pool (required for real use). |
oauth2 | object | Graph OAuth2 settings. |
temp_mail | object | Optional recovery-email binding via temp-mail API. |
captcha_strategy
| Value | Behavior |
|---|---|
0 | Fully automatic (captcha + mailbox + OAuth). |
1 | Semi-automatic: you press captcha; rest automatic. |
2 | Hand-off after captcha UI appears; no program OAuth for that task. |
proxy
| Field | Type | Description |
|---|---|---|
mode | string | single = one port (single_port); multiple = port range port_start…port_end. |
type | string | Proxy scheme, e.g. http, socks5. |
host | string | Proxy host, e.g. 127.0.0.1. Fill this before running. |
single_port | number | Port when mode is single. |
port_start | number | First port when mode is multiple. |
port_end | number | Last port when mode is multiple (inclusive). |
max_per_proxy | number | Max times a port may be selected before it is skipped (usage counters reset when all ports are exhausted or a batch resets). |
oauth2
| Field | Type | Description |
|---|---|---|
enable_oauth2 | bool | If false, registration success alone counts without fetching tokens. |
client_id | string | Azure/public client id used for authorize + token exchange. |
redirect_url | string | Redirect URI registered for the client (default http://localhost). |
Scopes | string[] | OAuth scopes, typically offline_access + Graph default. |
temp_mail
Used only if Microsoft shows “Help us protect your account” and binding is enabled.
| Field | Type | Description |
|---|---|---|
enabled | bool | false = never auto-bind recovery mail (skip path when the page appears). |
base_url | string | Temp-mail API base URL (your deployment). Leave empty if unused. |
admin_password | string | Admin password for creating addresses. Do not publish. |
domain | string | Mail domain for new addresses. |
name_prefix | string | Optional local-part prefix. |
enable_prefix | bool | Whether to apply name_prefix. |
code_timeout | number | Seconds to wait for a verification code email. |
poll_interval | number | Seconds between inbox polls. |
What it does
Generate email/password
-> open signup page
-> fill form
-> press-and-hold captcha
-> (optional) bind recovery email if Microsoft asks
-> enter Outlook mailbox
-> OAuth2 (cookie-first, then new browser with injected cookies)
-> append refresh_token to Results/oauth2.txt
OAuth handles common intermediate pages: personal/work account chooser, protect-account, email proof (or password path), KMSI “No”, consent, and code capture.
Key features
- Concurrent multi-proxy registration
- Batch success limit with in-process weight reset
- Cookie-first OAuth + cold/new-browser fallback with
storage_statewhen possible - Optional recovery-email binding via configurable temp-mail API
- Ctrl+C: write interrupt summary, then close browsers and clear profiles
- Failure breakdown and progress logs under
log/
Upstream and acknowledgements
- LainsNL/OutlookRegister — original project this fork is based on
- Microsoft identity platform / Graph — OAuth2 and Graph scopes
- patchright — browser automation
License
Distributed under the MIT License.
Attribution retained for upstream OutlookRegister and MIT-licensed portions this project builds on.
Community
linux.do: Learn AI on L-Station!!!- Nodeseek.com: Nodeseek is a place for people who love web development, hosting, vps / server and other geek things.
Similar Projects
Discover other similar projects and AI models.
Outlook/Hotmail local account management WebUI supports batch account import, status detection (alive/banned), token refresh and synchronization.Outlook / Hotmail 本地账号管理 WebUI,支持账号批量导入、状态检测(存活/封禁)、令牌刷新与同步。
A standalone OAuth2 refresh_token retrieval tool for existing Outlook / Hotmail accounts. 面向已有 Outlook / Hotmail 账号的独立 OAuth2 refresh_token 获取工具
Python tool for converting files and office documents to Markdown.
AutoGPT is the vision of accessible AI for everyone, to use and to build on. Our mission is to provide the tools, so that you can focus on what matters.