Query ServiceNow records from Slack

BotsArtificial IntelligenceCustomer ServiceIT Service ManagementRecipe Tools

What it does

When someone runs the ServiceNow select category command in Slack, this automation searches the sc_category table in ServiceNow. It then searches the sc_cat_item table and posts a dialog back to Slack so someone can pick a category and item.

Who it's for

IT teams who need to find ServiceNow records from Slack without leaving the conversation.

How teams use this

Find a ServiceNow category from Slack

Run the command to search sc_category records and pick one without opening ServiceNow. The dialog appears in the same thread so the team stays in context.

Let service desk staff search items

Invite the bot to a service desk channel so staff can find sc_cat_item records during a ticket conversation. The flow works the same way in a different channel.

Filter categories by a condition

Add a filter to the sc_category search so only active categories appear in the dialog. This requires a condition on the first ServiceNow search step.

How it works

  1. Run the ServiceNow select category command. Type the ServiceNow select category command in a Slack channel or direct message to start a search.
  2. Search the sc_category table. Query ServiceNow for records in the sc_category table that match the request so categories are available to choose from.
  3. Search the sc_cat_item table. Query ServiceNow for records in the sc_cat_item table to find items that belong to the selected category.
  4. Post a dialog to Slack. Display a dialog in Slack with the categories and items so someone can select the one they need from the conversation.