Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cro::MediaType can't parse AWS content types. #34

Closed
jonathanstowe opened this issue Nov 22, 2021 · 0 comments
Closed

Cro::MediaType can't parse AWS content types. #34

jonathanstowe opened this issue Nov 22, 2021 · 0 comments

Comments

@jonathanstowe
Copy link

This is kind of alluded to in #7 but I thought I'd make it more explicit now that I have an actual example in the wild.

The AWS Secrets Manager, DynamoDB and probably others require a content-type of application/x-amz-json-1.1 in requests and respond with the same content-type.

Unfortunately this gives rise to X::Cro::MediaType::Invalid when creating the request and when requesting the body from the response.

The only workaround I have found is to replace both the BodySerializers and BodyParsers with ones that ignore the content type when creating the Cro::HTTP::Client (which is fine in a library, but might be a bit of a faff if one wanted to re-use the client.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant