All Projects → francismeynard → lambda-multipart-parser

francismeynard / lambda-multipart-parser

Licence: MIT license
This nodejs module will parse the multipart-form containing files and fields from the AWS lambda event object. It works very well parsing binary and text files.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to lambda-multipart-parser

laravel-uppy-s3-multipart-upload
Multipart Uploads using Laravel, AWS S3, and Uppy
Stars: ✭ 30 (-33.33%)
Mutual labels:  s3, upload
Hands-On-Serverless-Applications-with-Go
Hands-On Serverless Applications with Go, published by Packt.
Stars: ✭ 92 (+104.44%)
Mutual labels:  api-gateway, s3
Dropdot
☁️ Direct Upload to Amazon S3 With CORS demo. Built with Node/Express
Stars: ✭ 87 (+93.33%)
Mutual labels:  s3, upload
react-relay-appsync
AppSync for Relay
Stars: ✭ 19 (-57.78%)
Mutual labels:  s3, upload
direct-upload-s3-signaturev4
Example of Directly uploading files to S3 with PHP
Stars: ✭ 50 (+11.11%)
Mutual labels:  s3, upload
S3 Uploader
🍎 macOS Electron+React App for uploading files to S3 directly from Status Bar
Stars: ✭ 119 (+164.44%)
Mutual labels:  s3, upload
Cakephp File Storage
Abstract file storage and upload plugin for CakePHP. Write to local disk, FTP, S3, Dropbox and more through a single interface. It's not just yet another uploader but a complete storage solution.
Stars: ✭ 202 (+348.89%)
Mutual labels:  s3, upload
Aws Mobile React Sample
A React Starter App that displays how web developers can integrate their front end with AWS on the backend. The App interacts with AWS Cognito, API Gateway, Lambda and DynamoDB on the backend.
Stars: ✭ 650 (+1344.44%)
Mutual labels:  api-gateway, s3
Aws Lambda Blog
AWS Lambda serverless blogging platform
Stars: ✭ 119 (+164.44%)
Mutual labels:  api-gateway, s3
Workshop Donkeytracker
Workshop to build a serverless tracking application for your mobile device with an AWS backend
Stars: ✭ 27 (-40%)
Mutual labels:  api-gateway, s3
Aws Mobile React Native Starter
AWS Mobile React Native Starter App https://aws.amazon.com/mobile
Stars: ✭ 2,247 (+4893.33%)
Mutual labels:  api-gateway, s3
Serverless Architectures Aws
The code repository for the Serverless Architectures on AWS book
Stars: ✭ 120 (+166.67%)
Mutual labels:  api-gateway, s3
sls-photos-upload-service
Example web app and serverless API for uploading photos and saving to S3 and DynamoDB
Stars: ✭ 50 (+11.11%)
Mutual labels:  api-gateway, s3
kong-plugin-api-response-merger
Kong API response merger plugin
Stars: ✭ 14 (-68.89%)
Mutual labels:  api-gateway
aws-certified-developer-associate-udemy-notes
AWS Certified Developer Associate Udemy Notes
Stars: ✭ 20 (-55.56%)
Mutual labels:  s3
data
[deprecated] Generate a DynamoDB data access layer from an .arc file. Automatically disambiguates testing (in memory) from deployment staging and production tables
Stars: ✭ 20 (-55.56%)
Mutual labels:  api-gateway
aws-tailor
AWS account provisioning and management service
Stars: ✭ 105 (+133.33%)
Mutual labels:  api-gateway
terraform-aws-cloudtrail-s3-bucket
S3 bucket with built in IAM policy to allow CloudTrail logs
Stars: ✭ 38 (-15.56%)
Mutual labels:  s3
react-deploy-s3
Deploy create react app's in AWS S3
Stars: ✭ 67 (+48.89%)
Mutual labels:  s3
Quark
Quark is a streaming-first Api Gateway using Akka
Stars: ✭ 13 (-71.11%)
Mutual labels:  api-gateway

lambda-multipart-parser

npm install lambda-multipart-parser --save

Introduction

This nodejs module will parse the multipart-form containing files and fields from the AWS lambda event object. It works very well parsing binary and text files.

Description

@param {event} - an event containing the multipart-form in the body
@return {object} - a JSON object containing array of files and fields, sample below.

{
    files: [
        {
            filename: 'test.pdf',
            content: <Buffer 25 50 6f 62 ... >,
            contentType: 'application/pdf',
            encoding: '7bit',
            fieldname: 'uploadFile1'
        }
    ],
    field1: 'VALUE1',
    field2: 'VALUE2',
}

Usage

const parser = require('lambda-multipart-parser');

const result = await parser.parse(event);
console.log(result.files);

Important Please make sure to enable the "Use Lambda Proxy integration" in API Gateway method Integration request.

If decided not to enable it for some reason, make sure to pass the required Lambda event parameters in Integration Request -> Mapping Templates section, such as body, headers and isBase64Encoded flag.

Sample Lambda and API Gateway implementation with Cloudformation can be found in here.

Test

npm run test

Releases / Changelogs

0.0.1 - Initial stable release.

0.0.2 - Updated readme. Added Usage and link to sample implementation.

1.0.0 - Formalized package release version. Add utf8 support.

1.0.1 - Added support for TypeScript typings.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].