> For the complete documentation index, see [llms.txt](https://docs.autommate.com/userguide/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.autommate.com/userguide/start-here/use-cases/servicenow-agent-example.md).

# ServiceNow AI Agent example

Give users conversational access to incidents and knowledge while keeping ServiceNow as the system of record. The agent interprets the request; configured Autom Mate skills perform the ServiceNow operations.

## Scope the first version

The documented ServiceNow template covers incident retrieval, resolved-incident lookup, incident creation, adding notes, knowledge search and service-catalog discovery. Inspect the template's installed skills before enabling it. Discovering a catalog item does not by itself submit that item's fulfilment form or complete its approvals.

| User request                             | Configure and verify                                                       |
| ---------------------------------------- | -------------------------------------------------------------------------- |
| “What is happening with incident INC…?”  | Retrieve the incident and return its current state from ServiceNow.        |
| “Do we have guidance for this issue?”    | Search the configured knowledge source and return relevant articles.       |
| “Create an incident for my VPN problem.” | Collect required incident fields, create the record and return its number. |
| “Add this information to my incident.”   | Validate the target record and permitted note field before updating it.    |
| “Which service should I request?”        | Retrieve relevant catalog information and offer the available choices.     |

## Prepare the connection

You need AI Agent Composer access, the ServiceNow instance URL, an appropriate model configuration and a ServiceNow credential stored in [Vault](/userguide/integrations-and-api/manage-app-and-custom-credentials.md). The integration documentation describes Basic Authentication and OAuth; choose the method supported by your instance and installed connector.

The source template references the `incident` table for create/read/update and `kb_knowledge` for knowledge reads. Catalog operations also require access to the relevant catalog resources. Match permissions to the actual actions: ServiceNow roles, ACLs and catalog structures determine the records the integration account can use. Do not grant broad access merely to make a test pass. See the [ServiceNow integration reference](/userguide/integrations-and-api/libraries/integration/servicenow.md).

## Configure the agent

1. Open [AI Agent Composer](/userguide/ai-agent-composer/configure-an-agent-in-ai-agent-composer.md) and create or import the available ServiceNow template.
2. Select the model configuration and the ServiceNow credential. Check the instance URL before testing a write.
3. Inspect the [skills](/userguide/ai-agent-composer/configure-agent-skills.md): names, descriptions, input fields and the Hyperflows each one calls. Remove operations outside the initial scope.
4. In **Knowledge → Applications**, select **ServiceNow** and configure the required knowledge source. Follow [knowledge setup](/userguide/ai-agent-composer/add-knowledge-to-an-agent.md).
5. Test in the [Playground](/userguide/ai-agent-composer/test-in-playground-and-review-logs.md) before connecting a user-facing channel. Mate Chat, Teams and WhatsApp are the documented channel options; configure the option enabled for your environment.
6. For Teams, complete [Connect an AI Agent to Teams](/userguide/ai-agent-composer/choose-and-connect-an-agent-channel/teams-ai-agent-channel.md).

## Acceptance checks

Test one permitted record, one inaccessible record, missing incident details, an ambiguous incident reference and an upstream error. Confirm that the reply uses the returned incident number and status. For notes, verify the text in ServiceNow and distinguish internal work notes from user-visible comments according to your action mapping.

If users should see only their own incidents, implement and test identity-to-ServiceNow-user mapping and filtering. A shared integration credential does not automatically enforce that rule.

## Extend after the basic journey works

Additional Hyperflows can handle diagnostics, identity tasks or cross-system remediation. Define each extension's permissions and success result separately. Keep approvals and fulfilment behaviour explicit rather than inferring them from a successful incident creation.
