Get media
Function: Get media
This action allows you to retrieve a specific media file, such as an image, document, or video, from your platform's storage. Once retrieved, the file is made available within your application's current process, ready for further use in subsequent actions.
Input,
- Media ID (Text): This is the unique identifier for the media file you want to load. You must provide this ID so the system knows which file to fetch.
Output,
- Result (File): This is the actual media file that was loaded. You can specify a name for the variable where this file will be stored for use in other actions. If you don't provide a name, the file will be stored in a variable called
MEDIA_FILEby default.
Execution Flow,
Real-Life Examples,
Example 1: Displaying a Product Image
Imagine you have a product page and need to display the main image for a specific product.
- Inputs:
- Media ID:
product_image_456 - Result:
ProductDisplayImage
- Media ID:
- Result: The image file identified by
product_image_456is loaded and stored in a variable namedProductDisplayImage. You can then use this variable in a UI element to show the image on your product page.
Example 2: Downloading a User Manual
A user clicks a button to download a PDF user manual for a device.
- Inputs:
- Media ID:
manual_device_xyz_v2 - Result:
UserManualPDF
- Media ID:
- Result: The PDF file identified by
manual_device_xyz_v2is loaded and stored in a variable namedUserManualPDF. This variable can then be passed to another action that initiates a download for the user.
Example 3: Accessing a Default Company Logo
Your application needs to retrieve the company's default logo for various reports, and you want to use the default variable name.
- Inputs:
- Media ID:
company_logo_main - Result: (Left blank, uses default)
- Media ID:
- Result: The logo file identified by
company_logo_mainis loaded and stored in the default variable namedMEDIA_FILE. ThisMEDIA_FILEvariable can then be used in subsequent actions to embed the logo in reports or emails.