Invoking methods from the REST API

This topic describes how to use the RESTful endponts of the Nintex FormsWeb Service API.

You can invoke any of the following REST methods from the NfRestService service provided by Nintex Forms:

For more information about the REST methods, see Web Service Reference.

Authenticating methods

The method request is authenticated by SharePoint, by providing a valid form digest in the X-RequestDigest header for both SharePoint 2010 and SharePoint 2013. For more information about the X-RequestDigest header, see X-RequestDigest Header on the Microsoft Developer Network..

If you are using Nintex Forms 2010, see Authenticating the REST API with SharePoint 2010 for more information about retrieving a form digest value from SharePoint 2010. Otherwise, if you're using Nintex Forms 2013, see Authenticating the REST API with NintexForms 2013 for more information about retrieving a form digest value from SharePoint 2013.

Wrapping message bodies

The methods for the NfRestService service are implemented using Windows Communication Foundation (WCF), and are implemented using either the WebMessageBodyStyle.WrappedRequest (for GetFormXml and PublishFormXml) or WebMessageBodyStyle.Wrapped (for DeleteForm) body styles. This implementation means that, instead of providing parameters as part of the request URL for one of these methods, they are instead provided in the request body, as the property of a JSON object.

For example, to invoke the DeleteForm method to delete the Nintex form definition for a SharePoint list, the identifier for the list is not provided as a parameter in the request URL. Instead, the request body is set to the following JSON object, in which the identifier for the list is provided as a property in the JSON object:

{
    "listId": "{DB0ECEE6-117D-4519-986E-020A9BE6A7E3}"
}

Similarly, the response body provided by DeleteForm is wrapped as a JSON object, as well. If the DeleteForm request described in the previous example was successfully invoked, the method returns the following JSON object, in which the DeleteFormResult property returns the relative URL for the default view of the SharePoint list from which the form was deleted:

{
  "DeleteFormResult": "/Lists/Test List/AllItems.aspx"
}

Related information

Migrate Forms with the Nintex Forms Web Service API

Web Service Reference