Create incident from scheduled report job

snuser10
Kilo Expert

Is there a way to create an incident ticket when report is scheduled to run? Meaning can the same scheduled job open an incident ticket with that report as an attachment? TIA!!

11 REPLIES 11

johnfeist
Mega Sage
Mega Sage

I'm not sure that you can export a report onto your instance.  I do have an alternative for you.  Have your job send the report back to your instance either directly or via a mailbox that auto forwards to your instance.  Then you can have your inbound actions pick it up and handle it like anything else coming in.

Hope that helps.

:{)

Helpful and Correct tags are appreciated and help others to find information faster

Hope that helps.

:{)

Helpful and Correct tags are appreciated and help others to find information faster

amaradiswamy
Kilo Sage

Hi,

Yes, we can use "Conditional" field in Scheduled reports which supports server side script. I tested in my developer instance and it is working

find_real_file.png

Hello! This works except it does NOT attach the report as an attachment. i tried adding "GlideSysAttachment.copy(current.getTableName(), current.getValue('sys_id'), 'incident', incidentSysId);" after gr.insert(); with no luck.  Any suggestion?

gr.insert() and gr.update() and gs.info() These commands are not at all working for me in conditional script 

I donno how you guys achieved this. Please help me