Expand my Community achievements bar.

Don’t miss the Workfront AMA: System Smarts & Strategic Starts! Ask your questions about keeping Workfront running smoothly, planning enhancements, reporting, or adoption, and get practical insights from Adobe experts.

Mark Solution

This conversation has been locked due to inactivity. Please create a new post.

SOLVED

API call: Attach / assign existing custom field (parameter) to existing custom form (category)

Avatar

Level 10

Hello,

 

I want to add an existing custom field to an existing custom form using the API.

 

I know how to get all custom fields assigned to a specific form using

https://<domainname>.my.workfront.com/attask/api/v15.0/ctgy/<customFormId>?fields=categoryParameters:parameter

but I don't know how to add another one to the categoryParameters.

 

Thanks in advance.

Regards

Lars

1 Accepted Solution

Avatar

Correct answer by
Level 10

Thank to the help of the customer support, I can now share how to do this:

 

You first have to run a GET request to get all currently assigned fields / parameters:

 

https://<domain>.my.workfront.com/attask/api/v15.0/ctgy/<categoryID>?fields=categoryParameters:*

 

In the next step, you have to run a PUT call containing the previous parameters and the new one(s):

 

PUT HTTP REQUEST URL:
https://<domain>.my.workfront.com/attask/api/v15.0/ctgy/<categoryID>


JSON BODY:
{
    "categoryParameters": [
        {
            "objCode": "CTGYPA",
            "categoryID": "<categoryID>",
            "customerID": "<customerID>",
            "displayOrder": 1,
            "hideFormulaFromDescription": false,
            "isInvalidExpression": false,
            "isRequired": false,
            "parameterGroupID": "<parameterGroupID>",
            "parameterID": "<parameterID>",
            "rowShared": false,
            "securityLevel": "LE",
            "viewSecurityLevel": "V"
        },
        {
            "objCode": "CTGYPA",
            "categoryID": "<categoryID>",
            "customerID": "<customerID>",
            "displayOrder": 2,
            "hideFormulaFromDescription": false,
            "isInvalidExpression": false,
            "isRequired": false,
            "parameterGroupID": "<parameterGroupID>",
            "parameterID": "<parameterID>",
            "rowShared": false,
            "securityLevel": "LE",
            "viewSecurityLevel": "V"
        },
        { "objCode": "CTGYPA", "categoryID": "<categoryID>", "customerID": "<customerID>", "displayOrder": 3, "hideFormulaFromDescription": false, "isInvalidExpression": false, "isRequired": false, "parameterGroupID": "<parameterGroupID>", "parameterID": "<parameterID>", "rowShared": false, "securityLevel": "LE", "viewSecurityLevel": "V" }
    ]
}

View solution in original post

1 Reply

Avatar

Correct answer by
Level 10

Thank to the help of the customer support, I can now share how to do this:

 

You first have to run a GET request to get all currently assigned fields / parameters:

 

https://<domain>.my.workfront.com/attask/api/v15.0/ctgy/<categoryID>?fields=categoryParameters:*

 

In the next step, you have to run a PUT call containing the previous parameters and the new one(s):

 

PUT HTTP REQUEST URL:
https://<domain>.my.workfront.com/attask/api/v15.0/ctgy/<categoryID>


JSON BODY:
{
    "categoryParameters": [
        {
            "objCode": "CTGYPA",
            "categoryID": "<categoryID>",
            "customerID": "<customerID>",
            "displayOrder": 1,
            "hideFormulaFromDescription": false,
            "isInvalidExpression": false,
            "isRequired": false,
            "parameterGroupID": "<parameterGroupID>",
            "parameterID": "<parameterID>",
            "rowShared": false,
            "securityLevel": "LE",
            "viewSecurityLevel": "V"
        },
        {
            "objCode": "CTGYPA",
            "categoryID": "<categoryID>",
            "customerID": "<customerID>",
            "displayOrder": 2,
            "hideFormulaFromDescription": false,
            "isInvalidExpression": false,
            "isRequired": false,
            "parameterGroupID": "<parameterGroupID>",
            "parameterID": "<parameterID>",
            "rowShared": false,
            "securityLevel": "LE",
            "viewSecurityLevel": "V"
        },
        { "objCode": "CTGYPA", "categoryID": "<categoryID>", "customerID": "<customerID>", "displayOrder": 3, "hideFormulaFromDescription": false, "isInvalidExpression": false, "isRequired": false, "parameterGroupID": "<parameterGroupID>", "parameterID": "<parameterID>", "rowShared": false, "securityLevel": "LE", "viewSecurityLevel": "V" }
    ]
}