-
Notifications
You must be signed in to change notification settings - Fork 0
/
example-incident-summary-workflow.json
1 lines (1 loc) · 8.53 KB
/
example-incident-summary-workflow.json
1
{"workflow":{"title":"Example incident summary workflow","description":"Initiate the incident process and assemble the team","icon":"","input_parameters":{"Ft07C5S5AB37__channel_id":{"type":"slack#/types/channel_id","name":"Ft07C5S5AB37__channel_id","description":"Channel where the workflow was used, if available","title":"Channel where the workflow was used"},"Ft07C5S5AB37__event_timestamp":{"type":"slack#/types/timestamp","name":"Ft07C5S5AB37__event_timestamp","description":"Time when workflow started","title":"Time when workflow started"},"Ft07C5S5AB37__user_id":{"type":"slack#/types/user_id","name":"Ft07C5S5AB37__user_id","description":"Person who used this workflow","title":"Person who used this workflow"},"Ft07C5S5AB37__interactivity":{"type":"slack#/types/interactivity","name":"Ft07C5S5AB37__interactivity","description":"Interactivity context","title":"Interactivity context","is_hidden":true}},"steps":[{"id":"ed7b2fd0-6d03-4eb2-b070-12d33b0df7cd","function_id":"Fn010N","inputs":{"title":{"hidden":false,"locked":false,"value":"Start an incident"},"fields":{"hidden":false,"locked":false,"value":{"elements":[{"long":true,"name":"8e494fc2-2cd4-4dbf-8fe4-9b2bdc8676aa","type":"string","title":"Describe the issue ...","description":"Submitting this form will trigger an incident!"},{"enum":["High","Medium","Low"],"name":"ad7761da-25d3-4541-9a71-d2b9573f8ee9","type":"string","title":"Severity","choices":[{"title":"High","value":"High","description":"High"},{"title":"Medium","value":"Medium","description":"Medium"},{"title":"Low","value":"Low","description":"Low"}],"default":"","description":""}],"required":["8e494fc2-2cd4-4dbf-8fe4-9b2bdc8676aa","ad7761da-25d3-4541-9a71-d2b9573f8ee9"]}},"interactivity":{"hidden":false,"locked":false,"value":"{{inputs.Ft07C5S5AB37__interactivity}}"}}},{"id":"9edf8240-c72d-4703-8277-7140ffdb2b2a","function_id":"Fn0102","inputs":{"message":{"hidden":false,"locked":false,"value":[{"type":"rich_text","elements":[{"type":"rich_text_section","elements":[{"name":"warning","type":"emoji","style":{"bold":true},"unicode":"26a0-fe0f"},{"text":" New incident","type":"text","style":{"bold":true}},{"text":"\n\n","type":"text"},{"id":"{{steps.ed7b2fd0-6d03-4eb2-b070-12d33b0df7cd.fields.8e494fc2-2cd4-4dbf-8fe4-9b2bdc8676aa}}","type":"workflowtoken","style":{"italic":true},"property":"","data_type":"string"},{"text":"\n\n","type":"text"},{"text":"Status","type":"text","style":{"bold":true}},{"text":": ","type":"text"},{"text":"Open","type":"text","style":{"code":true}},{"text":"\n","type":"text"},{"text":"Severity","type":"text","style":{"bold":true}},{"text":": ","type":"text"},{"id":"{{steps.ed7b2fd0-6d03-4eb2-b070-12d33b0df7cd.fields.ad7761da-25d3-4541-9a71-d2b9573f8ee9}}","type":"workflowtoken","style":{"code":true},"property":"","data_type":"string"},{"text":"\n","type":"text"},{"text":"Start Time","type":"text","style":{"bold":true}},{"text":": ","type":"text"},{"id":"{time.format(seconds={{inputs.Ft07C5S5AB37__event_timestamp}}, locale=en-US, dateType=DATE_MEDIUM_TIME_MEDIUM)}","type":"workflowtoken","style":{"code":true},"property":"","data_type":"string"},{"text":"\n\n","type":"text"},{"name":"person_frowning","type":"emoji","unicode":"1f64d"},{"text":" ","type":"text"},{"id":"{{inputs.Ft07C5S5AB37__user_id}}","type":"workflowtoken","property":"","data_type":"slack#/types/user_id"},{"text":"\n\n","type":"text"},{"text":"Use the thread to resolve this issue ...","type":"text","style":{"italic":true}}]}]}]},"channel_id":{"hidden":false,"locked":false,"value":"{{inputs.Ft07C5S5AB37__channel_id}}"},"interactive_blocks":{"hidden":false,"locked":false,"value":[{"type":"actions","elements":[{"text":{"text":"Resolve incident","type":"plain_text","emoji":true},"type":"button","style":"primary","value":"button","action_id":"0ad65d62-74c4-4f26-93af-07dfb1741e11"}]}]}}},{"id":"d0bda78d-8079-452e-a3c0-c00fcda08aca","function_id":"Fn010P","inputs":{"message":{"hidden":false,"locked":false,"value":[{"type":"rich_text","elements":[{"type":"rich_text_section","elements":[{"name":"large_green_circle","type":"emoji","unicode":"1f7e2"},{"text":" Incident was marked as resolved by ","type":"text"},{"id":"{{steps.9edf8240-c72d-4703-8277-7140ffdb2b2a.interactivity.interactor.id}}","type":"workflowtoken","property":"","data_type":"slack#/types/user_id"},{"text":" at ","type":"text"},{"id":"{time.format(seconds={{steps.9edf8240-c72d-4703-8277-7140ffdb2b2a.action.action_ts}}, locale=en-US, dateType=DATE_MEDIUM_TIME_MEDIUM)}","type":"workflowtoken","property":"","data_type":"string"}]}]}]},"message_context":{"hidden":false,"locked":false,"value":"{{steps.9edf8240-c72d-4703-8277-7140ffdb2b2a.message_context}}"},"reply_broadcast":{"hidden":false,"locked":false,"value":"true"}}},{"id":"8da7bb6e-e84b-49e9-9619-264c7dcfd1a9","function_id":"Fn011G","inputs":{"title":{"hidden":false,"locked":false,"value":"Incident summary: {time.format(seconds={{inputs.Ft07C5S5AB37__event_timestamp}}, timezone=America/New_York, format='Y-m-d')}"},"content":{"hidden":false,"locked":false,"value":[{"type":"expanded_rich_text","elements":[{"type":"rich_text_header","level":2,"elements":[{"text":"Incident Summary","type":"text"}]},{"type":"rich_text_section","elements":[{"text":"\n","type":"text"},{"text":"Incident Date:","type":"text","style":{"bold":true}},{"text":" ","type":"text"},{"id":"{time.format(seconds={{inputs.Ft07C5S5AB37__event_timestamp}}, timezone=America/New_York, locale=en-US, dateType=DATE_LONG)}","type":"workflowtoken","property":"","data_type":"string"},{"text":"\n","type":"text"},{"text":"Reported by:","type":"text","style":{"bold":true}},{"text":" ","type":"text"},{"id":"{{inputs.Ft07C5S5AB37__user_id}}","type":"workflowtoken","property":"","data_type":"slack#/types/user_id"},{"text":"\n","type":"text"},{"text":"Severity level:","type":"text","style":{"bold":true}},{"text":" ","type":"text"},{"id":"{{steps.ed7b2fd0-6d03-4eb2-b070-12d33b0df7cd.fields.ad7761da-25d3-4541-9a71-d2b9573f8ee9}}","type":"workflowtoken","property":"","data_type":"string"},{"text":"\n","type":"text"},{"text":"Incident channel:","type":"text","style":{"bold":true}},{"text":" ","type":"text"},{"id":"{slack.channel_mention_id(channel_id={{inputs.Ft07C5S5AB37__channel_id}})}","type":"workflowtoken","property":"","data_type":"string"},{"text":"\n","type":"text"},{"text":"Status:","type":"text","style":{"bold":true}},{"text":" ","type":"text"},{"text":"Closed","type":"text","style":{"code":true}},{"text":"\n\n","type":"text"}]},{"type":"rich_text_header","level":2,"elements":[{"text":"Incident Description","type":"text"}]},{"type":"rich_text_section","elements":[{"text":"<summary output variable>\n\n","type":"text"}]},{"type":"rich_text_header","level":2,"elements":[{"text":"Root Cause Analysis","type":"text"}]},{"type":"rich_text_section","elements":[{"text":"Cause:","type":"text","style":{"bold":true}},{"text":" <cause output variable>\n","type":"text"},{"text":"Impact:","type":"text","style":{"bold":true}},{"text":" <impact output variable>\n","type":"text"},{"text":"Resolution:","type":"text","style":{"bold":true}},{"text":" <resolution output variable>\n\n","type":"text"}]},{"type":"rich_text_header","level":2,"elements":[{"text":"Timeline","type":"text","style":{"bold":true}}]},{"type":"rich_text_section","elements":[{"text":"<duration output variable>\n<summary output variable>\n\n","type":"text"}]},{"type":"rich_text_header","level":2,"elements":[{"text":"Notes","type":"text","style":{"bold":true}}]},{"type":"rich_text_section","elements":[{"text":"Type something ...","type":"text","style":{"italic":true}}]}]}]},"owner_id":{"hidden":false,"locked":false,"value":"{{steps.9edf8240-c72d-4703-8277-7140ffdb2b2a.interactivity.interactor.id}}"},"canvas_create_type":{"hidden":false,"locked":false,"value":"blank"}}},{"id":"eaef70a3-9e1e-4fbc-827e-a7acff7ee62d","function_id":"Fn011Y","inputs":{"canvas_id":{"hidden":false,"locked":false,"value":"{{steps.8da7bb6e-e84b-49e9-9619-264c7dcfd1a9.canvas_id}}"},"access_level":{"hidden":false,"locked":false,"value":"view"},"message_context":{"hidden":false,"locked":false,"value":"{{steps.9edf8240-c72d-4703-8277-7140ffdb2b2a.message_context}}"},"reply_broadcast":{"hidden":false,"locked":false,"value":"false"}}}]},"triggers":[{"name":"Example incident workflow","type":"shortcut","inputs":{"Ft07C5S5AB37__user_id":{"value":"{{data.user_id}}","locked":false,"hidden":false},"Ft07C5S5AB37__channel_id":{"value":"{{data.channel_id}}","locked":false,"hidden":false},"Ft07C5S5AB37__interactivity":{"value":"{{data.interactivity}}","locked":false,"hidden":false},"Ft07C5S5AB37__event_timestamp":{"value":"{{event_timestamp}}","locked":false,"hidden":false}},"shortcut":{"schema":{}}}]}