error 'Missing required field: 'owner' when uploading / creating incident via json

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements

error 'Missing required field: 'owner' when uploading / creating incident via json

L2 Linker

Trying to export a ticket from PROD into DEV.


To test I exported a ticket in DEV as a json using this in the playground.

!azure-sentinel-get-incident-by-id incident_id="c5dc30e5-6981-4cb0-9895-66967fc3f2e9" raw-response="true"
(saved as json)

 

Then n DEV, i tried importing the json per the following instructions:

https://docs.paloaltonetworks.com/cortex/cortex-xsoar/6-6/cortex-xsoar-admin/incidents/incident-mana...

 

It fails and I get this error:

error 'Missing required field: 'owner'

 

Without any modification the exported json had:

"owner": {
"assignedTo": "Joshua Boyd",
"email": "soc@email.com",
"objectId": null,
"userPrincipalName": null
},

 

 

I tried modifying the json to the following, but both imports were unsuccessful:

"owner": {
"owner":"jboyd@x.onmicrosoft.com",
"assignedTo": "Joshua Boyd",
"email": "soc@email.com",
"objectId": null,
"userPrincipalName": null
},

 

Does anyone have an example of one that works.  I don't understand why I can export to json in DEV and then import to DEV; i choose the correct mapping and automapped my fields.  Looks correct...

Thanks again,

 

Boyd

1 accepted solution

Accepted Solutions

L3 Networker

Also, adding a note to the above response - The JSON you are attempting to use is the result of a command execution, not the structure the mapper is expecting. To easily obtain the JSON representation of an incident, you can use this URL https://hostname/incident/load/<incident_id>  for ex. https://hostname/incident/load/100.

 

Copy the json into a file, upload it into the mapper, map the fields and then create the incident.

View solution in original post

10 REPLIES 10

L2 Linker

The issue is you have "owner": {

...

}

it should be like this: 
{
"owner":"jboyd@x.onmicrosoft.com",
"assignedTo": "Joshua Boyd",
"email": "soc@email.com",
"objectId": null,
"userPrincipalName": null
}

L3 Networker

Also, adding a note to the above response - The JSON you are attempting to use is the result of a command execution, not the structure the mapper is expecting. To easily obtain the JSON representation of an incident, you can use this URL https://hostname/incident/load/<incident_id>  for ex. https://hostname/incident/load/100.

 

Copy the json into a file, upload it into the mapper, map the fields and then create the incident.

L2 Linker

Sorry my mappings have it under properties.owner.owner

 

jboyd98_0-1649100298789.png

jboyd98_1-1649100371672.png

 




L2 Linker

Thank you both, got it!

L3 Networker

Awesome! Let us know if you need more help🙂

 https://hostname/incident/load/<incident_id>

 

Actually that didn't work for me; just confirming is that the correct syntax?

L3 Networker

Yup, it's this format - https://hostname/incident/load/100  where 100 is the incident id. Make sure to remove the pound sign from the url. 

@RahulVijaydev 

Trying to get this to work, any advice.  Screenshot above, this command doesn't seem to be working, but it would make my life much easier if would work 🙂

 https://hostname/incident/load/<incident_id> 

Once I have that, should i be able to import using the upload json option to create the incident without any subsequent mapping?

Are you on a multi-tenant instance? I can see *acc* in the URL. If so, the URL should be of this format https://xxx/acc_name/incident/load/<incident_id>

  • 1 accepted solution
  • 5278 Views
  • 10 replies
  • 0 Likes
Like what you see?

Show your appreciation!

Click Like if a post is helpful to you or if you just want to show your support.

Click Accept as Solution to acknowledge that the answer to your question has been provided.

The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!

These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!

The LIVEcommunity thanks you for your participation!