Click here to Skip to main content
15,904,655 members

Comments by Romain Latry (Top 1 by date)

Romain Latry 1-Oct-23 15:28pm View    
Thanks a lot OriginalGriff, really appreciate it!

Makes sense to build something basic that works first and then improve it? and get fancy.

I've been on the Google article you shared and explored a bit + asked Chat GPT what would be the steps to build that V1 add-on.

He said the following:


**Step 1: Setting Up Your Development Environment**

1. **Create a Google Cloud Project:**
- Go to the [Google Cloud Console](https://console.cloud.google.com/).
- Create a new project.
- Enable the "Google Workspace Add-ons API" for your project.

2. **Install the Required Tools:**
- You'll need a code editor (e.g., Visual Studio Code).
- Install Node.js and npm (Node Package Manager).

I'm there :))

3. **Set Up a Google Workspace Account:**
- You'll need a Google Workspace account to test your add-on. If you don't have one, you can use a personal Gmail account for testing.

**Step 2: Create a Basic Gmail Add-on**

1. **Clone the Gmail Add-on Starter Kit:**
- Google provides a [Gmail Add-on Starter Kit](https://github.com/googlesamples/gmail-addons-starter-kit) that you can use as a starting point. Clone or download it to your local machine.

2. **Set Up OAuth Credentials:**
- Follow the instructions in the Starter Kit's README to set up OAuth credentials. This will allow your add-on to access Gmail.

3. **Run the Starter Kit:**
- Follow the instructions in the README to run the starter kit. This will deploy a basic Gmail add-on that displays a card when you open an email.

**Step 3: Enhance the Add-on Based on Your Goals**

1. **Define Custom Interfaces:**
- Based on your goals of sorting, deleting, and gamifying the email management process, you'll need to create custom interfaces using the Apps Script Card service. These interfaces can include additional information, buttons, and progress bars.

2. **Automate Sorting:**
- Develop logic to sort emails based on criteria you define. For example, categorize emails as "Important" and "Not Important" based on sender, subject, or other factors.

3. **Automatically Delete Emails:**
- Define rules and conditions for what constitutes an unnecessary email. Use the Gmail API to delete these emails. Ensure that you handle this functionality with caution to avoid unintended data loss.

4. **Gamify the Process:**
- Add visual elements such as progress bars, badges, and icons to the user interface of your add-on. These elements can track the user's progress in managing their emails and provide a gamified experience.

**Step 4: Testing and Deployment**

1. **Testing:**
- Test your enhanced add-on extensively to ensure it works as expected. Use a test Gmail account to avoid affecting your real email.

2. **Deployment:**
- When you're satisfied with your add-on, you can deploy it to the Google Workspace Marketplace so others can use it. Follow Google's documentation on how to [publish an add-on](https://developers.google.com/gmail/add-ons/how-tos/publish) for more information.

Remember that creating a Gmail add-on with advanced features like automatic email deletion requires a deep understanding of the Gmail API, OAuth2 authentication, and coding skills. If you're not familiar with coding, you may need to collaborate with a developer or consider learning programming to implement these features effectively and securely. Always handle user data and email deletion with caution to avoid unintended consequences.


Does that make sense for you?

In order to get through all this, are there any code language you would recommend to learn firsthand?

Thanks again for your help