Once users select files using the Picker, you need to handle and utilize this data in your Bubble application. This may include displaying information, storing data in the database, or performing additional actions.
The data from the selected files is published in the plugin's states. These states are available for use in your Bubble application.
State |
Data Type |
Description |
---|---|---|
|
List of Text |
Contains the full names of the selected files, including the file extension. These names are useful for displaying user-readable information about the selected files. They can also be used to generate unique identifiers or organize files in the application. |
|
List of Text |
Contains the unique Google Drive IDs for each selected file. These IDs are essential for any subsequent operations with the Google Drive API, such as downloading, sharing, or updating files. The IDs remain constant even if the file name changes, providing a stable reference. |
|
List of Text |
Contains the MIME types of the selected files (e.g., "image/jpeg", "application/pdf", "application/vnd.google-apps.document"). This information is useful for determining the type of content and how each file should be processed or displayed. Google-specific MIME types (beginning with "application/vnd.google-apps") indicate native Google documents that may require special handling. |
|
List of Text |
Contains direct URLs to access the selected files. These URLs can be used to download, preview, or link to the files. For regular files, these URLs point directly to the file content, while for Google Docs, they point to the viewable version of the document. |
|
List of Text |
Contains URLs for thumbnails of the selected files, generated by Google Drive. For image files, these thumbnails represent the actual content. For other file types, they display icons or automatically generated previews. These URLs are useful for showing visual representations of the files in your application's user interface. |
|
List of Numbers |
Contains the sizes of the selected files in bytes. This information is useful for displaying file sizes to users, verifying if they meet certain limits, or calculating the total space occupied by a set of files. Some files may not have a defined size (especially native Google documents), in which case the value will be 0. |
|
List of Text |
Contains the names of the owners of the selected files. This information is useful for identifying who the creator or primary owner of each file is, which can be important for applications that handle permissions or attribution. If owner information is unavailable for a file, "Unknown" will be used as the default value. |
|
Text |
Contains the custom error message displayed when the maximum number of selected files is exceeded (configured in the |
|
Text |
Contains the custom warning message displayed when some selected files exceed the maximum allowed size (configured in the |
State |
Data Type |
Description |
---|---|---|
|
List of Text |
Contains the names of the files prepared for download. For native Google documents (such as Google Docs, Sheets, or Slides), these names include the appropriate extension for the exported format (e.g., .docx, .xlsx, .pptx), making it easier for users to identify the downloaded file type. |
|
List of Text |
Contains the unique Google Drive IDs for the files prepared for download. These IDs are important for tracking which specific files are being downloaded, especially when processing multiple files. |
|
List of Text |
Contains URLs specifically optimized for direct file downloads. These URLs are configured to allow immediate content download without requiring additional authentication. For native Google documents, these URLs point to exported versions in standard formats (e.g., DOCX for Google Docs, XLSX for Google Sheets, PPTX for Google Slides), enabling downloadable usable versions of these documents in external applications. When a single file is selected in this mode, the plugin will automatically initiate the download using the corresponding URL. |
State |
Data Type |
Description |
---|---|---|
|
List of Text |
Contains URLs specifically formatted to allow others to view shared files in read-only mode. These URLs are configured to work even for users who are not logged into Google (if file permissions allow). For native Google documents, these URLs open the documents in view mode, while for other file types, they open a preview in the Google Drive viewer. These URLs are ideal for sharing content that only needs to be viewed but not edited. |
|
List of Text |
Contains URLs that allow others to edit shared files (mainly applicable to native Google documents like Docs, Sheets, and Slides). These URLs are formatted to open documents directly in edit mode for users with appropriate permissions. For files that cannot be edited in Google Drive (e.g., PDFs or images), this value may be empty. These URLs are useful when real-time collaboration or multi-user editing is required. |
|
List of Text |
Contains URLs specifically formatted for embedding files in websites, blogs, or applications. These URLs are designed to work with iframe tags and provide an integrated viewing experience without leaving the website where they are embedded. Different file types generate optimized embedding URL formats: documents use preview mode, presentations use specific embedding mode, and media files use specialized viewers. These URLs are ideal for integrating Google Drive content directly into web pages. |
|
List of Text |
Contains URLs optimized for sharing on social media and messaging platforms. These URLs are designed to provide rich previews when shared on platforms like Facebook, Twitter, LinkedIn, or messaging apps. They include special parameters that enhance how they appear when shared, showing thumbnails, titles, and appropriate descriptions in the generated previews. They are ideal for marketing campaigns or when you want to maximize visual impact when sharing content on social media. |
The plugin emits several events that you can use to trigger workflows in your Bubble application. These events allow you to respond to different user actions and situations during interaction with Google Drive.
Event |
Description |
---|---|
|
Triggered when the user successfully completes file selection in standard mode ("select"). This event indicates that the plugin's basic states ( |
|
Triggered when file preparation for download is completed in "download" mode. This event indicates that, in addition to the basic states, the download-specific states ( |
|
Triggered when link generation for sharing is completed in "share" mode. This event indicates that the sharing-specific states ( |
|
Triggered when all operations are completed in "all" mode. This event indicates that all plugin states (basic, download, and sharing) have been updated with complete information. If a single file was selected, its download will also have been automatically initiated. Use this event when you need full access to all plugin capabilities in a single step. |
|
Triggered when the user explicitly cancels the picker operation by closing the Google Picker dialog without selecting files. Use this event to clean up temporary states, display informational messages, or redirect to other parts of your application when the user decides not to select any files. |
|
Triggered when a significant error occurs during any plugin operation. This event includes information about the error type in the |
|
Triggered when a situation arises that requires attention but does not prevent the main operation, such as when some files exceed the maximum allowed size and are excluded from the selection. This event includes information in the |
|
Triggered when the user’s session expires due to inactivity (if |
|
Triggered when the plugin’s security system detects a potential security issue, such as code manipulation attempts, execution in unauthorized environments, or suspicious behavior patterns. Use this event to implement additional protective measures, such as logging suspicious attempts or temporarily limiting certain functionalities. |
You can use these states to display information about the selected files in your Bubble application.
Add a Repeating Group :
Configure the Data Source :
Google Drive Picker's file_ids
.Add Elements Inside the Repeating Group :
Current cell's Google Drive Picker's file_names
.Current cell's Google Drive Picker's file_thumbnails
.Current cell's Google Drive Picker's file_urls
.Create a Custom Data Type :
Configure the Workflow to Create New Files :
Google Drive Picker's file_names
Google Drive Picker's file_ids
Google Drive Picker's file_mime_types
Google Drive Picker's file_urls
Google Drive Picker's file_thumbnails
Google Drive Picker's file_sizes
Google Drive Picker's file_owners
Save and Test :
Was this page helpful?
Thank you for your feedback!
Please Login First
Comments (00)