Skip to content

Conversation

svozza
Copy link
Contributor

@svozza svozza commented Aug 14, 2025

Summary

The event handler will eventually support multiple lambda event type (ALB etc). types, as such we need a common format to represent these requests. This PR adds a utility function to convert the event to the web Request types

Changes

  • Adds the proxyEventToWebRequest function to handle to conversion.
  • Adds a type guard function to ensure that the event to be converted is the correct type.
  • Unit tests for both functions.

Issue number: closes #4342


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Disclaimer: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.

@boring-cyborg boring-cyborg bot added event-handler This item relates to the Event Handler Utility tests PRs that add or change tests labels Aug 14, 2025
@pull-request-size pull-request-size bot added the size/L PRs between 100-499 LOC label Aug 14, 2025
@svozza svozza requested a review from dreamorosi August 14, 2025 18:44
@svozza svozza self-assigned this Aug 14, 2025
@svozza svozza force-pushed the event-handler/response-handling-arch branch 2 times, most recently from 7ad4112 to 7eb3a90 Compare August 14, 2025 18:58
@svozza svozza changed the title add function to convert Lambda proxy event to web response object feat(event-handler): add function to convert Lambda proxy event to web response object Aug 14, 2025
@svozza svozza force-pushed the event-handler/response-handling-arch branch from 7eb3a90 to e0a43ab Compare August 15, 2025 08:17
@svozza svozza requested a review from dreamorosi August 15, 2025 08:21
Co-authored-by: Andrea Amorosi <dreamorosi@gmail.com>
@svozza svozza requested a review from dreamorosi August 15, 2025 09:24
Copy link

@svozza svozza merged commit 6277e0d into main Aug 15, 2025
34 checks passed
@svozza svozza deleted the event-handler/response-handling-arch branch August 15, 2025 11:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
event-handler This item relates to the Event Handler Utility size/L PRs between 100-499 LOC tests PRs that add or change tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature request: Add function to convert Lambda event to web Request object
2 participants