Commit 9a237d7
committed
feat(event_handler): enhance OpenAPI response with headers, links, examples and encoding
- Add OpenAPIResponseHeader TypedDict with full OpenAPI spec compliance
- Add headers and links fields to OpenAPIResponse TypedDict
- Add examples and encoding fields to content models
- Fix processing logic to preserve examples when using model field
- Maintain 100% backward compatibility with total=False
- Add comprehensive functional tests covering all scenarios
Fixes aws-powertools#48701 parent 02b2305 commit 9a237d7
File tree
3 files changed
+492
-4
lines changed- aws_lambda_powertools/event_handler
- openapi
- tests/functional/event_handler/_pydantic
3 files changed
+492
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
675 | 675 | | |
676 | 676 | | |
677 | 677 | | |
678 | | - | |
| 678 | + | |
679 | 679 | | |
680 | 680 | | |
681 | 681 | | |
682 | 682 | | |
| 683 | + | |
| 684 | + | |
| 685 | + | |
| 686 | + | |
| 687 | + | |
683 | 688 | | |
684 | 689 | | |
685 | 690 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
66 | 77 | | |
67 | 78 | | |
| 79 | + | |
| 80 | + | |
68 | 81 | | |
69 | 82 | | |
70 | | - | |
| 83 | + | |
71 | 84 | | |
| 85 | + | |
| 86 | + | |
72 | 87 | | |
73 | 88 | | |
74 | | - | |
75 | | - | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
76 | 92 | | |
| 93 | + | |
0 commit comments