My Serverless Application

Welcome to your AWS serverless application. This example application has several resources configured for you to explore. State is stored in memory in a given container, and is therefore ephemeral - see Understanding Container Reuse in AWS Lambda for more information.

Resources

GET /users

 Returns a list of all users.

curl https://api.staging.gamegen.diy/users -H 'accept: application/json'

POST /users

 Creates a new user.

curl https://api.staging.gamegen.diy/users -X POST -d '{"name":"Sam"}' -H 'accept: application/json'

GET /users/:userId

 Returns a single user.

curl https://api.staging.gamegen.diy/users/1 -H 'accept: application/json'

PUT /users/:userId

 Updates an existing user.

curl https://api.staging.gamegen.diy/users/1 -X PUT -d '{"name":"Samantha"}' -H 'accept: application/json'

DELETE /users/:userId

 Deletes an existing user.

curl https://api.staging.gamegen.diy/users/1 -X DELETE -H 'accept: application/json'

Form

Experiment with POST and PUT via the form below. Leave the id empty to create a new user (POST) or enter an id to update a user's name (PUT).