Using AWS Lambda with API Gateway and S3 for imagemagick tasks.
Follow the tutorial Building your First Serverless App in Node.js with AWS Lambda + S3 + API Gateway
You don't need to install any packages. All the used dependencies are already available in AWS Lambda.