Attaching a new Templates to an existing Project using API calls | Community
Skip to main content
September 1, 2022
Question

Attaching a new Templates to an existing Project using API calls

  • September 1, 2022
  • 2 replies
  • 895 views

I can't find any doc about this subject that could bring me a solution, then here I'm:

 

I already created many projects using API calls, via Snaplogic and even updated them in the same way, but what doesn't work is the action attachTemplate as below:

this was supposed to add a new Template to a existing project, but when I use PUT passing the update parameters it returns error code 422. 

2 replies

Jason_JB
Level 5
September 2, 2022

We're doing this via Fusion, but I think the same approach applies.  We're using "assignCategories".

 

Just a heads up, I remember we originally wrote this with a different call and it removed existing templates from the projects.

 

 

 

lgaertner
Level 9
July 1, 2024

Hi,

 

I just tried to do it using a PUT call and it worked:

https://example.my.workfront.com/attask/api-internal/PROJ/attachTemplate?method=PUT&action=attachTemplate&ID=<projectID>


using the following payload:

{ "templateID": "<templateID>", "predecessorTaskID": "<predecessorTaskID>", "parentTaskID": '', "excludeTemplateTaskIDs": [ "<excludeTemplateTaskID>" ], "options": [] }

 

Regards

Lars

_Manish_Singh
Level 9
September 17, 2025

Hello @lgaertner, do you know what I should enter in "options" in the payload if I only need to select 'Queue Properties & Issue Setup'? (see image below)