Using Web request method PUT

  • 29 October 2015
  • 4 replies
  • 9 views

Badge +3

Hi there! I'm using Nintex Workflow 2013 to send web requests to remote system.

When i send GETPOST request, all seems worked fine. But when i try to use "Other" web methods, trouble arises.

I'm adding action "Web request", in "method" option choosing Other, then typing "PUT" into field.

And then i'm add headers that i need: Content-Type and Content-Length with appropriate values (without this my remote system responds "forbidden" and it's ok, already tested with Fiddler).

When i try to test this in "Play now" window, error appears: "The content-type header must be modified using appropriate property or method."

That statement looks like not Nintex-intended issue but common WebHeaderCollection classHttpRequestHeader issue. I'm already know that some common headers are considered restricted and are either exposed directly by the API (including mine Content-Type) or protected by the system and cannot be changed.

And i suppose, that Nintex adds default headers and does not allow change that headers with my interface, right?

Screenshot from "Play now" below (!i've deleted URL and Content parameters manually only for screenshot after testing!)

PUTPlayNow.png


4 replies

Userlevel 5
Badge +9

Have you tested your web request without the Content-Type header ?

Badge +3

Of course, remote server returns 403 forbidden error, i need to specify both Content-Type and Content-Length headers as documented at remote service API documentation.

Userlevel 5
Badge +9

ok, In this case you should open a ticket to Nintex Support.

I'm also unable to define the Content-Type header by adding a header. It's only possible to define it when performing a POST request where there is a specific field for this header.

Badge +3

Hello! After updating Nintex to current version (3.1.6.0) problem has gone and things worked flawlessly!

Although changelog contain notes about POST request fixes, it seems that whole action Web Request has been fixed:

- Corrected a Headers error on HTTP POST Web Request

- Corrected an issue where a Web Request - POST method content type gets ignored

So, the solution is update to latest build check.png

Reply