AnsweredAssumed Answered

API Call to Publishformxml fails

Question asked by niclas.carlsson on Sep 21, 2017
Latest reply on Oct 6, 2017 by niclas.carlsson

Hi

 

I'm trying to get a form from a list and publish it using the Nintex Forms API (https://help.nintex.com/en-US/sdks/sdk2013/#FormSDK/Topics/SDK_NF_API_REF_PublishFormXml.htm ) 

 

It works fine getting the form XML using GetFormXML (https://help.nintex.com/en-US/sdks/sdk2013/#FormSDK/Topics/SDK_NF_API_REF_GetFormXml.htm) and saving it to a variable but the PublishFormXml call fails all the time with the error "Error performing web request". The XML from GetFormXML is saved in a variable that I use to send in to PublishFormXML. 

 

 

The error message is: 

 

 

The server encountered an error processing the request. The exception message is 'The formatter threw an exception while trying to deserialize the message: There was an error while trying to deserialize parameter http://tempuri.org/:listId. The InnerException message was 'There was an error deserializing the object of type System.String. Encountered unexpected character '''.'. Please see InnerException for more details.'. See server logs for more details. The exception stack trace is:

at System.ServiceModel.Dispatcher.DataContractJsonSerializerOperationFormatter.DeserializeParameterPart(XmlDictionaryReader reader, PartInfo part)
at System.ServiceModel.Dispatcher.DataContractJsonSerializerOperationFormatter.DeserializeParameters(XmlDictionaryReader reader, PartInfo[] parts, Object[] parameters, PartInfo returnInfo, Object& returnValue)
at System.ServiceModel.Dispatcher.DataContractJsonSerializerOperationFormatter.DeserializeBodyCore(XmlDictionaryReader reader, Object[] parameters, Boolean isRequest)
at System.ServiceModel.Dispatcher.DataContractJsonSerializerOperationFormatter.DeserializeBody(XmlDictionaryReader reader, MessageVersion version, String action, MessageDescription messageDescription, Object[] parameters, Boolean isRequest)
at System.ServiceModel.Dispatcher.OperationFormatter.DeserializeBodyContents(Message message, Object[] parameters, Boolean isRequest)
at System.ServiceModel.Dispatcher.OperationFormatter.DeserializeRequest(Message message, Object[] parameters)
at System.ServiceModel.Dispatcher.DemultiplexingDispatchMessageFormatter.DeserializeRequest(Message message, Object[] parameters)
at System.ServiceModel.Dispatcher.UriTemplateDispatchFormatter.DeserializeRequest(Message message, Object[] parameters)
at System.ServiceModel.Dispatcher.DispatchOperationRuntime.DeserializeInputs(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage31(MessageRpc& rpc)
at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)

Outcomes