We implemented a third-party API using a WSDL it provided us.
The implementation is in C# using Visual studio built-in service reference util (it takes WSDL file and create a service reference file with all services and classes)
in the reference.cs file there is a member named "CreateDate" which is of type DateTime.
The problem is that the third party API is sending us this member data with milliseconds in the format of 3 places after the dot, but when I try to send this data back to the web service the WSDL framework is deleting the last zero from the millisecond's member
for example:
the 3rd party API is sending "CreateDate="2020-03-26T07:49:05.640+00:00" the .net framework is serializing this data into c# classes. so far so good. we save this class so we can send it later to the web service we build the requests to the web service with the DateTime which is valid at this point (see debugger screenshot)
when I "catch" the RAW request that is being passed the value of the date-time is invalid (see screenshot)
(since I can't use fiddler for technical issues the way I catch these requests is by implementing a MessageInspector class and use a debugger to inspect the System.ServiceModel.Channels.Message before it's sent to the web service)
when I send this data I get an error from the web service since they have validation on that field.
somewhere, after my control, the .net serializer (I guess) is transforming a DateTime class into a string\stream with different value
any suggestion will help
thanks