Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Not able to create Work Order task using Rest API

nikhilagarw
Tera Contributor

I have created the Work Order in my PDI using Rest API, while trying to create tasks in my workorder, using below request, I am getting error.  It shows "Parent is mandatory" though I have parent tag in the request.

Request:

{
    "parent": {
        "value": "15b5254d93f20210675e3d5efaba10c0",
         "number": "WO0010015"
    },
    "short_description": "wm task insert test",
    "work_type": "Leak Repair"
}
 
Response:
{
    "error": {
        "message": "Operation Failed",
        "detail": "Data Policy Exception: \n\tThe following fields are mandatory: Parent"
    },
    "status": "failure"
 

 

1 REPLY 1

MihirV
Tera Contributor

Hi, Were you able to resolve this issue ? If yes what was resolution ?