> ## Documentation Index
> Fetch the complete documentation index at: https://koreai.mintlify.app/llms.txt
> Use this file to discover all available pages before exploring further.

# Using the ServiceNow Action Templates

<Badge icon="arrow-left" color="gray">[Back to Actions Integrations](/ai-for-service/integrations/overview#actions)</Badge>

Use prebuilt ServiceNow action templates to auto-create dialog tasks for managing incidents and requests.

**To access templates:**

1. Go to **Automation AI** > **Use Cases** > **Dialogs** and click **Create a Dialog Task**.

2. Under **Integration**, select **ServiceNow**.

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img2.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=0acd5267c0433fcc7c73d25d2dd5e084" alt="Integration - Servicenow" width="899" height="913" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img2.png" />

3. If no integration is configured, click **Explore Integrations** to set one up. See [Actions Overview](/ai-for-service/integrations/overview#actions).

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img3.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=aedc24a5202265b33fcfc03d8e4faf5f" alt="Explore integrations" width="899" height="913" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img3.png" />

***

## Supported Actions

| Task               | Description                                  | Method |
| ------------------ | -------------------------------------------- | ------ |
| Create an Incident | Creates a new incident in the system.        | POST   |
| Update an Incident | Updates the incident details.                | GET    |
| List All Incidents | Retrieves all incidents from the system.     | PUT    |
| Find an Incident   | Searches all incidents that match a keyword. | GET    |
| Delete Incident    | Deletes an incident.                         | DELETE |
| Create a Request   | Creates a request in the system.             | POST   |
| Update a Request   | Updates a request in the system.             | GET    |
| List All Requests  | Retrieves all requests from the system.      | GET    |
| Find a Request     | Searches all requests that match a keyword.  | GET    |
| Delete Request     | Deletes a request.                           | DELETE |

***

### Create an Incident

1. Install the template from [ServiceNow Action Templates](/ai-for-service/integrations/actions/configuring-the-servicenow-action#step-2-install-the-servicenow-action-templates).

2. The **Create a Incident** dialog task is added with the following components:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img4.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=926299f04ebcb930e8d68b1c0c3b1f73" alt="Create an Incident dialog task" width="1522" height="915" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img4.png" />

   * **createIncident** - User intent to create an incident.

   * **createIncidentShortDescription** and **createIncidentDescription** - Entity nodes for incident details.

   * **createIncidentService** - Bot action service to create an incident. Click **Edit Request**:

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img5.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=44bbe3c113ddab8ce26f815e21dfd41d" alt="Edit request" width="1917" height="826" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img5.png" />

     **Sample Request:**

     ```json theme={null}
     {
       "short_description": "Unable to log in to my mail app",
       "description": "I see an error stating user with this mail id doesn't exist"
     }
     ```

     Click **+Add Response**:

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img6.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=e9e203b160fa55f546b14f3f5b887097" alt="Add response" width="1916" height="843" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img6.png" />

     **Sample Response:** (truncated)

     ```json theme={null}
     {
       "result": {
         "number": "INC0011182",
         "sys_id": "e0f70482478e11105474f088436d4xxx",
         "state": "1",
         "incident_state": "1",
         "short_description": "21-sept-2022",
         "sys_class_name": "incident",
         "category": "inquiry"
       }
     }
     ```

   * **setCallerService** - Bot action service to set a caller node.

   * **createIncidentMessage** - Message node to display responses.

3. Click **Train**, then **Talk to Bot** to test:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img7.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=61e273ff05b8b052747f0c598b1a738f" alt="VA prompts to create an incident" width="552" height="838" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img7.png" />

4. The new incident is created in ServiceNow:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img8.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=e7c1403ebebb625098731ec81d237bad" alt="New incident created" width="560" height="841" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img8.png" />

5. Click **View Incident** to see incident details:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img9.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=25c263bda163a149fe3ed7dbf485150a" alt="View incident details" width="1908" height="791" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img9.png" />

***

### Update an Incident

1. Install the template from [ServiceNow Action Templates](/ai-for-service/integrations/actions/configuring-the-servicenow-action#step-2-install-the-servicenow-action-templates).

2. The **Update an Incident** dialog task is added with the following components:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img10.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=ac673d05d3550b6fd37d1682763056c4" alt="Update an Incident dialog task added" width="1504" height="916" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img10.png" />

   * **Update Incident** - User intent to update an incident.

   * **SysId**, **updateRecordFields**, **updatedShortDescription**, **updatedDescription** - Entity nodes for update details.

   * **prepareUpdatePayloadScript** - Bot action script to update an incident.

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img11.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=a4b13ec8e399d23f3acaeda97b6e2262" alt="prepareUpdatePayloadScript bot action component properties" width="1917" height="797" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img11.png" />

   * **updateIncidentService** - Bot action service to update an incident.

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img12.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=c1dc792d0b31d24b009a3537712c512e" alt="updateIncidentService bot action component properties" width="1908" height="811" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img12.png" />

   * **updateIncidentMessage** - Message node to display responses.

3. Click **Train**, then **Talk to Bot** to test:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img13.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=80ac6f77fb68fd242f836c9cde0ad129" alt="VA prompts to update incident" width="548" height="828" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img13.png" />

4. Enter all incident update details when prompted. The incident is updated in ServiceNow:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img14.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=06e13156c064902e2cd35a9b380fef0a" alt="Incident updated" width="550" height="841" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img14.png" />

***

### List All Incidents

1. Install the template from [ServiceNow Action Templates](/ai-for-service/integrations/actions/configuring-the-servicenow-action#step-2-install-the-servicenow-action-templates).

2. The **List All Incidents** dialog task is added with the following components:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img15.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=8acf59a89f004e8b7ba58a198ef12676" alt="List All Incidents dialog task added" width="1551" height="889" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img15.png" />

   * **List All Incidents** - User intent to list all incidents.

   * **listAllIncidentsService** - Bot action service to fetch all incidents. Click **+Add Response**:

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img16.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=aafe34ec5d022c60535a7ada78a3c844" alt="Add response" width="1910" height="812" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img16.png" />

   * **listAllIncidentsMessage** - Message node to display responses.

3. Click **Train**, then **Talk to Bot** to test:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img17.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=4b2777f34b54c9ba8650866b1c583472" alt="VA prompt to view all incidents" width="554" height="836" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img17.png" />

***

### Find an Incident

1. Install the template from [ServiceNow Action Templates](/ai-for-service/integrations/actions/configuring-the-servicenow-action#step-2-install-the-servicenow-action-templates).

2. The **Find an Incident** dialog task is added with the following components:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img18.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=73dba7cb6edefb220576f051860b6c65" alt="Find an Incident dialog task added" width="1519" height="909" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img18.png" />

   * **Find Incident** - User intent to find an incident.

   * **findRecordFields**, **findRecordSysId**, **findRecordNumber**, **findShortDescription**, **findDescription** - Entity nodes for finding an incident.

   * **prepareSearchingFieldScript** - Bot action script to prepare search fields.

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img19.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=667faae8291fcc95077489ecfd4a3d55" alt="prepareSearchingFieldScript bot action component properties" width="1917" height="780" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img19.png" />

   * **findSearchingFieldScript** - Bot action service to search incidents.

   * **findIncidentMessage** - Message node to display responses.

3. Click **Train**, then **Talk to Bot** to test:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img20.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=784c2fdb692865ca0de4a92990a9be9e" alt="VA prompt to view an incident" width="549" height="839" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img20.png" />

***

### Delete an Incident

1. Install the template from [ServiceNow Action Templates](/ai-for-service/integrations/actions/configuring-the-servicenow-action#step-2-install-the-servicenow-action-templates).

2. The **Delete an Incident** dialog task is added with the following components:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img21.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=260dba0bbac20ffa29135839efff316a" alt="Delete an Incident dialog task added" width="1544" height="910" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img21.png" />

   * **Delete Incident** - User intent to delete an incident.
   * **SysId** - Entity node for the incident ID.
   * **deleteIncidentService** - Bot action service to delete an incident.
   * **deleteIncidentMessage** - Message node to display responses.

3. Click **Train**, then **Talk to Bot** to test:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img22.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=e1cd1d8d6cc81995c1bb83ff59a0b9b0" alt="VA prompt to delete an incident" width="558" height="847" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img22.png" />

<Note>If you enter an incorrect ID, the **404 - No Record Found** error message is displayed.</Note>

***

### Create a Request

1. Install the template from [ServiceNow Action Templates](/ai-for-service/integrations/actions/configuring-the-servicenow-action#step-2-install-the-servicenow-action-templates).

2. The **Create Request** dialog task is added with the following components:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img23.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=380050a448e21a4548cceda454231c83" alt="Create Request dialog task added" width="1548" height="906" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img23.png" />

   * **Create Request** - User intent to create a request.

   * **createRequestShortDescription** and **createRequestDescription** - Entity nodes for request details.

   * **createRequestService** - Bot action service to create a request. Click **Edit Request**:

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img24.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=486702073d80006c77fc1885563a98aa" alt="Edit Request" width="1911" height="823" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img24.png" />

     **Sample Request:**

     ```json theme={null}
     {
       "short_description": "Need a new device",
       "description": "old one not working"
     }
     ```

   * **createRequestMessage** - Message node to display responses.

3. Click **Train**, then **Talk to Bot** to test:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img25.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=c69cc7b3eabc569cf8b1cfd4a12c8a4d" alt="VA prompt to create new request" width="544" height="847" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img25.png" />

4. Click **View Request** to see request details in ServiceNow:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img26.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=d97ba99304119e5cc80f416e9f0b70b3" alt="View request" width="1898" height="808" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img26.png" />

***

### Update a Request

1. Install the template from [ServiceNow Action Templates](/ai-for-service/integrations/actions/configuring-the-servicenow-action#step-2-install-the-servicenow-action-templates).

2. The **Update a Request** dialog task is added with the following components:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img27.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=2bf23fe4696cf0b8755ab4e1139464f6" alt="Update a Request dialog task added" width="1551" height="904" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img27.png" />

   * **Update Request** - User intent to update a request.

   * **SysId**, **updateRecordFields**, **updatedShortDescription**, **updatedDescription** - Entity nodes for update details.

   * **prepareUpdatePayloadScript** - Bot action script to update a request.

   * **updateRequestService** - Bot action service to update a request.

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img28.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=7b29ea70be292f98cfb875f4f5790076" alt="updateRequestScript bot action component properties" width="1919" height="822" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img28.png" />

   * **updateRequestMessage** - Message node to display responses.

3. Click **Talk to Bot** and follow the prompts to update a request.

***

### List All Requests

1. Install the template from [ServiceNow Action Templates](/ai-for-service/integrations/actions/configuring-the-servicenow-action#step-2-install-the-servicenow-action-templates).

2. The **List All Requests** dialog task is added with the following components:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img29.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=955291a504c22313a3fa6ffd1336d2d3" alt="List All Requests dialog task added" width="1521" height="859" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img29.png" />

   * **List All Requests** - User intent to list all requests.

   * **listAllRequestsService** - Bot action service to fetch all requests.

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img30.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=8c934f1e59fde2fe1b415572b9e92a35" alt="listAllRequestService bot action component properties" width="1919" height="823" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img30.png" />

   * **listAllRequestsMessage** - Message node to display responses.

3. Click **Talk to Bot** and follow the prompts to view all requests.

***

### Find a Request

1. Install the template from [ServiceNow Action Templates](/ai-for-service/integrations/actions/configuring-the-servicenow-action#step-2-install-the-servicenow-action-templates).

2. The **Find a Request** dialog task is added with the following components:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img31.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=4ee5456a5442df93b90a48f262976446" alt="Find a Request dialog task added" width="1511" height="913" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img31.png" />

   * **Find Request** - User intent to find a request.

   * **findRecordFields**, **findRecordSysId**, **findRecordNumber**, **findShortDescription**, **findDescription** - Entity nodes for finding a request.

   * **prepareSearchingFieldScript** - Bot action script to prepare search fields.

   * **findRequestService** - Bot action service to search requests.

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img32.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=fe49140e72ebec4f4456490435d5d73b" alt="findRequestService bot action component properties" width="1914" height="818" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img32.png" />

   * **findRequestMessage** - Message node to display responses.

3. Click **Talk to Bot** and follow the prompts to find a request.

***

### Delete a Request

1. Install the template from [ServiceNow Action Templates](/ai-for-service/integrations/actions/configuring-the-servicenow-action#step-2-install-the-servicenow-action-templates).

2. The **Delete a Request** dialog task is added with the following components:

   <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img33.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=2051a25e6f1503cfcafb41f7e2356f92" alt="Delete a Request dialog task added" width="1517" height="913" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img33.png" />

   * **Delete Request** - User intent to delete a request.

   * **SysId** - Entity node for the request ID.

   * **deleteRequestService** - Bot action service to delete a request.

     <img src="https://mintcdn.com/koreai/sy5HaLmfjOFkpZKk/ai-for-service/integrations/actions/images/servicenow-tem-img34.png?fit=max&auto=format&n=sy5HaLmfjOFkpZKk&q=85&s=6633642a631337ab650c4d184f28be49" alt="deleteRequestService bot action component properties" width="1908" height="813" data-path="ai-for-service/integrations/actions/images/servicenow-tem-img34.png" />

   * **deleteRequestMessage** - Message node to display responses.

3. Click **Talk to Bot** and follow the prompts to delete a request.

<Note>If you enter an incorrect ID, the **404 - No Record Found** error message is displayed.</Note>
