XSD 亚马逊 MWS 产品 Feed 的验证说明
XSD validation clarification for Amazon MWS product feed
我正在寻找有关如何阅读亚马逊用来验证其 XML 产品 Feed 的 XSD 的说明。
这是XSD used (and the inner Product one) and these are the docs。
当我提交没有描述或 BulletPoint 提要的基本产品提要时,我收到此错误:
A value was not provided for "bullet_point1". Please provide a value for "bullet_point1". This information appears on the product detail page and helps customers evaluate products.
A value was not provided for "product_description". Please provide a value for "product_description". This information appears on the product detail page and helps customers evaluate products.
以下是相关的 XSD 部分:
<xsd:element name="Description" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:normalizedString">
<xsd:maxLength value="2000"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="BulletPoint" type="LongStringNotNull" minOccurs="0" maxOccurs="5"/>
我的理解是 minOccurs="0"
意味着它不是必需的,但显然是。我已经查看了这些字段的其他一些内部 XSD(例如 Base),以防它们被覆盖但没有看到任何东西。
这是错误的吗XSD?我读错了吗?
是的,minOccurs="0"
表示可选,但是...
一般来说,应用程序通常有超出其 XML 输入的 XSD 中指定的额外要求。当仅在某些情况下需要参数时,XSD 将在一般情况下将它们列为可选参数,然后在 XSD 的带外检查它们。 (XSD 1.1 通过 xs:assertion
为有条件地要求 elements/attributes 提供了一些额外的表现力,但它尚未被广泛采用。)
请注意,bullet_point1
没有出现在您链接到问题的任何 XSD 或文档中。如果 bullet_point1
派生自 XSD 中的 BulletPoint
,那么显然是下游应用程序提出了额外的要求,并在未满足时发出错误。
我向亚马逊开发人员询问了这个问题,他们回答我:
xsd of categories are not correctly updated so some elements would be
required but not reflected in the .xsd document thaty's the problem.
我正在寻找有关如何阅读亚马逊用来验证其 XML 产品 Feed 的 XSD 的说明。
这是XSD used (and the inner Product one) and these are the docs。
当我提交没有描述或 BulletPoint 提要的基本产品提要时,我收到此错误:
A value was not provided for "bullet_point1". Please provide a value for "bullet_point1". This information appears on the product detail page and helps customers evaluate products.
A value was not provided for "product_description". Please provide a value for "product_description". This information appears on the product detail page and helps customers evaluate products.
以下是相关的 XSD 部分:
<xsd:element name="Description" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:normalizedString">
<xsd:maxLength value="2000"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="BulletPoint" type="LongStringNotNull" minOccurs="0" maxOccurs="5"/>
我的理解是 minOccurs="0"
意味着它不是必需的,但显然是。我已经查看了这些字段的其他一些内部 XSD(例如 Base),以防它们被覆盖但没有看到任何东西。
这是错误的吗XSD?我读错了吗?
是的,minOccurs="0"
表示可选,但是...
一般来说,应用程序通常有超出其 XML 输入的 XSD 中指定的额外要求。当仅在某些情况下需要参数时,XSD 将在一般情况下将它们列为可选参数,然后在 XSD 的带外检查它们。 (XSD 1.1 通过 xs:assertion
为有条件地要求 elements/attributes 提供了一些额外的表现力,但它尚未被广泛采用。)
请注意,bullet_point1
没有出现在您链接到问题的任何 XSD 或文档中。如果 bullet_point1
派生自 XSD 中的 BulletPoint
,那么显然是下游应用程序提出了额外的要求,并在未满足时发出错误。
我向亚马逊开发人员询问了这个问题,他们回答我:
xsd of categories are not correctly updated so some elements would be required but not reflected in the .xsd document thaty's the problem.