Amazon-SP-API-CSharp icon indicating copy to clipboard operation
Amazon-SP-API-CSharp copied to clipboard

FulFillmentInboundServicev20240320.ListDeliveryWindowOptionsAsync return dates as null

Open dmelendez35 opened this issue 1 year ago • 2 comments

The method FulFillmentInboundServicev20240320.ListDeliveryWindowOptionsAsync is returning the rows, however, all the date fields return null. When I test the same request in postman it returns the dates fields with values. The field "DeliveryWindowOptionId" is also null

See image image

dmelendez35 avatar Oct 17 '24 14:10 dmelendez35

So I tested creating a different model where the dates are of type 'string', I had to inherith the 'FulFillmentInboundServicev20240320' service in order to copy the method and make use of my modified model, and it worked! So the problem seems to be this line:

var response = await RequestClient.ExecuteAsync<T>(Request, cancellationToken);

where RequestClient is unable to parse the date string in the fields "startDate", "endDate", "validUntil", and that also affects "DeliveryWindowOptionId" somehow. This is an example of the format in the fields: "2024-10-25T00:00Z" that is causing problems to be converted to DateTime? I believe.

So I appreciate any help fixing that, to avoid having to keep my inherited service

dmelendez35 avatar Oct 18 '24 14:10 dmelendez35

So I tested creating a different model where the dates are of type 'string', I had to inherith the 'FulFillmentInboundServicev20240320' service in order to copy the method and make use of my modified model, and it worked! So the problem seems to be this line:

var response = await RequestClient.ExecuteAsync(Request, cancellationToken);

where RequestClient is unable to parse the date string in the fields "startDate", "endDate", "validUntil", and that also affects "DeliveryWindowOptionId" somehow. This is an example of the format in the fields: "2024-10-25T00:00Z" that is causing problems to be converted to DateTime? I believe.

So I appreciate any help fixing that, to avoid having to keep my inherited service

Hi! This error is already fixed. The fix was waiting for approving and now it is approved.

Baros6647 avatar Oct 28 '24 18:10 Baros6647