Socket
Socket
Sign inDemoInstall

@guidesmiths/systemic-aws-s3

Package Overview
Dependencies
173
Maintainers
5
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @guidesmiths/systemic-aws-s3

A systemic component for AWS S3 service


Version published
Maintainers
5
Created

Changelog

Source

1.0.3 (2021-10-22)

Features

  • add standard-version (2c25c8a)

Bug Fixes

Readme

Source

Systemic AWS S3

A Systemic component for the AWS S3 SDK v3.

How to use it

Configuration

A typical, simple configuration looks like this:

{
  "region": "us-east-1",
  "credentials": {
    "secretAccessKey": "test",
    "accessKeyId": "test"
  }
}

Here you can finde the complete configuration interface of S3Client class constructor that set the region, credentials and other options.

Initialize the component

As with any other Systemic component, you can run it with the start method:

const initAWSS3 = require('systemic-aws-s3');
const { start } = initAWSS3();

const api = await start({ config }); // configuration similar to the one above

Call the API commands

As the AWS API has dozens of commands, intead of having one wrapper for each of them, the component exposes one single command commandExecutor that can be used to call any of the commands exposed by the api:

For example, to list all the objects in a specific bucket:

const listObjectConfig = {
  commandParams: { Bucket: bucketName },
  commandName: 'listObjects'
}
const res = await api.commandExecutor(listObjectConfig);

You can check all the available commands here.

Custom commands

In the future, this component will also expose some custom commands not supported by the official API.

Guide for developers

How to test it

You can test the whole test suite running one of these commands:

# all tests will be executed once
npm run test

# tests will be executed every time code changes (useful when coding)
npm run test:watch

In case that you want to just execute a certain test case, you can also use these scripts to up / tear down the infra.

npm run infra:up
npm run infra:down

Keywords

FAQs

Last updated on 05 Oct 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc