Skip to content

Serverless Examples – A collection of boilerplates and examples of serverless architectures built with the Serverless Framework on AWS Lambda, Microsoft Azure, Google Cloud Functions, and more.

License

Notifications You must be signed in to change notification settings

serverless/examples

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WebsiteEmail UpdatesGitterForumMeetupsTwitterFacebookContact Us

examples-hero

Serverless Examples

A collection of ready-to-deploy Serverless Framework services.

Table of Contents

Click to expand

Getting Started

If you are new to serverless, we recommend getting started with by creating an HTTP API Endpoint in NodeJS, Python, Java, or Golang.

Examples

Each example contains a README.md with an explanation about the service and it's use cases.

Have an example? Submit a PR or open an issue. ⚡️

To install any of these you can run:

serverless install -u https://github.com/serverless/examples/tree/master/folder-name -n my-project
Example Runtime
Aws Dotnet Rest Api With Dynamodb
Reading/Writing operations using .NET Core and DynamoDB
dotnet
Aws Lambda Layer nodeJS
Aws Golang Auth Examples
These example shows how to run a Golang lambda with authentication
golang
Aws Golang Dynamo Stream To Elasticsearch
This example deploys a DynamoDB Table, an Elasticsearch Node, and a lambda triggered off of a Dynamo Stream which updates an elasticsearch index with the data from the Dynamo Table
golang
Aws Golang Http Get Post
Example on Making Parameterized Get and Post Request with Golang
golang
Aws Golang Rest Api With Dynamodb
Serverless CRUD service exposing a REST HTTP interface
golang
Aws Golang Simple Http Endpoint
Example demonstrates how to setup a simple HTTP GET endpoint with golang
golang
Aws Golang Stream Kinesis To Elasticsearch
Pull data from AWS Kinesis streams and forward to elasticsearch
golang
Aws Alexa Skill
This example demonstrates how to use an AWS Lambdas for your custom Alexa skill.
nodeJS
Aws Node Auth0 Cognito Custom Authorizers Api
Authorize your API Gateway with either Auth0 or Cognito RS256 tokens.
nodeJS
Aws Auth0 Api Gateway
Demonstration of protecting API gateway endpoints with auth0
nodeJS
Aws Node Dynamic Image Resizer nodeJS
Aws Node Dynamodb Backup
Serverless DynamoDB changes backed up to S3
nodeJS
Aws Env Variables Encrypted In A File
Serverless example managing secrets in an encrypted file
nodeJS
Aws Env Variables
This example demonstrates how to use environment variables for AWS Lambdas.
nodeJS
Aws Node Express Api nodeJS
Aws Node Express Dynamodb Api nodeJS
Aws Fetch File And Store In S3
Fetch an image from remote source (URL) and then upload the image to a S3 bucket.
nodeJS
Sfe Demo Leadcapture nodeJS
Frontend nodeJS
Aws Function Compiled With Babel
Demonstrating how to compile all your code with Babel
nodeJS
Serverless Github Check nodeJS
Aws Github Webhook Listener
Extend your github repositories with this github webhook listener
nodeJS
Graphql Api And Serverless nodeJS
Aws Node Graphql Api With Dynamodb
A single-module GraphQL endpoint with query and mutation functionality.
nodeJS
Aws Lambda And Heroku Postgres
Shows how to connect AWS Lambda to Heroku Postgres. Uses an api:release Heroku webhook and the Heroku API to handle automatic Heroku Postgres credential rotation.
nodeJS
Aws Iot Event
Example on how to setup a AWS IoT Rule to send events to a Lambda function
nodeJS
Aws Lambda And Mongodb Atlas
Shows how to connect AWS Lambda to MongoDB Atlas.
nodeJS
Dropbox
dropbox integration
nodeJS
Aws Node Puppeteer
When it comes to AWS Lambda function , they have their own limits as follows AWS Limits So , When you try to use Puppeteer your deployment package size(unzipped) easily go's above 250 mb because When you install Puppeteer, it downloads a recent version of Chromium (~170MB Mac, ~282MB Linux, ~280MB Win) that is guaranteed to work with the API.
nodeJS
Aws Node Rekognition Analysis S3 Image
Analyse an Image from an S3 Bucket with Amazon Rekognition
nodeJS
Aws Node Restapi Mongodb
Serverless REST API with MongoDB using Mongoose and Bluebird
nodeJS
Aws Node Rest Api Typescript nodeJS
Aws Node Typescript Rest Api
This is simple REST API example for AWS Lambda By Serverless framwork with TypeScript and MongoDB Atlas.
nodeJS
Aws Rest Api Offline
Serverless REST API with DynamoDB and offline support
nodeJS
Aws Rest With Dynamodb
Serverless CRUD service exposing a REST HTTP interface
nodeJS
Aws Fetch File And Store In S3
Fetch an image from remote source (URL) and then upload the image to a S3 bucket.
nodeJS
Aws Scheduled Cron
Example of creating a function that runs as a cron job using the serverless schedule event
nodeJS
Aws Scheduled Weather
Example of creating a function that runs as a cron job using the serverless schedule event through pulling weather and sending an email daily.
nodeJS
Aws Serve Dynamic Html Via Http Endpoint
Hookup an AWS API Gateway endpoint to a Lambda function to render HTML on a GET request
nodeJS
Aws Node Serverless Gong
A simple serverless gong using GitHub webhooks and a Slack app
nodeJS
Aws Node Ses Receive Email Body
Receive an email, store in S3 bucket, trigger a lambda function.
nodeJS
Aws Node Ses Receive Email Header
Receive an email, trigger a lambda function to process header.
nodeJS
Shared Aws Api Gateway Nodejs
A sample of implementing shared API gateway with multiple Node Lambdas.
nodeJS
Aws Node Signed Uploads
Serverless example for S3 signed uploads
nodeJS
Aws Serve Simple Http Endpoint
Example demonstrates how to setup a simple HTTP GET endpoint
nodeJS
Aws Node Simple Transcribe S3
Example demonstrates how to setup a lambda function to transcribe audio file
nodeJS
Aws Single Page App Via Cloudfront
Demonstrating how to deploy a Single Page Application with Serverless
nodeJS
Serverless Single Page App Plugin
A plugin to simplify deploying Single Page Application using S3 and CloudFront
nodeJS
Aws Node Sqs Worker
Serverless Framework Node SQS Producer-Consumer on AWS
nodeJS
Aws Node Stripe Integration
This example for Stripe integration using AWS Lambda and API Gateway.
nodeJS
Aws Node Line Echo Bot
This is a simple echo bot on Telegram
nodeJS
Aws Text Analysis Via Sns Post Processing
Example demonstrates how to setup a simple data processing pipeline
nodeJS
Aws Node Twilio Send Text Message
Send a text message via twilio from aws lambda. See live demo
nodeJS
Baddadjokesbot nodeJS
Aws Node Typescript Apollo Lambda
Serverless example for apollo lambda
nodeJS
Aws Node Typescript Kinesis
Serverless example using Kinesis with TypeScript
nodeJS
Nest Serverless
serverless app
nodeJS
Typescript Example nodeJS
Aws Node Typescript Sqs Standard
Serverless example using Standard SQS with TypeScript
nodeJS
Upload To S3 And Postprocess
Upload a files to S3 to trigger a lambda function.
nodeJS
Aws Node Vue Nuxt Ssr
Sample project for using Nuxt.js to create a server-side rendered Vue.js app on AWS Lambda and AWS API Gateway. Can easily integrate with your own API or 3rd party APIs such as headless CMS, e-commerce or serverless architecture.
nodeJS
Aws Nodejs Websockets Authorizers
Simple example that demonstrates how to use authorizer functions with websocket events
nodeJS
Aws Alexa Skill
This example demonstrates how to use an AWS Lambdas for your custom Alexa skill.
python
Aws Auth0 Api Gateway
Demonstration of protecting API gateway endpoints with auth0
python
Aws Python Flask Api
Example of a Python Flask API service with traditional Serverless Framework
python
Aws Python Flask Dynamodb Api
Example of a Python Flask API service backed by DynamoDB with traditional Serverless Framework
python
Aws Python Line Echo Bot
this is echo bot on LINE message
python
Aws Python Pynamodb S3 Sigurl
Serverless signed uploader REST API using pynamodb, s3 generated events, custom log format, and DRY serverless.yml with custom section
python
Aws Rest With Dynamodb
Serverless CRUD service exposing a REST HTTP interface
python
Aws Rest With Faunadb
Serverless CRUD service exposing a REST HTTP interface
python
Aws Python Rest Api With Pymongo
Serverless pymongo example
python
Aws Rest With Pynamodb
Serverless CRUD service exposing a REST HTTP interface
python
Aws Scheduled Cron
Example of creating a function that runs as a cron job using the serverless schedule event
python
Aws Simple Http Endpoint
Example demonstrates how to setup a simple HTTP GET endpoint with python
python
Aws Python Sqs Worker
Serverless Framework Python SQS Producer-Consumer on AWS
python
Serverless Telegram Bot
This example demonstrates how to setup an echo Telegram Bot using the Serverless Framework ⚡🤖
python
Serverless Ruby Dynamodb Cron
This is an example of creating a function that runs as a cron job using the serverless 'schedule' event. With the usage of the AWS Lambda function, it creates a record to the DynamoDB each and every 30 minutes.
ruby
Aws Ruby Line Bot
Example demonstrates how to setup a simple Line echo bot on AWS
ruby
Aws Ruby Simple Http Endpoint
Example demonstrates how to setup a simple HTTP GET endpoint
ruby
Aws Ruby Sinatra Dynamodb Api
Example of a Ruby Sinatra API service backed by DynamoDB with traditional Serverless Framework
ruby
Aws Ruby Step Functions Callback
Ruby example that make usage of AWS Step Functions with callback pattern, AWS Lambda, DynamoDB, Amazon Comprehend, API Gateway, and Step Functions flows
ruby
Serverless Ruby Sqs Dynamodb
A serverless ruby example that creates DynamoDB records with the usage of SQS, API Gateway, and AWS Lambda functions.
ruby
Aws Ruby Step Functions
Ruby example that make usage of AWS Step Functions with AWS Lambda, DynamoDB and Step Functions flows.
ruby
Aws Ruby Step Functions Express Workflow
Ruby example that make usage of AWS Step Functions Express Type with AWS Lambda, DynamoDB, Amazon SES, API Gateway, and Step Functions flows
ruby
Aws Rust Simple Http Endpoint
Example demonstrates how to setup a simple HTTP GET endpoint with rust
nodeJS
Azure Nodejs
Azure Functions sample for the Serverless framework
nodeJS
Azure Node Simple Http Endpoint
An example of making http endpoints with the Azure Functions Serverless Framework plugin
nodeJS
Azure Nodejs
Azure Functions sample for the Serverless framework
nodeJS
Service Bus Trigger Example
Serverless application for asset model creation
nodeJS
Google Golang Simple Http Endpoint
Example demonstrates how to setup a simple HTTP GET endpoint with golang
golang
Google Node Simple Http Endpoint
An example of making http endpoints with the Google Cloud Functions Serverless Framework plugin.
nodeJS
Gcp Node Typescript Simple
Simple HTTP example for GCP functions by Serverless framework with Typescript
nodeJS
Google Python Simple Http Endpoint
Example demonstrates how to setup a simple HTTP GET endpoint with python
python
Kubeless Python Simple Function
This example demonstrates how to setup a simple Python function with Kubeless
python
Kubeless Python Simple Scheduled Function
This example demonstrates how to setup a simple Python function with Kubeless
python
Openwhisk Go Simple
Example demonstrates how to setup a simple Go function with OpenWhisk.
nodeJS
Openwhisk Node And Docker Chaining Functions
Example of chaining function calls using sequences and docker images.
nodeJS
Openwhisk Node Chaining Functions
Example of chaining function calls using sequences and the sdk.
nodeJS
Openwhisk Node Scheduled Cron
Example of creating a function that runs as a cron job using the serverless schedule event.
nodeJS
Openwhisk Node Simple Http
Example demonstrates how to setup a simple HTTP GET endpoint with OpenWhisk.
nodeJS
Openwhisk Node Simple
Simple example demonstrating OpenWhisk provider support.
nodeJS
Openwhisk Php Simple
Example demonstrates how to setup a simple PHP function with OpenWhisk.
php
Openwhisk Python Scheduled Cron
Example of creating a Python function that runs as a cron job using the serverless schedule event.
python
Openwhisk Python Simple Http Endpoint
Example demonstrates how to setup a simple HTTP GET endpoint with OpenWhisk.
python
Openwhisk Python Simple
Example demonstrates how to setup a simple Python function with OpenWhisk.
python
Openwhisk Ruby Simple
Example demonstrates how to setup a simple Ruby function with OpenWhisk.
ruby
Openwhisk Rust Simple Http Endpoint
Example demonstrates how to setup a simple Rust function with OpenWhisk.
nodeJS
Openwhisk Swift Package With Precompiled Binaries
Swift packages and pre-compiled binaries on OpenWhisk.
swift
Openwhisk Swift Scheduled Cron
Example of creating a Swift function that runs as a cron job using the serverless schedule event.
swift
Openwhisk Swift Simple Http Endpoint
Example demonstrates how to setup a simple HTTP endpoint using Swift function with OpenWhisk.
swift
Openwhisk Swift Simple
Example demonstrates how to setup a simple Swift function with OpenWhisk.
swift
Twilio.node Forward Call
Example demonstrating Twilio Runtime support with an endpoint that returns TwiML to forward a phone call
nodeJS

Community Examples

Add an example

To install any of these you can run:

serverless install -u https://github.com/author/project -n my-project

Contributing

We are happy to accept more examples from the community. 🎉

Adding example code

  1. Make sure your contribution matches the linting setup for this repo:

Run the linting via

npm run lint
  1. Add a package.json file in your example with the name of the example and a description and any dependencies used.

  2. Regenerate the README.md with the following command

npm run docs
  1. Open a new pull request with your example. ⚡️

Adding a community example

We love hearing about projects happening in the community. Feel free to add your serverless project to our growing list.

  1. Add link, title, and description to the community-examples.json file.

  2. Open a new pull request with your example. ⚡️

About

Serverless Examples – A collection of boilerplates and examples of serverless architectures built with the Serverless Framework on AWS Lambda, Microsoft Azure, Google Cloud Functions, and more.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published