Last active
October 12, 2020 11:44
-
-
Save bmccann36/1b4ffa48e94f1f8aecae785777a55bb9 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
functions: | |
create: #defines a function named create | |
handler: com.notesservice.CreateNote # points to the location of the code to invoke | |
events: # defines what type of event will trigger the invocation | |
- http: # creates a REST endpoint for you | |
path: notes # calling POST - {apiGatewayUrl}/notes will lead to this function's invocation | |
method: post | |
get: | |
handler: com.notesservice.GetNote | |
events: | |
- http: | |
path: notes/{id} # calling GET - {apiGatewayUrl}/notes/{id} will lead to this function's invocation | |
method: get |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment