20

    20 days of showing up and indexing oneweek.dev logs on Google

    Ebru
    Ebru
    โ€ข2 min

    Today marks 20 consecutive days of showing up on oneweek.dev ๐ŸŽ‰

    To celebrate that small milestone, I focused on a bit of infrastructure work, adding pagination (?page=x) to the logs section, updating the sitemap.xml, and re-submitting it to Google Search Console.

    Since I didnโ€™t want each paginated view indexed separately, I kept it minimal, just enough for proper SEO crawling while keeping URLs clean.

    Then, I used a small Google Indexing API script I had written earlier to automate submitting recent logs directly to Google whenever needed.

    Itโ€™s simple, local, and gets the job done quickly. Hereโ€™s the Node.js script if you want to try it too:

    const { google } = require("googleapis");
    const fs = require("fs");
    
    // Load client secrets
    const credentials = JSON.parse(fs.readFileSync("credentials.json"));
    
    // Read URLs from file
    const urlsFilePath = "urls.txt"; // Path to your file
    const sitemapUrls = fs
      .readFileSync(urlsFilePath, "utf8")
      .split("\n")
      .filter(Boolean);
    
    async function authenticate() {
      const auth = new google.auth.GoogleAuth({
        credentials: {
          client_email: credentials.client_email,
          private_key: credentials.private_key,
        },
        scopes: ["https://www.googleapis.com/auth/indexing"],
      });
    
      return await auth.getClient();
    }
    
    async function notifyGoogle(auth, url) {
      const indexing = google.indexing({
        version: "v3",
        auth,
      });
    
      try {
        const res = await indexing.urlNotifications.publish({
          requestBody: {
            url: url,
            type: "URL_UPDATED",
          },
        });
        console.log(`โœ… Successfully notified Google about URL: ${url}`);
      } catch (error) {
        console.error(`โŒ Error notifying Google about URL: ${url}`, error);
      }
    }
    
    async function main() {
      const auth = await authenticate();
      for (const url of sitemapUrls) {
        await notifyGoogle(auth, url);
      }
    }
    
    main().catch(console.error);
    

    urls.txt

    https://oneweek.dev/log/2025-11-08-bringing-ambassador-program-for-genuine-growth
    https://oneweek.dev/log/2025-11-07-adding-app-store-data-and-platform-breakdown
    https://oneweek.dev/log/2025-11-06-publishing-the-advertise-page-on-our-finance-app
    

    credentials.json

    { "type": "service_account", "project_id": "xxx", "private_key_id": "xxxx", "private_key": "-----BEGIN PRIVATE KEY-----xxxx-----END PRIVATE KEY-----\n", "client_email": "xxxx", "client_id": "xxxx", "auth_uri": "https://accounts.google.com/o/oauth2/auth", "token_uri": "https://oauth2.googleapis.com/token", "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs", "client_x509_cert_url": "xxxx", "universe_domain": "googleapis.com" }
    

    It seems like it worked perfectly, all recent logs are now indexed!

    google logs indexed

    A small but satisfying improvement to make oneweek.dev more discoverable while keeping things fully manual for now and maker-friendly.

    If you'd like a quiet update once a week, join our tiny letter with weekly summary of learnings, findings, and what we're building.

    No spam, just genuine updates from our indie making journey.

    Or follow the journey on: