├── bg.png ├── logo-small.webp ├── manifest.json ├── custom.css ├── LICENSE ├── popup.js ├── README.md ├── popup.html └── background.js /bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/themorajr/ms-reward-bot/HEAD/bg.png -------------------------------------------------------------------------------- /logo-small.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/themorajr/ms-reward-bot/HEAD/logo-small.webp -------------------------------------------------------------------------------- /manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "manifest_version": 3, 3 | "name": "Bing Searcher", 4 | "version": "1.0.0", 5 | "description": "Searches Bing for random text 30 times", 6 | "background": { 7 | "service_worker": "background.js" 8 | }, 9 | "permissions": [ 10 | "tabs" 11 | ], 12 | "action": { 13 | "default_popup": "popup.html" 14 | } 15 | } -------------------------------------------------------------------------------- /custom.css: -------------------------------------------------------------------------------- 1 | body { 2 | font-family: Arial, sans-serif; 3 | text-align: center; 4 | width: 300px; 5 | padding: 15px; 6 | } 7 | h1 { 8 | font-size: 18px; 9 | margin-bottom: 15px; 10 | } 11 | img { 12 | width: 80px; 13 | height: auto; 14 | margin-bottom: 10px; 15 | } 16 | p { 17 | font-size: 14px; 18 | margin-bottom: 15px; 19 | } 20 | button { 21 | display: block; 22 | width: 100%; 23 | padding: 8px; 24 | margin-bottom: 10px; 25 | border: none; 26 | border-radius: 4px; 27 | cursor: pointer; 28 | font-size: 14px; 29 | } 30 | #startButton { background-color: #0078d4; color: white; } 31 | #mobileSearchButton { background-color: #00a4ef; color: white; } 32 | #stopButton { background-color: #d13438; color: white; } 33 | #emergencyStopButton { background-color: #ffb900; color: black; } 34 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2023 themorajr 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /popup.js: -------------------------------------------------------------------------------- 1 | document.addEventListener("DOMContentLoaded", () => { 2 | const startButton = document.getElementById("startButton"); 3 | const stopButton = document.getElementById("stopButton"); 4 | const emergencyStopButton = document.getElementById("emergencyStopButton"); 5 | const mobileSearchButton = document.getElementById("mobileSearchButton"); 6 | 7 | startButton.addEventListener("click", () => { 8 | chrome.runtime.sendMessage({ command: "start" }); 9 | startButton.disabled = true; 10 | stopButton.disabled = false; 11 | emergencyStopButton.disabled = false; 12 | mobileSearchButton.disabled = true; 13 | }); 14 | 15 | stopButton.addEventListener("click", () => { 16 | chrome.runtime.sendMessage({ command: "stop" }); 17 | startButton.disabled = false; 18 | stopButton.disabled = true; 19 | emergencyStopButton.disabled = true; 20 | mobileSearchButton.disabled = false; 21 | }); 22 | 23 | emergencyStopButton.addEventListener("click", () => { 24 | chrome.runtime.sendMessage({ command: "emergencyStop" }); 25 | startButton.disabled = false; 26 | stopButton.disabled = true; 27 | emergencyStopButton.disabled = true; 28 | mobileSearchButton.disabled = false; 29 | }); 30 | 31 | mobileSearchButton.addEventListener("click", () => { 32 | chrome.runtime.sendMessage({ command: "mobileSearch" }); 33 | mobileSearchButton.disabled = true; 34 | }); 35 | }); 36 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | # Bing Search Extension for MS Rewards 3 | 4 | This is a straightforward browser extension designed for Bing searches, streamlining the process of earning Microsoft Rewards points. The extension automates the search of random text on Bing, reaching the daily limit of 30 searches to maximize MS Rewards points. 5 | 6 | ## Compatibility 7 | The extension is compatible with both Chrome and Edge browsers. 8 | 9 | ## Installation 10 | 11 | 1. Clone or download this repository to your local machine. 12 | 2. Open the "Extensions" page in your browser by typing chrome://extensions/ for Chrome or edge://extensions/ for Edge. Ensure that "Developer mode" is enabled. 13 | 3. Click on the "Load unpacked" button and select the directory where the downloaded extension is located. 14 | 15 | ## Usage 16 | 17 | ### PC Search 18 | 19 | 1. Open Bing.com in your browser and make sure you are signed in to your Microsoft account. 20 | 2. Click on the extension icon in your browser. 21 | 3. The extension will automatically search random text 30 times on Bing, earning you MS Rewards points. 22 | 23 | ### Mobile Search [Not working, Will fix in next version] 24 | 25 | 1. To use Mobile Search, open Bing.com on your mobile device and sign in to your Microsoft account. 26 | 2. Copy the cookie value from your mobile browser. In Chrome, you can do this by going to the "Application" tab in the developer tools, expanding the "Cookies" section, and copying the value of the "MUID" cookie. 27 | 3. Paste the cookie value into the "cookie" variable in the `background.js` file. 28 | 4. Click on the extension icon in your browser. 29 | 5. The extension will automatically search random text 20 times on Bing, earning you MS Rewards points. 30 | 31 | ## Note 32 | 33 | If utilizing the Mobile Search feature, ensure to insert your cookie in the code before running the extension. 34 | -------------------------------------------------------------------------------- /popup.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Bing Searcher 7 | 42 | 43 | 44 | Bing Searcher Logo 45 |

Bing Searcher

46 |

Easily earn "Bing Rewards" coins with this tool. Supports both PC and Mobile searches.

47 | 48 | 49 | 50 | 51 | 52 | 71 | 72 | 73 | -------------------------------------------------------------------------------- /background.js: -------------------------------------------------------------------------------- 1 | // Constants 2 | const INTERVAL_DURATION = 2000; // 2 seconds 3 | const TAB_CLOSE_DELAY = 10000; // 10 seconds 4 | const DESKTOP_SEARCH_LIMIT = 40; 5 | const MOBILE_SEARCH_LIMIT = 25; 6 | const BADGE_TEXT = { 7 | ON: "ON", 8 | OFF: "", 9 | EMERGENCY: "!" 10 | }; 11 | 12 | // State 13 | let intervalId; 14 | let isRunning = false; 15 | 16 | // Utility functions 17 | const generateQuery = () => Math.random().toString(36).substring(2); 18 | 19 | const createTab = async (url) => { 20 | return new Promise((resolve) => { 21 | chrome.tabs.create({ url, active: false }, resolve); 22 | }); 23 | }; 24 | 25 | const closeTabAfterDelay = (tabId, delay) => { 26 | setTimeout(() => chrome.tabs.remove(tabId), delay); 27 | }; 28 | 29 | const updateBadge = (text, color = null) => { 30 | chrome.action.setBadgeText({ text }); 31 | if (color) chrome.action.setBadgeBackgroundColor({ color }); 32 | }; 33 | 34 | // Search functions 35 | const performSearch = async (searchUrl, limit) => { 36 | let counter = 0; 37 | intervalId = setInterval(async () => { 38 | const query = generateQuery(); 39 | const url = searchUrl(query); 40 | 41 | if (searchUrl === desktopSearchUrl) { 42 | const tab = await createTab(url); 43 | closeTabAfterDelay(tab.id, TAB_CLOSE_DELAY); 44 | } else { 45 | await fetch(url); 46 | } 47 | 48 | counter++; 49 | if (counter >= limit) stopSearch(); 50 | }, INTERVAL_DURATION); 51 | }; 52 | 53 | const desktopSearchUrl = (query) => `https://www.bing.com/search?q=${query}`; 54 | const mobileSearchUrl = (query) => `https://www.bing.com/search?q=${query}&PC=SANSAAND&form=LWS001&ssp=1&cc=XL&setlang=th&safesearch=moderate`; 55 | 56 | const performDesktopSearch = () => performSearch(desktopSearchUrl, DESKTOP_SEARCH_LIMIT); 57 | const performMobileSearch = () => performSearch(mobileSearchUrl, MOBILE_SEARCH_LIMIT); 58 | 59 | // Control functions 60 | const stopSearch = () => { 61 | clearInterval(intervalId); 62 | isRunning = false; 63 | updateBadge(BADGE_TEXT.OFF); 64 | }; 65 | 66 | const startSearch = (searchFunction) => { 67 | searchFunction(); 68 | isRunning = true; 69 | updateBadge(BADGE_TEXT.ON, "#008000"); 70 | }; 71 | 72 | const emergencyStop = () => { 73 | stopSearch(); 74 | updateBadge(BADGE_TEXT.EMERGENCY, "#ff0000"); 75 | }; 76 | 77 | // Event listeners 78 | chrome.action.onClicked.addListener(() => { 79 | isRunning ? stopSearch() : startSearch(performDesktopSearch); 80 | }); 81 | 82 | chrome.runtime.onMessage.addListener((message) => { 83 | switch (message.command) { 84 | case "start": 85 | startSearch(performDesktopSearch); 86 | break; 87 | case "stop": 88 | stopSearch(); 89 | break; 90 | case "emergencyStop": 91 | emergencyStop(); 92 | break; 93 | case "mobileSearch": 94 | startSearch(performMobileSearch); 95 | break; 96 | } 97 | }); 98 | --------------------------------------------------------------------------------