top of page

OutSystems and Amazon S3 Integration

The integration between OutSystems and Amazon S3 (Simple Storage Service) offers an effective solution to leverage the advantages of both platforms in building and managing applications with secure and scalable data storage. Below is an explanation of each platform and the steps to integrate them.


What is OutSystems?

OutSystems is a low-code platform that enables organizations to quickly develop, deploy, and manage custom software applications using visual development tools. With features like ready-made templates and drag-and-drop interfaces, developers can build applications with minimal coding. This accelerates the software development process, allowing businesses to easily create and update applications as needed.


What is Amazon S3?

Amazon S3 (Simple Storage Service) is a cloud-based object storage service provided by Amazon Web Services (AWS). It is designed to store and retrieve large amounts of data from anywhere on the web. Amazon S3 is renowned for its scalability, durability, and security, making it a popular cloud storage solution for a wide range of use cases, from simple backups to large-scale data analytics. Its cost-effectiveness and flexibility make it a vital tool for businesses looking to securely store and manage their data in the cloud.


Steps to Integrate OutSystems with Amazon S3

  1. Create an AWS Account and S3 Bucket

    To begin the integration, the first step is to create an AWS account if you don’t already have one. Then, navigate to the S3 service and create a new bucket for data storage. After creating the bucket, a new user must be created in AWS Identity and Access Management (IAM) to grant full access to the bucket.


  2. Configure AWS Access Keys

    After creating the user, you will generate an access key and secret access key for that user. These keys will be used in the OutSystems configuration to allow the application to interact with Amazon S3. Keep these access keys secure, as they will be needed in the following steps.


  3. Integrate Amazon S3 in OutSystems

    In OutSystems, you will need to install the Amazon S3 module available from Forge. Once installed, dependencies related to this module can be added, allowing you to start building applications integrated with Amazon S3.


  4. Create Application - OutSystems Service Studio

    Create new Application

    •Select From scratch

    •Select Reactive Web App

    •Type application name

    •Click Create App



5. Create Application. File List

Create new empty Screen.

Name : FileList

Retrieve Amazon S3 file list

•Right click on the screen Interface, select [Fetch Data from Other Sources]. Name : S3Files.

•Add new output parameter. Name : Files, Data Type : List of Structure Object.

•Drop [Object_List] from Logic panel to Canvass, assign to output parameter (Files).



Assign AWS Credential

•Select [Objects_List] on Canvass

•Input AccessKeyId and SecretAccessKey with User Access Key and Secret Access Key created on previous step

•Input Region with selected AWS Region

•Input BucketName with bucket name created on previous step

Add Table

•Drop [Table] from Toolbox panel to the Canvass.

•Set [Table] source to “S3Files.Files”

•Add columns and expressions based on object properties.

•Add new column, drop [Link] from Toolbox panel to its Row Cell. Set Text to “Download”. Create new Client Action to handle its On Click event. Name : DownloadOnClick.

Create new Server action.

Name : DownloadS3File

•Create Input Parameter : Key (Text)

•Create Output Parameter : File (Binary Data)

•Drop [Object_Get] from Logic panel to Canvass

  - AWSCredentials & BucketName : same as in FileList page

  - Key : Key

•Assign File parameter value with [Object_Get] activity result

Open DownloadOnClick client action.

•Add [Run Server Action]. Select “DownloadS3File” Server Action. Set parameter : Key = S3Files.Files.Current.Key.

•Add [Download], replacing [End] activity. Set File Content = DownloadS3File.File, Filename = S3Files.Files.Current.Key


6. Create Application. Upload Screen

Create new empty Screen.

Name : UploadFile

•Add [Form], [Upload], [Label] and [Button] to the screen.

•Create 2 Local Variable : File (Binary Data) and Filename (Text)

•Set [Upload] widget : File Content = File, File Name = Filename

•Create New [Client Action] for Upload [Button] On Click event. Name : UploadOnClick

Create new Server action.

Name : UploadFileToS3

•Create 2 Input Parameter : File (Binary Data) and Filename (Text)

•Drop [Object_Put] from Logic panel to Canvass

  - AWSCredentials & BucketName : same as in FileList page

  - Key : Filename

  - File : File

Open UploadOnClick client action.

•Add [Run Server Action]. Select “UploadFileToS3” Server Action. Set parameter : File = File, Filename = Filename.

•Add [Destination], replacing [End] activity. Select “FileList” screen as destination.

Open FileList screen.

•Add new [Button] to the screen. Set Text to “Upload File”.

•Create New [Client Action] for Upload. File [Button] On Click event. Name : UploadFileOnClick. Change [End] activity to [Destination] and set destination to UploadFile screen.

7. Publish

8. Open in Browser

9. Testing and Publishing the Application

Once the application is complete, the final step is to publish the application and test it. The application can be tested in the browser to ensure that features such as file retrieval, file downloading from S3, and file uploads are working as expected.


The integration of OutSystems with Amazon S3 allows organizations to build applications that utilize S3's scalability and security for data storage. With OutSystems' low-code approach, application development becomes faster and easier, while Amazon S3 provides a robust and reliable cloud storage infrastructure.


Contact us if you'd like to learn more about OutSystems and Amazon S3 integration or need assistance with implementation. We are ready to help you build the optimal technology solution for your business needs.




Comments


bottom of page