Skip to main content
Nintex Community Menu Bar

Call WebService error

  • Sep 5, 2017 9:02 AM UTC
  • 3 replies
  • 30 views
  • Translate All

Forum|alt.badge.img+13

Hi,

I'm following Ben Stori‌ blog Get List Item Attachments using Web Services  to get the name of an attachment from a workflow task form so that it can be used later on in the workflow for building a hyperlink to it.

I'm getting a "Bad Request" response. First time using this action in O365 and there's plenty that looks wrong with what I'm doing, but hoping someone might be able to help me out with this.

Firstly I've built the dictionary

When I output this in an email I get this (are those additional backslashes meant to be there?)

{"Content-type":"application/json;odata=verbose","Accept":"application/json;odata=verbose"}

Then I build the URL

‍{Workflow Context:Current site URL}‍_api/web/lists/getbytitle('Workflow Tasks')/items(‍{Variable:vnumTaskID}‍)/attachmentFiles

When I output this in an email I get this

https://tenantname/sites/heals/_api/web/lists/getbytitle('Workflow Tasks')/items(117)/attachmentFiles

This looks right to me.

Then my Call Web Service action is configured with the following

Can anyone see why I'm getting the "BadRequest" error?

Thanks

3 replies

Forum|alt.badge.img+13
  • Author
  • Novice
  • Sep 5, 2017 11:23 AM UTC

Ignore me. The URL had a carriage return inserted into it, not sure why.

Translate

Forum|alt.badge.img+7
  • Nintex Partner
  • Sep 5, 2017 1:37 PM UTC

I am glad you were able to get this working!

Translate

Forum|alt.badge.img+13
  • Author
  • Novice
  • Sep 5, 2017 1:39 PM UTC

yes, ahem, user error.

Translate