microsoft / msticpy

Microsoft Threat Intelligence Security Tools
Other
1.72k stars 310 forks source link

Pass `true` for props into `_build_sent_data` when calling `update_incident` #774

Closed kylelol closed 1 month ago

kylelol commented 2 months ago

This PR updates the update_incident function to pass true for the props parameter of _build_sent_data.

This helps us solve the use case of being able to pass in an object like {'labels': [{'labelName': 'test', 'labelType': 'User'}]} when calling update_incident .

This should allow labels to be passed in according to the documentation here: https://learn.microsoft.com/en-us/rest/api/securityinsights/incidents/create-or-update?view=rest-securityinsights-2024-03-01&tabs=HTTP

We have tried doing something like update_incident(incident_id='xxx', update_items={'severity': 'xxx', 'properties.labels': [{'labelName': 'test", 'labelType': 'User'}]) with no luck

glwallum commented 2 months ago

Requesting approval

ianhelle commented 1 month ago

@kylelol - apologies for the delay in getting this merged.