How it works...

The serverless code (Google Function code) executes in response to an event, in this case, a Google Storage event. The Storage events are triggered whenever there is a create, update, or delete action for an object. The data of the event change is captured through the event.data in our code.

Get Google Cloud Platform Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.