Bing Webmaster Index Now Script for Blogger

 <script>
    function sendIndexNowRequest() {
        var url = "https://www.bing.com/indexnow";
        var apiKey = "f869c984534f4c9f8b66a9f95a93fd31";

        var xmlPayload = `<?xml version="1.0" encoding="utf-8"?>
            <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
                <url>
                    <loc>https://www.pravinzende.co.in/2024/02/Navigating-the-Current.html</loc>
                </url>
                <url>
                    <loc>https://www.pravinzende.co.in/2024/02/Invalid%20Character%20Errors%20in%20Money%20Robot%20Software.html</loc>
                </url>
                <!-- Add more URLs as needed -->
            </urlset>`;

        var xhr = new XMLHttpRequest();
        xhr.open("POST", url + "?key=" + apiKey, true);
        xhr.setRequestHeader("Content-Type", "application/xml; charset=utf-8");

        xhr.onreadystatechange = function () {
            if (xhr.readyState == 4) {
                if (xhr.status == 200) {
                    console.log("IndexNow request successful");
                    console.log(xhr.responseText);
                } else {
                    console.error("IndexNow request failed");
                    console.error(xhr.status, xhr.statusText);
                }
            }
        };

        xhr.send(xmlPayload);
    }

    // Call the function when the page loads, or trigger it based on user action
    sendIndexNowRequest();
</script>