Skip to content

Conversation

@marcobiscaro2112
Copy link
Collaborator

rest-json and json protocols are not the same.

rest-json is defined by [1], and uses application/json content type.

json is a AWS-specific protocol defined by [2], that uses a custom application/x-amz-json-1.0 or application/x-amz-json-1.1 content type. It also requires the X-Amz-Target header.

Fixes #168
Fixes #241

[1] https://smithy.io/2.0/aws/protocols/aws-restjson1-protocol.html
[2] https://smithy.io/2.0/aws/protocols/aws-json-1_0-protocol.html and https://smithy.io/2.0/aws/protocols/aws-json-1_1-protocol.html

`rest-json` and `json` protocols are not the same.

`rest-json` is defined by [1], and uses `application/json` content type.

`json` is a AWS-specific protocol defined by [2], that uses a custom `application/x-amz-json-1.0` or `application/x-amz-json-1.1` content type. It also requires the `X-Amz-Target` header.

Fixes #168
Fixes #241

[1] https://smithy.io/2.0/aws/protocols/aws-restjson1-protocol.html
[2] https://smithy.io/2.0/aws/protocols/aws-json-1_0-protocol.html and https://smithy.io/2.0/aws/protocols/aws-json-1_1-protocol.html
@marcobiscaro2112 marcobiscaro2112 marked this pull request as ready for review August 26, 2025 19:19
@marcobiscaro2112 marcobiscaro2112 merged commit ace0f97 into main Sep 2, 2025
4 checks passed
@marcobiscaro2112 marcobiscaro2112 deleted the mb/json-content-types branch September 2, 2025 18:23
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

Successfully merging this pull request may close these issues.

Verified Permissions always return 400 incorrect Unsupported Media Type when calling savingsplans API

3 participants