Poridhi Lab Tracker is a productivity tool designed to help users efficiently track their progress on labs and modules within the poridhi.io platform. It consists of a browser user script and a Cloudflare Worker backend, making it easy to mark labs as complete/incomplete, sync progress, and manage your workflow seamlessly.
- Mark Labs/Modules as Done or Incomplete:
- Instantly mark any lab or module as completed or not directly from the poridhi.io UI.
- Progress Syncing:
- Your progress is securely synced to a Cloudflare Worker backend, so you can access your status from any device.
- Tampermonkey Integration:
- Simple user script installation for Chrome, Firefox, Edge, and more.
- Secure API Key Authentication:
- All API requests require a user-generated API key for security.
- Customizable Backend:
- Easily deploy your own Cloudflare Worker and control your data.
- User-Friendly Configuration:
- Set your API endpoint and key from the Tampermonkey menu.
- Open Source:
- Fully open for customization and self-hosting.
This project consists of two main components:
- Poridhi Lab Tracker User Script (for use with Tampermonkey)
- Cloudflare Worker API (backend service)
Follow the instructions below to set up both components for a seamless experience.
- Tampermonkey extension installed in your browser (Chrome, Firefox, Edge, etc.)
- The
poridhi_tracker.user.jsscript file from this repository
- Open Tampermonkey Dashboard in your browser.
- Click the "+" (Create a new script) button.
- Copy the contents of
poridhi_tracker.user.jsand paste it into the new script editor. - Save the script.
- API_HOST: Set this to the URL of your deployed Cloudflare Worker (see below for deployment instructions).
- API Key: After installing the script, go to poridhi.io, click the Tampermonkey icon, select the Poridhi Lab Tracker script, and use the menu to set your API key (generated in the Cloudflare Worker setup).
How to set API_HOST and API Key:
- Open the Tampermonkey dashboard.
- Find the Poridhi Lab Tracker script and click on it.
- Look for the script menu or settings (usually accessible via the script's menu icon or by right-clicking the script name).
- Enter your Cloudflare Worker URL as
API_HOSTand paste your API key.
- Email verified Cloudflare account
- Wrangler CLI installed (
npm install -g wrangler) - Node.js and npm installed
git clone <this-repo-url>
cd poridhi-lab-tracker/workernpm installUse openssl to generate a secure API key:
openssl rand -hex 32Copy the generated key. You will use this in both the worker and the user script.
Set the API key in your environment (replace <your-api-key> with the key you generated):
wrangler secret put API_KEYYou will be prompted to enter the value. Paste your API key and press Enter.
- Edit
wrangler.jsoncif needed to set your account and project details.
npx wrangler deployAfter deployment, note the worker URL (e.g., https://your-worker-name.your-account.workers.dev).
- In the Tampermonkey script, set
API_HOSTto your deployed worker URL. - Set the API key in the script menu as described above.
- CORS Issues: Tampermonkey will prompt you to allow cross-origin requests. Make sure to allow them for the worker URL.
- Invalid API Key: Double-check that the API key in Tampermonkey matches the one set in the worker.
- Deployment Errors: Check your Cloudflare account and wrangler configuration.
- Keep your API key secret. Do not share it publicly.
- Update your API key regularly to maintain security.
Enjoy!