A Chrome MV3 extension for detecting papers on publisher/preprint pages, checking whether they already exist on SciCommons, and saving them through the SciCommons integrations API.
The extension reads metadata from the current page first. When a DOI is found but important metadata is missing, it falls back to CrossRef to fill title, abstract, and authors before saving.
The extension supports two built-in environments:
- Local:
http://localhost:3000frontend andhttp://127.0.0.1:8000backend - Test:
https://test.scicommons.orgfrontend auth andhttps://backendtest.scicommons.orgAPI routing
Use the environment selector in the popup. Changing environments clears the stored extension token.
The extension no longer asks users to paste JWTs.
- Popup sends the user to
/auth/extensionwith a PKCE challenge. - The SciCommons web app uses the existing logged-in session or redirects to login.
- The backend creates a short-lived one-time extension auth code.
- The extension exchanges the code for API tokens.
- Tokens are stored only in
chrome.storage.localand are never sent to page JavaScript.
contentScript.js: reads public page metadata only.background.js: owns authentication, API calls, and the offline retry queue.popup.js: renders user confirmation controls and sends commands to the background worker.config.js: local/test environment configuration.
- Start the SciCommons backend on
http://127.0.0.1:8000. - Start the SciCommons frontend on
http://localhost:3000. - Open
chrome://extensions. - Enable Developer mode.
- Load this
extension/folder as an unpacked extension. - Open a paper page and use the popup to connect and save.
For test.scicommons.org, select the Test environment in the popup and reconnect. Test auth opens
https://test.scicommons.org; paper lookup/import requests go to
https://backendtest.scicommons.org.