🎉I was featured by Replit's CEO

My first experiment with Replit's AI Agent was retweeted by Amjad Masad.

⏱️Time’s flying so fast.

It’s already been 23 days since the previous edition of my newsletter.

I’ve been working on all sorts of coding projects: assisting a friend who’s about to release an amazing AI video creation platform (more about this very soon), working on Python automations connecting Airtable and WordPress, shipping new features for the AI Jingle Maker and also testing the mind-blowing AI Agent recently released by Replit.

My first published Chrome Extension

It all started with a nasty bug…

Last week, I noticed some issues in my Gmail account.

The contacts suggestion wasn’t working anymore when I was typing the email of a recipient in a new draft. Very annoying.

After some research, I found out that the bug had suddenly been caused by one of my favourite Chrome extensions, which I used to search and copy-paste emojis.

I was forced to deactivate the extension and remove it from Chrome, which solved my Gmail issue.

But I wanted to find another similar basic extension. Since I wasn’t able to get something which matched my expectations, I decided to code my own extension, which I called Easymoji. It was published yesterday on the Chrome Store. You can install it for free.

I coded the extension in less than one evening with ChatGPT.

The longest part was probably to generate the big JSON file featuring all the emojis 😯.

I needed to include 3 versions of my original icon (generated with MidJourney) in the package of my extension.

The problem is that you can’t export 16×16 and 48×48 pixels versions with Canva.

The minimum is 64×64.

I thought that I would easily find a nice resizing tool on the web but the only app I found was exporting the output as .ico files, which wasn’t what I wanted.

So, again, I decided to create my own little tool.

This time I opened Replit and prompted their brand new AI Agent to generate a simple web app.

Here is the prompt:

Create a Flask web app.
Use Tailwind CSS for styling (via CDN). 
The app should have the following functionality:
The index page includes a field to upload a PNG file.
The app automatically resizes the uploaded PNG to the following dimensions:
16x16 pixels
48x48 pixels
128x128 pixels
The three resized PNGs are displayed on the page, maintaining the correct proportions, along with a download button for each resized version.

I pressed on START BUILDING and the AI Agent generated all the folders and all the files before running the app, which opened straight in Replit.

🪄Right first time, nothing to change. Pure Black Magic!

Replit AI Agent

I was so impressed by the result that I immediately shared my enthusiasm with Replit’s CEO on Twitter.

He retweeted and commented my post, aptly mentioning that I was able to “make software faster than I could have googled it”.

You can fork the Repl via this link, it’s free.

💡 By the way, for all the geeks, there’s also a one line bash command to achieve the same result, which I got from my friend ChatGPT.

convert icon.png -resize 16x16 icon-16.png; convert icon.png -resize 48x48 icon-48.png; convert icon.png -resize 128x128 icon-128.png

I debugged a Gmail add-on with ChatGPT

I’ve just released for a client a(n AI-coded) micro SaaS, PACTIFY.IT, which enables you to extracts the takeaways from any Gmail thread and share the summary via email with all the thread participants, in one click.

The first step of the review process, which validated all the OAuth permissions, took quite a while (and required to get the app tested by a third-party service (TAC Security)).

Then we had to submit the app for review by the Workspace Marketplace team.

For some reason they kept on encountering the same bug, even if the app was working perfectly fine at our end.

I found in the Apps Script execution logs the “cause” of the bug:

Exception: Access denied: DriveApp.

Now, buckle up, we’re going Full Meta.

After some Perplexiting (the new Googling), I read on Google’s website that the reason was probably some kind of Drive API restriction in the Workspace environment of the tester.

The fact is that we needed to create a sharing link on Google Drive for the PDF containing the thread takeaways.

file.setSharing(DriveApp.Access.ANYONE_WITH_LINK, DriveApp.Permission.VIEW);

And ANYONE_WITH_LINK was the cause of the bug because the account of our tester at Google did not allow this level of permission.

So I asked my friend ChatGPT to give me the code to restrict access to the link to the participants in the thread (without sending them an instant notification, which would defeat the purpose of the add-on), which it did in a few seconds.

// Collect email addresses from the thread
var emailAddresses = collectEmailAddresses(thread);

emailAddresses.forEach(function(email) {
  try {
    // Use Drive API to add viewer without sending notification
    var permission = {
      'type': 'user',
      'role': 'reader', // Viewer permission
      'emailAddress': email
    };

    // Using Drive API to add permissions without sending notifications
    Drive.Permissions.create(
      permission,
      fileId, // The ID of the file you want to share
      {
        'sendNotificationEmail': false // Disable notification emails
      }
    );
  } catch (error) {
    Logger.log("Failed to add viewer permission for: " + email + ". Error: " + error.message);
  }
});

// Construct the PDF link
var pdfLink = `https://drive.google.com/file/d/${fileId}/view`;

This fresh code fixed the bug.

I finally received a message from my reviewer, telling me that the add-on was finally approved and would be published soon! Such a relief!

You can test the web app version of the product via pactify.it 

Bear in mind that it only retrieves the latest 25 threads of at least 3 messages.

And you can also install the app in Gmail via the Workspace Marketplace, right here.

It was published 5 minutes ago, while I was writing these lines.

I gave 5 stars to our reviewer for his cooperation!

I picked the EMOJI on the left!

Pactify.it is pretty cool if you want to get the gist of a long exchange of emails with your colleagues or with a supplier. I’ve also designed a simple UI where you can see all your “pactified” threads and some key data.

This was a small part of my busy week 🙂, assisted on a daily basis by ChatGPT, GitHub Copilot and Replit AI Agent.

One last thing: a talented (REAL) developer has just sent me a WhatsApp message praising Cursor.

So I HAVE TO TEST IT, asap.

Remember that if you have any questions about AI-assisted coding, I’m just one click away.

Simply REPLY to this email. I’ll do my best to assist you.

Stay Creative!

Frédérick