diff --git a/docs/source/1.0/spec/core/http-traits.rst b/docs/source/1.0/spec/core/http-traits.rst index 23468435747..aab5b3af32c 100644 --- a/docs/source/1.0/spec/core/http-traits.rst +++ b/docs/source/1.0/spec/core/http-traits.rst @@ -788,11 +788,10 @@ Trait selector .. code-block:: none structure > member - :test(> map > member[id|member=value] > :test(string, collection > member > string)) + :test(> map > member[id|member=value] > string) The ``httpPrefixHeaders`` trait can be applied to ``structure`` members - that target a ``map`` of ``string``, or a ``map`` of ``list``/``set`` of - ``string``. + that target a ``map`` of ``string``. Value type ``string`` value that defines the prefix to prepend to each header field name stored in the targeted map member. For example, given a prefix value diff --git a/smithy-model/src/main/resources/software/amazon/smithy/model/loader/prelude.smithy b/smithy-model/src/main/resources/software/amazon/smithy/model/loader/prelude.smithy index 356bfa76b59..d7aaea39b34 100644 --- a/smithy-model/src/main/resources/software/amazon/smithy/model/loader/prelude.smithy +++ b/smithy-model/src/main/resources/software/amazon/smithy/model/loader/prelude.smithy @@ -610,7 +610,7 @@ string httpHeader /// Binds a map of key-value pairs to prefixed HTTP headers. @trait(selector: """ structure > member - :test(> map > member[id|member=value] > :test(string, collection > member > string))""", + :test(> map > member[id|member=value] > string)""", structurallyExclusive: "member", conflicts: [httpLabel, httpQuery, httpHeader, httpPayload, httpResponseCode, httpQueryParams]) @tags(["diff.error.const"]) diff --git a/smithy-openapi/src/test/resources/software/amazon/smithy/openapi/fromsmithy/mappers/prefix-headers.smithy b/smithy-openapi/src/test/resources/software/amazon/smithy/openapi/fromsmithy/mappers/prefix-headers.smithy index 46968373814..d47b8e39f8c 100644 --- a/smithy-openapi/src/test/resources/software/amazon/smithy/openapi/fromsmithy/mappers/prefix-headers.smithy +++ b/smithy-openapi/src/test/resources/software/amazon/smithy/openapi/fromsmithy/mappers/prefix-headers.smithy @@ -24,9 +24,5 @@ structure Output { map Headers { key: String, - value: StringList, -} - -list StringList { - member: String + value: String }