janssenr / SendCloudApi.Net

A C#/.net wrapper for the SendCloud API
MIT License
6 stars 5 forks source link

Error message when getting list of shipments #6

Closed davidkdb closed 3 years ago

davidkdb commented 3 years ago

Hi,

When getting a list of shipments we get this error:

System.Runtime.Serialization.SerializationException HResult=0x8013150C Message=There was an error deserializing the object of type System.Collections.Generic.Dictionary2[[System.String, System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[SendCloudApi.Net.Models.Shipment[], SendCloudApi.Net, Version=2.0.2.0, Culture=neutral, PublicKeyToken=null]]. String '2021-03-06T09:26:49Z' was not recognized as a valid DateTime. Source=System.Private.DataContractSerialization StackTrace: at System.Runtime.Serialization.XmlObjectSerializer.ReadObjectHandleExceptions(XmlReaderDelegator reader, Boolean verifyObjectName, DataContractResolver dataContractResolver) at System.Runtime.Serialization.Json.DataContractJsonSerializerImpl.ReadObject(XmlDictionaryReader reader) at System.Runtime.Serialization.Json.DataContractJsonSerializerImpl.ReadObject(Stream stream) at System.Runtime.Serialization.Json.DataContractJsonSerializer.ReadObject(Stream stream) at SendCloudApi.Net.Helpers.JsonHelper.DeserializeAsDictionary[T](String json, String dateTimeFormat) at SendCloudApi.Net.SendCloudApi.<SendRequest>d__251.MoveNext() at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter1.GetResult() at SendCloudApi.Net.SendCloudApi.<Get>d__221.MoveNext() at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter1.GetResult() at SendCloudApi.Net.Resources.SendCloudApiIntegrationsResource.<GetShipments>d__3.MoveNext() at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.ConfiguredTaskAwaitable1.ConfiguredTaskAwaiter.GetResult()

Inner Exception 1: FormatException: String '2021-03-06T09:26:49Z' was not recognized as a valid DateTime.

We are using a Shopify connector in Sendcloud.

.Net Core 3.1

janssenr commented 3 years ago

I cannot test this, because I don't have an active integration. Can I get your ApiKey and Secret? To test and solve this? I will delete them afterwards.

davidkdb commented 3 years ago

Is there a way of sending private here ? (the apikey/secret)

janssenr commented 3 years ago

You can send them to rob.janssen@upcmail.nl

davidkdb commented 3 years ago

Email sent.

janssenr commented 3 years ago

Error should be solved now.