node package manager


a 's3url' command for generating s3 signed urls


A small command line tool to generate signed S3 url for the EU WEST 1 region

npm install s3url

The usage is very straightforward

s3tool --expires 30 resource_url

where resource_url is an url in the following form


and "expires" is the number of seconds the url will be available. For example if the bucket is "foo" and the key is "bar/baz", the command will be:

s3tool --expires 30 /foo/bar/baz

You can supply authentication credentials in two ways:

  • command line parameters
  • environment variables

In the first option, you can pass the parameters --key and --secret to the command line and provide credentials. For example:

s3tool --key THISISTHEKEY --secret THISISTHESECRET resource_url

In the second options, just export two environment variables containing the key and the secret:

s3tool --expires 30 resource_url