AppsScriptPulse

Calling all Google Workspace developers! Apps Script Meetup at Google Cloud Next 2025

Calling all Google Workspace developers! Join us for a lively discussion on Apps Script, the cloud-based JavaScript platform that empowers you to automate tasks, connect services, and extend the functionality of your favorite Google apps. Whether you’re a seasoned Apps Script pro or just starting out, this session offers a space to share knowledge, exchange tips, and connect with fellow enthusiasts.

I’m delighted to announce that I’ll be joining Steve Bazyl, Head of Google Workspace DevRel, to co-facilitate the Apps Script Meetup at Google Cloud Next 2025. The last Next meetup we had was in 2018 so this is long overdue.

To help us plan an amazing meetup, we’d love your input! Steve and I have got this very quick survey that we’ll use to help us tailor the content and activities to your interests. The meetup is scheduled for April 10 at 12:15pm and is limited to Google Cloud Next attendees.

If you are attending Cloud Next there are a couple of other meetups:

Source: Apps Script developers meetup Google Cloud Next 25

Create Responsive Emails Easily with Google Apps Script and MJML

Today I had the task of implementing a newsletter for internal updates and decided to use Google Apps Script since I was already using it for managing the project data. Based upon past experiences with emails using HTML I need this area was full of landmines and I didn’t want to navigate through it. 💣

So I decided to use MJML with Google Apps Script.

Sending emails using Google Apps Script is a common task, however, creating HTML emails that render consistently across different email clients and that look visually appealing can be challenging.

Justin Poehnelt’s post on DEV Community, “Using MJML in Google Apps Script to Send Beautiful Emails,” offers a solution to this problem. MJML is a markup language that makes it easy to create responsive HTML emails. It removes some of the complexities of HTML email development, allowing users to focus on the content of their emails.

In the post, Justin explains how to use MJML with Google Apps Script to send beautiful, responsive emails. He also mentions that he has published a library, MJMLApp, that “hides the gnarly bits” of using MJML with Google Apps Script. This library is available on GitHub in the mjml-apps-script repo where you can find the library ID and basic usage information.

Source: Using MJML in Google Apps Script to Send Beautiful Emails

Beyond Basic Q&A: What is the future of the Google Apps Script community and development?

The data reveals a notable decrease in Stack Overflow activity related to Google Apps Script from 2023 to 2024. There’s a reduction in total questions, questioners, answerers, and tags used. Interestingly, the ratios of answered and solved questions have increased. This suggests that while there’s less activity, a higher proportion of questions are getting resolved. A key factor influencing these trends is likely the rise of generative AI.

The latest report on the google-apps-script tag on Stack Overflow, published by Kanshi Tanaike, paints a fascinating picture: Google Apps Script is a maturing platform, but it’s also undeniably at a critical juncture. As Tanaike notes, “the rise of generative AI” is reshaping the developer landscape, and this is clearly reflected in the data.

The declining volume of basic Google Apps Script questions on Stack Overflow is arguably not a sign of the platform’s decline, but rather a signal of a significant evolution. This shift demands our attention and a willingness to explore the new opportunities and challenges it presents. This means actively seeking out new opportunities, adapting our skillsets, and rethinking traditional approaches to Google Apps Script development.

I believe the future of Apps Script rests on the skills of its developers and the strength of its community. Fostering a community capable of tackling complex integrations, building sophisticated automation within Google Workspace, and leveraging AI to enhance Apps Script’s capabilities is paramount. Supporting both current and new Apps Script developers, enabling them to unlock the platform’s full potential, is a key part of this future. The core value proposition, Apps Script’s unparalleled integration with the Google ecosystem, remains strong.

The real challenge, and the opportunity, lies in how the Google Apps Script community adapts, supporting knowledge sharing that goes beyond basic Q&A and cultivating a culture of deep understanding, critical thinking, and collaborative problem-solving. For us at AppsScriptPulse, this means continuing to share not just code snippets, but also design patterns, architectural best practices, and strategies for effectively integrating and evaluating AI-generated code.

Source: Trend of google-apps-script Tag on Stackoverflow 2025

Google Workspace Developer News: Managing Folders with Limited and Expansive Access with the Drive API

There are nine updates highlighted in this month’s Google Workspace Developer News. The news that caught my eye the most relates to updates to the Google Drive API and upcoming changes to My Drive folders with restricted access.

Google Drive API: Managing Folders with Limited and Expansive Access

Google recently announced that by 2026, it will stop allowing restricted access on specific files and folders in My Drive, instead consistently managing it via the limited access folder setting. These changes will align the My Drive experience with Shared Drives, which use an expansive access model where everyone sees the same items in a folder. For developers wanting to get ahead of the curve, there are several new fields that can be used. The Google Workspace Developer News episode gives an overview of these, and there is a new Google Developers Documentation guide on Manage folders with limited and expansive access. In summary:

  • Restricting Folder Access: To limit access to a folder, developers can set the boolean inheritedPermissionsDisabled field on the files resource to true.
  • Opt-in API Behavior: Developers can also opt in to expansive access API behavior in My Drive ahead of any future mandatory enforcement by setting the enforceExpansiveAccess request parameter to true on the permissions.delete() and permissions.update() methods.

Other Updates

Here’s a brief overview of the other updates covered in the Google Workspace Developer News video:

  • Apps Script Rhino Runtime Deprecation: Also already highlighted in Pulse, the Apps Script Rhino runtime will no longer function after January 31, 2026.
  • Google Meet API Enhancements: All meeting participants can query conference data, including the conference records, the conference artifacts, and the participant records, using the Google Meet API.
  • Google Meet Pre-Configurations: Auto-recording, auto-transcripts, and “take notes for me” can now be pre-configured within a meeting space when created. This feature is available through the Developer Preview Program.
  • Google Meet Media API: The Google Meet Media API is now available through the Developer Preview Program, granting access to real-time media from Google Meet conferences.
  • Reports API Updates: Google Chat now supports the customerUsageReports.get() and userUsageReports.get() methods for the Reports API.

Source: Apps Script’s Rhino runtime deprecated, launch of Meet Media API, and more!

Unlock Your Productivity Potential with Gemini and Google Calendar (and other Workspace APIs)


As a Google Workspace Developer Advocate, I’m always exploring innovative ways to leverage technology. I’m thrilled to share my new Jupyter Notebook that showcases the power of Gemini and the Google Calendar API for productivity coaching. 🚀✨

This notebook dives into:
– Using Gemini’s multimodal capabilities to analyze calendar data. 📅
– Leveraging function calling to connect Gemini with Google Workspace APIs. 🔗
– Developing a personalized AI productivity coach. 🧑‍🏫

It’s amazing to see how generative AI can transform the way we work and optimize our time. ⏳

Explore the notebook on GitHub and discover how to build your own AI-powered productivity tools! 🛠️

👉 Link: https://lnkd.in/gpTxMMAy

Are you struggling to manage your time effectively? Mohammad Al-Ansari, Google Developer Advocate, has recently shared how the Gemini API can act as a personal productivity coach. The solution uses a Google Colab notebook, which is connected to the Google Calendar API. The Gemini API is used to provide personalized insights and recommendations to boost your productivity and improve your work/life balance. For those who don’t know, Google Colab is a free cloud-based platform for running Jupyter Notebooks, which are interactive coding environments that allow users to write and execute code and can be a useful tool to have in the toolbox when exploring data.

Some of the key features in Mohammad’s ‘Productivity Coach’ are:

  • Function Calling: This notebook uses Gemini’s ‘function calling’ capabilities, allowing it to dynamically interact with the Google Calendar API and retrieve real-time data. This ensures that the analysis and recommendations are always up-to-date and relevant to your current schedule.
  • Google Workspace Integration: By integrating with the Google Calendar API, this notebook shows how the Gemini API can be seamlessly integrated with other Google Workspace services. This opens up exciting possibilities for quickly experimenting with other Workspace data sources, such as Google Docs, Sheets or Drive.
  • Personalized Coaching: As a bonus you can see how Gemini can act as your personal productivity coach, so if nothing else you can get some tailored guidance and support about your own calendar

Check out the notebook to explore!

Source: generative-ai/gemini/use-cases/productivity/productivity_coaching_with_google_calendar.ipynb at main · GoogleCloudPlatform/generative-ai

‘AI Agents’ in Google Apps Script: Automate Google Workspace with Natural Language

Imagine that you write in plain English what you want to do in Google Workspace (eg. workflows) and it happens just like magic. Insert text prompt, Gemini will generate the code for you and run it immediately. A dream? No, reality, thanks to my conceptual and practical idea of how to implement AI Agents in Google Apps Scripts to leverage the V8 runtime.

Ivan Kutil has explored the concept of AI Agents in Google Apps Script, enabling Google Workspace automation via plain English descriptions. Users describe their automation needs in natural language, which is then processed by Gemini API to generate the necessary code. The generated code is then executed in your Google Apps Script project.

Ivan’s solution uses the gemini-2.0-flash-thinking-exp-01-21 model, an experimental model within Vertex AI specifically designed to reveal its ‘thinking process’, resulting in more reliable code generation. The enhanced reasoning capabilities of this model are particularly beneficial for complex automation tasks, making it a powerful tool for Google Workspace customisation.

To ensure that the agent is doing the right thing, the clever bit is you can test the execution via a dry-run, where the code created with Gemini Flash Thinking is sent to an internal ‘Tester’ agent, which uses Gemini to comment on the code and summarises it in a log. It’s important to review the script before running it, as Ivan accepts no responsibility for the results of the script. Another nice feature is the generated code is stored in the Cache, so after running a dry-run and then a run, the same version will be executed within the Cache limit (currently set to 5 minutes).

This solution, which mirrors Gemini for Workspace’s ability to generate and execute basic Python code, suggests a future where Gemini for Workspace could write and execute Apps Script code for basic tasks. This has the potential to transform how users interact with and automate their Google Workspace environments.

If you are interested in a version of Ivan’s solution that incorporates my GeminiApp library, follow this link. For additional information on Ivan’s solution including setup instructions follow the source link.

Source: Create AI agents in Google Apps Script with Vertex AI and Gemini

Rhino Runtime Retirement: Action Needed for Apps Script Projects

As of February 20, 2025, the Rhino runtime is deprecated. Scripts running on Rhino will continue to function until January 31, 2026, after which they will no longer execute. Please migrate your scripts to the V8 runtime before this date. Refer to Migrate scripts to the V8 runtime.

Attention Google Workspace Developers!

A recent email to Google Workspace administrators announced the upcoming retirement of the Rhino runtime for Apps Script. As also highlighted in the Apps Script release notes, all Apps Script projects still using the Rhino runtime must be migrated to the V8 runtime by January 31, 2026, to avoid execution issues.

What this means for Workspace Developers:

If you are a Workspace developer, even if you don’t have an administrator role, it’s crucial to check your Apps Script projects for Rhino runtime usage. The email to administrators included a CSV file listing affected projects, with details such as:

  • Script URL, Script ID, Last Updated: Identifies the specific script.
  • Creator Email, Owner Email: Identifies the script’s originators.
  • Incompatibility Reason: Explains why the script needs migration.
  • Execution Count: Shows how often the script is used.
  • Additional Information: Includes opt-out status, library dependencies, etc.

Suggested Actions for Developers:

  • Non-Admins: You might want to contact your Workspace administrator to find out if any of your or your colleague Apps Script projects are on the list of affected scripts and ask for guidance on the migration process.
  • Third-Party Developers: You may want to proactively reach out to your customers to inform them of the upcoming changes, offer assistance with the migration, and ensure their scripts are updated before the deadline to prevent any disruption in their services.
  • Workspace Admins: Review the CSV file to identify your affected scripts, prioritize migrating scripts with high usage first to minimize user disruption, and understand the specific issues that need to be addressed in each script.

Important Considerations:

Google provides a migration guide and support resources to assist with the transition. In particular, it is worth noting that:

  • For Apps Script web apps and Google Workspace Add-ons “[You] must create a new version of the script with the V8 adjustments. To make the V8 version available to users, you must re-publish the script with this version.”
  • When updating standalone scripts to run on the V8 runtime, “you need to provide users at least view access to the script in order for the script’s triggers to work properly.”

It’s also important to note that while the V8 runtime generally offers performance advantages, there have been some reports of specific instances where performance with JDBC connectors might not be as efficient as in the Rhino runtime.

So don’t delay, start migrating your Apps Script projects today!

Source: Google Apps Script release notes  |  Google for Developers

Streamline Your Google Sheets: Automate Row Archival with Google Apps Script

Archive Google Sheet Data with Google Sheets API Advanced Service in Google Apps Script

Keeping your Google Sheets organised can be a chore. A recent tutorial by Scott Donald shows you how to automatically archive old rows based on multi-column parameters using Google Apps Script and the Advanced Sheets API, making data management easier and more efficient. This post highlights Scott’s approach to scripting a solution, including how to set up the Sheets API, the main components of the script, and potential applications.

As always Scott packs in a lot of useful tips and guidance; in particular, the tutorial highlights how to archive data using just five API calls, potentially making it faster than the standard SpreadsheetApp approach. Scott also details how to modify the script to suit different processes and includes details on his SsReq class. It provides a structured way to perform common operations like retrieving data, finding rows based on criteria, copying rows, appending rows, and removing rows, making it a great addition to your personal Apps Script toolbox.

For detailed explanations, code examples, and helpful tips, consult the complete tutorial.

Source: Creating a Google Sheets Row Archiver with Google Sheets API Advanced Service and Apps Script – Yagisanatode

Automating Data Extraction with the Gemini API Controlled Generation and AppSheet’s New Gmail Integration

Tired of manually processing invoices? I recently built a demo that automates this tedious task using the power of Gemini, AppSheet’s new Gmail integration, and a custom Apps Script library. Let me show you how it works!

Here’s the setup:

  • Gmail Integration: AppSheet’s new Gmail integration allows you to trigger automations based on incoming emails. I’ve set it up to monitor a specific Gmail label called “Invoices”.
  • Apps Script Library: Using my “GeminiApp” (available on Github) which simplifies the interaction with Google’s Gemini AI models directly from Apps Script. This library handles the heavy lifting of making API calls and managing responses.
  • Controlled Generation: Gemini’s “Controlled Generation” feature lets me define a JSON schema that structures the AI’s output. This is key for extracting invoice data in a consistent, machine-readable format.

The Workflow:

  1. Invoice Received: When an invoice email arrives and is labelled “Invoices”, AppSheet’s Gmail integration kicks in.
  2. Automation Triggered: AppSheet triggers an automation that calls a custom Apps Script function called jsonControlledGeneration.
  3. Data Extraction: The jsonControlledGeneration function uses the GeminiApp library to send the email body to Gemini with a predefined JSON schema for invoice data.
  4. Structured Output: Gemini processes the email content and extracts the relevant invoice details (e.g., invoice number, supplier name, date, amount) in a JSON format that adheres to the schema.
  5. Downstream Processing: The structured JSON output can then be easily returned to the AppSheet automation for further actions, such as automatically populating your data table, updating a database, or triggering a payment process.

If you would like to try this yourself, instructions are provided below.

Want to try it yourself?

To set this demo up you will either need a Google AI Studio API key or a Google Cloud project with Vertex AI enabled. Information on both these setups is included in the GeminiApp Setup Instructions. Once you have these you can follow these steps:

  1. Open the GeminiApp Controlled Generation Google Apps Script project and click ‘Make a copy’ from the Overview page
  2. Open the Invoice Tracker template and click ‘Copy and Customize’, then click OK on the Error Creating App: Apps Script function is invalid error
  3. Navigate to appsheet.com and from your ‘recent’ apps  open the ‘Invoice Tracker’ app
  4. Open Automations and for the ‘New Invoices’ event under the Gmail Event Source, click Authorize, then
  5. In the ‘Add a new data source’ enter a name e.g. Invoices Trigger, click the Gmail button and follow the authentication steps
  6. Once complete in the AppSheet Automation settings select your Gmail account and a Label to watch
  7. In the Process section click on the GeminiApp task and click on the blue file icon, then select your copied version of the Apps Script project and click Authorize
  8. Once Authorize, from the Function Name select jsonControlledGeneration

To test this app, you can copy and send this example invoice.

Step 7: Click on the blue file icon, then select your copied version of the Apps Script project

The Power of Controlled Generation

Controlled Generation is a powerful way for extracting information from unstructured data like emails. By defining a JSON schema, I can specify exactly what information I want Gemini to extract and how it should be structured. This ensures that the output is consistent and reliable, eliminating the need for manual cleanup or post-processing.

Here’s an example of a simple JSON schema for invoice data:

 const schema = {
    "type": "object",
    "properties": {
      "Invoice Reference": {
        "type": "string",
        "description": "Unique identifier for the invoice"
      },
      "Supplier Name": {
        "type": "string",
        "description": "Name of the supplier"
      },
      "Invoice Date": {
        "type": "string",
        "description": "Date the invoice was issued",
        "format": "date"
      },
      "Due Date": {
        "type": "string",
        "description": "Date the invoice is due",
        "format": "date"
      },
      "Invoice Amount": {
        "type": "number",
        "description": "Total amount due on the invoice"
      },
      "Notes": {
        "type": "string",
        "description": "Additional notes related to the invoice",
        "nullable": true
      }
    },
    "required": ["Invoice Reference"]
  }

Creating JSON Schemas with Gemini

Creating JSON schemas can seem a bit daunting at first, but Gemini can actually help you with that too! If you have sample data in a Google Sheet, you can use the Gemini Side Panel to generate a schema automatically. Just highlight the data and ask Gemini to create a JSON schema for you. You can even provide a description for each property to make your schema more understandable. Below is a prompt you can use in the Gemini Sheet Side Panel to generate a schema for your own data:

I'm using Controlled Generation with the Gemini API as described in the document https://drive.google.com/file/d/1ETKHlEUDQzJ-f2fmAzsuDjcwdt1D7R2y/view?usp=drive_link

I need help creating a JSON schema to capture data from a screen.

Could you generate a JSON schema suitable for using Controlled Generation with the Gemini API? I want to extract specific information from what's displayed on my screen.

Here are my requirements:

* **Comprehensive Schema:** The schema should be designed to capture a variety of relevant data points from the screen.  
* **Detailed Descriptions:** Please include a clear and concise \`description\` for each \`property\` in the schema. This will help me understand the purpose of each field.  
* **Format Specification:** If any columns contain date or datetime data, please use the \`format\` field to specify the appropriate format (e.g., "date", "date-time"). This is crucial for accurate data parsing.  
* **Output Example:** Please provide the schema in the following format:

```
const schema = {
  description: "Description of the data",
  type: "array", // or "object", depending on the structure
  items: { // If type is array
    type: "object",
    properties: {
      propertyName: {
        type: "string", // or other appropriate type
        description: "Description of the property",
        format: "date", // or "date-time", if applicable
        nullable: false, // or true
      },
      // ... more properties
    },
    required: ["propertyName"], // If any properties are required
  },
  properties: { // If type is object
      propertyName: {
        type: "string", // or other appropriate type
        description: "Description of the property",
        format: "date", // or "date-time", if applicable
        nullable: false, // or true
      },
      // ... more properties
    },
    required: ["propertyName"], // If any properties are required
};
```

Limitations and future developments

While the beta Gmail integration in AppSheet marks a significant new feature, it’s important to note a current limitation is support for processing email attachments. Currently, the integration focuses on metadata such as sender name, subject, and message body, but the AppSheet team have acknowledged attachment support will be added in the near future.

Looking ahead, at Google Cloud Next 2024 the AppSheet team announced an upcoming “Gemini Extract” feature, currently in private preview. This feature intends to include a native Gemini ‘controlled generation’ feature which would let app creators select the data fields they would like populated from sources including images and text. This should be a more intuitive approach to data extraction, directly integrating Gemini capabilities into AppSheet. The Next video includes a Google URL to sign up to the Gemini Extract feature https://goo.gle/appsheet-previews?r=qr

Summary

The Invoice Tracker example hopefully highlights the opportunity for streamlined solutions with data extraction with AppSheet’s Gmail integration, Gemini, and Apps Script.The GeminiApp library also  simplifies the integration of Google’s Gemini AI models into Google Workspace, providing developers with tools to create sophisticated AI-powered applications.

Using the structured JSON output with Controlled Generation can help AppSheet creators by making it easier to ensure you get the data back in a suitable format including the type of data you need, such as dates. With the GeminiApp library, rapid prototyping is achievable, in the ‘Invoice Tracker’ example I was able to get a functional prototype up and running in under 30 minutes.

AppSheet’s Gmail integration, generally available to all AppSheet and Google Workspace Core users, can trigger automations directly from incoming emails without requiring app deployment. Combined with Apps Script functions this opens the door to some powerful opportunities for AppSheet creators. Integrating Gemini-powered AI extraction with AppSheet and Apps Script provides an innovative solution for automating data extraction from emails. By taking advantage of these capabilities, citizen developers can create efficient and user-friendly solutions.

AppSheet’s New Gmail Integration: Bridging the Gap Between your Inbox and Applications

We’re pleased to announce the public preview of Gmail integration with AppSheet – something we know has been a longstanding community request. With this preview launch, your Gmail inbox can seamlessly connect to the full breadth of downstream processes AppSheet automation already offers.

AppSheet has introduced a Gmail integration in public preview, offering a workaround for situations including third-party applications that lack direct integration with Google Workspace via add-ons or APIs. With this new feature users can now connect their Gmail inboxes to AppSheet, enabling incoming emails to trigger various automations.

How it Works

Users can link their AppSheet apps to authorized Gmail accounts and select specific labels in their Gmail inboxes for monitoring. When an email arrives with a designated label, AppSheet receives information about the email, including the sender, subject, and body. This information can then be used to automate various tasks and processes within the AppSheet platform.

Things to Note

Currently, the beta release does not include support for attachments, but AppSheet is working on adding this feature for the full release later this year. Also, Gmail cannot be used as a full data source in AppSheet. To save Gmail messages in an app table, users need to create a process to add the email data.

Availability and Feedback

The Gmail integration is rolling out to all AppSheet users soon as part of the preview and the AppSheet team is encouraging users to provide feedback on this new integration. To read more and provide feedback follow the source link

Source: Gmail Integration in AppSheet: Now in Public Preview! (Beta)