Expand my Community achievements bar.

Join us LIVE in San Francisco on November 14th for Experience Makers The Skill Exchange. Don't miss out on this free learning event!
SOLVED

Erro while working on Multiple Task Assignment through API

Avatar

Level 1

Hi Team,

 

We require your help on multiple assignment in tasks. We are referring - Tasks (workfront.com) for multiple assignments like role, user & team through fusion.

 

Please find fusion setup below-

DP12_0-1678106322532.png

 

 

Getting below error –

DP12_1-1678106322535.png

 

 

As now we are trying with hardcoded values. We verified all the ids are correct.

 

Any inputs on this will be highly appreciated.

 

Thanks

Deepak

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

The "Misc Action" module makes this easier than the "Custom API" module does, but either can work. 

"Misc Action" would look like this:

William_0-1678116628039.png



If you must use Custom API call module, you need to pass the arguments as JSON in the request body; not as parameters in the query string: 

William_1-1678116892578.png

 

Good luck!

If you like my content, please take a moment to view and vote on my Idea Requests: https://tinyurl.com/4rbpr7hf

View solution in original post

3 Replies

Avatar

Correct answer by
Community Advisor

The "Misc Action" module makes this easier than the "Custom API" module does, but either can work. 

"Misc Action" would look like this:

William_0-1678116628039.png



If you must use Custom API call module, you need to pass the arguments as JSON in the request body; not as parameters in the query string: 

William_1-1678116892578.png

 

Good luck!

If you like my content, please take a moment to view and vote on my Idea Requests: https://tinyurl.com/4rbpr7hf

Avatar

Community Advisor

Thanks William, this works great for my purposes, which is to add certain personnel to the People tab of a project based on a typeahead in the "company" record a project is associated with; by assigning them to a created task and then deleting it (as  per  @Doug_Den_Hoed__AtAppStore's  suggestion).

Since the assignment iterates through 3 people currently, I have to create 1 task and delete it each, and iterate thru that. If I parse after the task creation, it assignes 1 person and deletes the task so the next assignment can't find the task because it just got deleted. I'd rather it assign one then another, then another,  and THEN delete the task.

Since multiple people are being pulled from a record and parsed, I'm adding the ID field of the parsed objects to the "userIDs" section. (See pictures) When it iterates, it overwrites the previous with the current. I wonder, Is there a way to get each individual ID from a parsed object? Or a way to build an array on the fly when you don't know how many records it will pull?

userIDs.jpgParse Output.jpg

Screenshot 2023-03-15 at 5.07.23 pm.jpg

Avatar

Community Advisor

I figured out a way to do it but it's a bit messy.

Screenshot 2023-03-16 at 1.32.52 pm.jpg