Local tools and a lightweight web console for managing NodeLoc OIDC ChatGPT accounts and importing them into Sub2 / Sub2API.
This project wraps three operational flows:
- Manage OIDC-backed
@fuckoai.oooooooooo.bondaccounts - Warm up a fresh account by logging it into ChatGPT in an incognito Chrome context
- Finalize Sub2 OpenAI OAuth by capturing the
localhost:1455callback and creating the corresponding OpenAI OAuth account inside Sub2
It also ships with a browser-based local control panel for:
- viewing OIDC accounts
- deleting/recreating a single test account
- running the full single-account end-to-end flow
- running only the third-step Sub2 finalization
- editing local machine-specific configuration in the UI
- checking environment health
outputs/
sub2_console/ local web console
start_sub2_console.ps1 stable console launcher
stop_sub2_console.ps1 stable console stopper
sub2_single_account_e2e.mjs full single-account E2E runner
run_sub2_single_account_e2e.ps1 PowerShell wrapper for full E2E runner
sub2_finalize_openai_oauth.mjs third-step-only finalizer
finalize_sub2_openai_oauth.ps1 PowerShell wrapper for third-step-only flow
nodeloc_api.py OIDC account CRUD wrapper
sub2_console.config.example.json machine-specific config template
sub2_portable/ portable distributable directory
- Windows
- Node.js 22+
- Python 3.10+
- Google Chrome
- A valid
NODELOC_NL_SESSIONin the workspace.env - A reachable Sub2 instance
- Install dependencies:
npm install- Create a workspace
.envfile containing at least:
NODELOC_NL_SESSION=your_real_nl_session_value- Copy the config template:
Copy-Item .\outputs\sub2_console.config.example.json .\outputs\sub2_console.config.json- Edit:
outputs/sub2_console.config.json
Set these values for your machine:
sub2ApiBaseUrloidcBaseUrldeployEnvPathchromePathdefaultE2EPortdefaultFinalizePortdefaultRunCountdefaultIntervalMinutesconnectionNamechatgptUrl
- Start the local console:
.\outputs\start_sub2_console.ps1- Open:
http://127.0.0.1:8788/
In the web console, click:
删光并只建 1 个账号
This deletes all current OIDC accounts and creates exactly one fresh account.
Use:
.\outputs\run_sub2_single_account_e2e.ps1Or click:
运行完整单账号闭环
The E2E runner will:
- delete all current OIDC accounts
- create exactly one new OIDC account
- open a fresh incognito Chrome with remote debugging
- warm up that account inside official ChatGPT
- generate a fresh Sub2 OpenAI OAuth link
- capture
http://localhost:1455/auth/callback?... - exchange the callback with Sub2
- create the OpenAI OAuth account in Sub2
Use this only after the first two steps were already completed in the same incognito Chrome context.
PowerShell:
.\outputs\finalize_sub2_openai_oauth.ps1 -Port 9251Or click:
只跑第三步补授权
The UI now exposes two related fields:
每批连续次数批次间隔分钟
Their meaning is:
每批连续次数 = N: one batch contains N back-to-back runs批次间隔分钟 = M: after that whole batch finishes, wait M minutes, then start the next batch
Example:
每批连续次数 = 3批次间隔分钟 = 5
Behavior:
- run 3 times in a row
- wait 5 minutes
- run 3 times again
- wait 5 minutes
- continue repeating
This is not "wait 5 minutes between each individual run".
If 批次间隔分钟 = 0, only one batch is executed.
The web console includes an environment self-check panel for:
- Node.js
- Python
- Chrome path
- workspace
.env NODELOC_NL_SESSION- Sub2
deploy/.env - local Sub2
/health - OIDC site reachability
- Do not commit your real
.env - Do not commit
NODELOC_NL_SESSION - Do not share
.nodeloc_managed_account.json/.nodeloc_managed_accounts.json - Do not share generated Chrome test profiles
The .gitignore already excludes these local/sensitive files.
There is also a prepared portable directory and zip:
outputs/sub2_portable/outputs/sub2_portable_bundle.zip
This is intended for handoff to another Windows machine.
Usually the console service is not running.
Start it:
.\outputs\start_sub2_console.ps1Stop it:
.\outputs\stop_sub2_console.ps1The project now guards against falsely treating the public homepage as a logged-in session. If this still happens, rerun the flow and inspect the task log panel.
The latest E2E flow already performs both:
/admin/openai/exchange-code/admin/accountscreate
If the UI still does not show the new account, inspect the run result table and the raw task log.
Minimal local commands:
npm install
npm run consoleAnd for syntax checks:
node --check .\outputs\sub2_single_account_e2e.mjs
node --check .\outputs\sub2_console\server.mjsThis project contains operational automation tailored for a specific NodeLoc OIDC + Sub2 workflow. Review every environment-specific path and endpoint before sharing it publicly.