add_Attachment
Related Concepts: Case Manipulation
This function adds an entry to the case wall with a file attachment (that can
be then downloaded from the client into the user’s local machine). The
function does essentially the same thing as adding evidence (on the bottom of
the case overview screen).
NOTE: To be able to upload a file to the case
wall, you need to have the file available in the file system of the Siemplify
server, or have it on a shared location accessible from the Siemplify server.
Here’s a usage example:
from SiemplifyAction import SiemplifyAction
siemplify = SiemplifyAction()
siemplify.add_attachment(r'C:/temp/investigation.txt', description='Deep investigation report b
y
TIER3 team', is_favorite=True)
In this example, we will upload the “investigation.txt” from “C:/temp” on the local machine (the Siemplify server itself) to the case wall. A comment will be added to that entry on the case wall, with the string in the description. The “is_favorite” flag was set to “True”, and so this new entry will also be starred (favorite).
Param Name | Param Type | Possible Values | Comments | Mandatory Parameter |
---|---|---|---|---|
file_path | string | Any accessible file path | File path could be a remote location as well. You need read permissions to that file | Yes |
case_id | string | A case ID to add the attachment to its case wall | The default is the current case | Yes |
alert_identifier | string | Alert identifier string of the alert you want to associate the attachment with | The default is the current running alert | No |
description | string | Any string | Default is empty string – Empty message with the attachment on the case wall | No |
is_favorite | Boolean | True/False | Default is False | No |