{"library":"screepsmod-auth","title":"screepsmod-auth","description":"Screepsmod-auth is a mod for the Screeps private server that adds user/password authentication, enabling login via the API and web form. Version 2.8.2 is current, with low release cadence. It supports password setting via Steam client, server CLI, and GitHub OAuth. Configurable initial CPU and spawn blocking. Differentiates from default Steam-only auth by allowing custom credentials and GitHub login.","language":"javascript","status":"active","last_verified":"Sat Apr 25","install":{"commands":["npm install screepsmod-auth"],"cli":null},"imports":["import { authUser } from 'screepsmod-auth'","import { setPassword } from 'screepsmod-auth'","import { config } from 'screepsmod-auth'"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import { setPassword } from 'screepsmod-auth';\n\n// Via CLI: npx screeps cli\n// Then run: setPassword('Username', 'YourDesiredPassword')\n\n// Or in server config:\nimport { config } from 'screepsmod-auth';\nconfig.auth.authUser = async (username, password) => {\n  // custom auth logic\n  return username === 'admin' && password === 'secret' ? { username } : false;\n};","lang":"typescript","description":"Shows basic usage: set a password via CLI, and configure custom authUser function.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}