I tried to create an image resizer lambda function and for that I use S3 bucket for storage, but when I try to add Redirection rules under S3 properties it does not allow me to save it. It keep giving me error
(Unknown Error
An unexpected error occurred.
API response
Expected params.WebsiteConfiguration.RoutingRules to be an Array)
this is the redirect rule I'm trying to add
<RoutingRules>
<RoutingRule>
<Condition>
<KeyPrefixEquals/>
<HttpErrorCodeReturnedEquals>404</HttpErrorCodeReturnedEquals>
</Condition>
<Redirect>
<Protocol>https</Protocol>
<HostName>API-endpoint</HostName>
<ReplaceKeyPrefixWith>prod/resize?key=</ReplaceKeyPrefixWith>
<HttpRedirectCode>307</HttpRedirectCode>
</Redirect>
</RoutingRule>
</RoutingRules>