Step 1 of 8
Install OAuth dependencies
Add the required npm packages for Passport and the Google/GitHub strategies.
The project is a Node.js/Express app using npm. Assume a package.json already exists.
1. Open a terminal in the project root. 2. Execute `npm install passport passport-google-oauth20 passport-github2`. 3. Verify that the installation succeeded without errors. 4. Open package.json and confirm that the three new dependencies appear under "dependencies" with semantic version ranges. 5. Commit the updated package.json and package-lock.json (or yarn.lock) to version control.
Expected after this step
package.json lists passport, passport-google-oauth20, and passport-github2 under dependencies.
Should not happen
- ✕AI inserts placeholder client IDs or secrets instead of referencing process.env variables.
- ✕Strategy verify callbacks contain pseudo‑code or comments instead of real DB queries.
- ✕Passport initialization is omitted or serializeUser/deserializeUser are left as stubs.
- ✕Routes are described but not actually added to the Express app, or missing callbacks.
Verify before continuing
Do not move on until every check is true. The complete button stays locked until then.
Do not continue if…
- !AI inserts placeholder client IDs or secrets instead of referencing process.env variables.
- !Strategy verify callbacks contain pseudo‑code or comments instead of real DB queries.
- !Passport initialization is omitted or serializeUser/deserializeUser are left as stubs.
- !Routes are described but not actually added to the Express app, or missing callbacks.
- !User model is not updated, causing new users to lack provider data.
- !Self‑audit or PASS/FAIL statements are missing in aggressive prompts.
If the AI messes this up
Use this when the AI fakes progress or breaks the feature. It forces a real fix.
The AI only listed package names but did not modify package.json. Please edit package.json to actually add the three dependencies with proper version strings and show the updated file.