My FNZ Studio Version

Extensions

Latest Update: 02.03.2022 |
Documentation
2024
2023
2022.2
2022.1
11
10

Some features described in this article may be subject to licensing and/or separate surcharge. See the AWS S3 Connector Products card and the AWS S3 Connector Licensing article for detailed information.

Introduction

The AWSS3Connector extension allows uploading files to the AWS S3 service.

Configuration

To use the AWSS3Connector extension, the following properties need to be configured (all of them are required):

  • com.nm.extensions.awss3connector.accessKey: AWS access key (aka Access Key ID, example: AMIAJJHUSKCHKDQYE7EA) to access the S3 service.
  • com.nm.extensions.awss3connector.secretKey: AWS secret key (aka Secret Access Key, example: Kyb+/MY17dQ3cQepM4Psckuq/m+oSN5y+WPXqlh+) to access the S3 service.
  • com.nm.extensions.awss3connector.region: AWS region used to access the S3 service. E.g. eu-central-1
  • com.nm.extensions.awss3connector.bucket: AWS S3 bucket name to store the upload files. E.g. client-onboarding-bucket

The AWS access key and secret key, after they are manually configured, are encrypted, stored in the Appway internal vault, and marked as [ENCRYPTED].

Usage

To upload files to the AWS S3 service, the following Script Function is provided:

AWSS3Connector:UploadLocalFile(LocalFile $file, String $path)

where $file is the LocalFile to upload and $path is the path (aka key) in the configured S3 bucket.

There is no return value.

If an exception occurs, an NmRuntimeException is thrown.

Usage Example

The following code snippet will upload the locally stored file /tmp/test.txt to the configured S3 bucket under the given path uploads/test.txt:

LocalFile $file := NewObject(LocalFile, '/tmp/test.txt');
AWSS3Connector:UploadLocalFile($file, 'uploads/test.txt');

Consider the following:

  • If the file (and directory) do not exist yet, they are created automatically.
  • If the file (and directory) already exist, the file is overwritten.
© 2026 Appway AG. All Rights Reserved