1 Answer
- Newest
- Most votes
- Most comments
0
Lambda functions receive two parameters: Event object and Context object. The event object contains all the information about why it was triggered. The context object contains different run-time information, e.g., request ID. Most customers don't use the context object.
When you invoke the function using the Invoke API, the event object will contain the payload that you send in the API call. Usually clients will not invoke the function directly. They will use other services to invoke the function, e.g., API Gateway to expose a REST API that invokes the function for every API call. In this case, when API GW invokes the function, the payload will include the entire REST request, including all the headers, body, etc.
Relevant content
- asked 5 months ago
- asked 5 months ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated a year ago