NLdoc.S3 (NLdoc.S3 v1.0.5)

View Source

Helper functions for S3.

Summary

Functions

Head an object in a bucket.

Download a specific file as a stream

Upload a specific file as a stream.

Check if bucket exists. Create it if it does not.

Types

response()

@type response() :: {:ok, term()} | {:error, term()}

Functions

head_object(bucket, key)

@spec head_object(bucket :: String.t(), key :: String.t()) :: response()

Head an object in a bucket.

stream_download!(bucket, key)

@spec stream_download!(bucket :: String.t(), key :: String.t()) :: Enumerable.t()

Download a specific file as a stream

stream_upload(path, bucket, key, opts)

@spec stream_upload(
  path :: String.t(),
  bucket :: String.t(),
  key :: String.t(),
  opts :: ExAws.S3.upload_opts()
) :: {:ok, term()} | {:error, term()}

Upload a specific file as a stream.

upsert_bucket(bucket, region)

@spec upsert_bucket(bucket :: String.t(), region :: String.t()) :: response()

Check if bucket exists. Create it if it does not.