Working With The AWS S3 API


File storage is one of the more difficult tasks that a developer can come across. I mean everything about files is bad, they’re big which means they’re slow and slow generally means a bad user experience. So if your file management process is bogged down with complexity it can be a real pain for your users to upload their content. Luckily there are some fantastic cloud solutions out there to handle a majority of the headache with this.

While I’ve found that most of the cloud service providers have some form of storage API for JavaScript, I find myself leaning to Google and Amazon to deal with my cloud storage solutions. Their API’s are shockingly easy to use and in just a few moments you can have a file upload process setup to push your user’s content to the cloud.

The S3 API In particular only requires a few lines of code assuming you’ve got the appropriate credentials stored in a unversioned file(as you should with any credentials). Check out this example:

I mean for pushing out to the cloud, it doesn’t get much simpler than this. Tie this together with a service like cloud-front and you’ve got some highly available content. The great documentation, ease of use, and reliability makes it easy for devs to make apps that can plug into a plethora of different cloud services for some highly versatile applications.

Leave a Reply

Your email address will not be published. Required fields are marked *