diff --git a/resources/metadata/modifications.json b/resources/metadata/modifications.json index 10d03595c..c3fb32279 100644 --- a/resources/metadata/modifications.json +++ b/resources/metadata/modifications.json @@ -46,6 +46,24 @@ } ] }, + "merchant-fulfillment": { + "0": [ + { + "comment": "Remove required 'RequiresAdditionalSellerInputs', its not always present in response", + "action": "replace", + "path": "components.schemas.ShippingService.required", + "value": [ + "CarrierName", + "Rate", + "ShipDate", + "ShippingServiceId", + "ShippingServiceName", + "ShippingServiceOfferId", + "ShippingServiceOptions" + ] + } + ] + }, "orders": { "0": [ { diff --git a/resources/models/seller/merchant-fulfillment/v0.json b/resources/models/seller/merchant-fulfillment/v0.json index 0ca91ec2d..a08f51233 100644 --- a/resources/models/seller/merchant-fulfillment/v0.json +++ b/resources/models/seller/merchant-fulfillment/v0.json @@ -3080,7 +3080,6 @@ "required": [ "CarrierName", "Rate", - "RequiresAdditionalSellerInputs", "ShipDate", "ShippingServiceId", "ShippingServiceName", @@ -3543,4 +3542,4 @@ } }, "x-original-swagger-version": "2.0" -} \ No newline at end of file +} diff --git a/src/Seller/MerchantFulfillmentV0/Dto/ShippingService.php b/src/Seller/MerchantFulfillmentV0/Dto/ShippingService.php index 20e2f5b29..e1cda9900 100644 --- a/src/Seller/MerchantFulfillmentV0/Dto/ShippingService.php +++ b/src/Seller/MerchantFulfillmentV0/Dto/ShippingService.php @@ -41,7 +41,7 @@ final class ShippingService extends Dto * @param \DateTimeInterface $shipDate Date-time formatted timestamp. * @param CurrencyAmount $rate Currency type and amount. * @param ShippingServiceOptions $shippingServiceOptions Extra services provided by a carrier. - * @param bool $requiresAdditionalSellerInputs When true, additional seller inputs are required. + * @param ?bool $requiresAdditionalSellerInputs When true, additional seller inputs are required. * @param ?\DateTimeInterface $earliestEstimatedDeliveryDate Date-time formatted timestamp. * @param ?\DateTimeInterface $latestEstimatedDeliveryDate Date-time formatted timestamp. * @param ?AvailableShippingServiceOptions $availableShippingServiceOptions The available shipping service options. @@ -57,7 +57,7 @@ public function __construct( public readonly \DateTimeInterface $shipDate, public readonly CurrencyAmount $rate, public readonly ShippingServiceOptions $shippingServiceOptions, - public readonly bool $requiresAdditionalSellerInputs, + public readonly ?bool $requiresAdditionalSellerInputs = null, public readonly ?\DateTimeInterface $earliestEstimatedDeliveryDate = null, public readonly ?\DateTimeInterface $latestEstimatedDeliveryDate = null, public readonly ?AvailableShippingServiceOptions $availableShippingServiceOptions = null,