We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d272e5a commit b8d790bCopy full SHA for b8d790b
examples/sst/packages/functions/src/todo.ts
@@ -1,8 +1,10 @@
1
-export const handler = async () => {
2
- console.log("TODO LIST", JSON.stringify({ MESSAGE:[{ id: 1, text: "TODO 1" }]}));
3
-
4
- return {
+import { APIGatewayProxyEventV2, Callback, Context } from "aws-lambda";
+
+export const handler = (a: APIGatewayProxyEventV2, b: Context, c: Callback) => {
+ console.log("TODO LIST", JSON.stringify({ MESSAGE: [{ id: 1, text: "TODO 1" }] }));
5
6
+ c(null, {
7
statusCode: 200,
- body: JSON.stringify({ MESSAGE:[{ id: 1, text: "TODO 12" }]}),
- }
8
+ body: JSON.stringify({ MESSAGE: [{ id: 1, text: "TODO 12" }] }),
9
+ })
10
}
0 commit comments