Configure the ServiceNow MCP Server
Connect ServiceNow's MCP Server Console to a Dtwo gateway via OAuth.
On this page
Overview
ServiceNow offers a remote MCP server, hosted on your own instance. AI agents can look up and update incidents, search knowledge articles, and summarize cases. Users connect through OAuth and use their own ServiceNow permissions.
Prerequisites
- Check that MCP Server Console shows up in the All menu in ServiceNow. If it doesn’t, an admin needs to install the Model Context Protocol Server app from All → System Applications → All Available Applications → All. The app requires a Now Assist license.
- You need the
sn_mcp_server.adminoradminrole to create the server and the OAuth client.
1. Create the MCP server
-
Go to All → MCP Server Console (or Admin → MCP Server Console), open the Configuration tab, select Servers, and click Create server. Enter a Label and a Short description. ServiceNow generates the server’s Name from the label, and that name becomes part of the MCP endpoint URL. You can also use ServiceNow’s preconfigured Quickstart Server instead of creating one from scratch.
-
In the Tools section, click Add tools, select the tools the server should expose, and click Add. Tools must be in the same application scope as the server. When you’re done, click Create to save and activate the server.
If the tool you need isn’t in the list, you can build your own with Create tool. A custom tool can wrap a REST API, a Flow Designer action or subflow, a Knowledge Graph query, or a Now Assist skill.
-
Copy the endpoint from the server record’s Server URL field. It follows the pattern
https://<SERVICENOW_INSTANCE>.service-now.com/sncapps/mcp-server/mcp/<SERVER_NAME>. For the Quickstart Server, the server name issn_mcp_server_default.
2. Create the OAuth app
-
In MCP Server Console, go to Servers and select Client authorization in the left navigation.
-
Click Create integration and give it a name (for example,
Dtwo). -
Enter your Dtwo gateway’s OAuth callback URL as the redirect URL, and click Create. To get it, open your gateway in the Dtwo UI, go to the Overview tab, and copy the Callback URL.
-
Select the integration you just created to open its summary. Keep it open, and in another tab go to Vault in the Dtwo UI. Add two entries, selecting Add entry for each one. Set Used by to the gateway you’re connecting ServiceNow to, or to All gateways if you plan to connect more than one gateway to ServiceNow:
- Client ID:
- Name:
SERVICE_NOW_CLIENT_ID - Value: paste the Client ID from the ServiceNow summary
- Name:
- Client secret:
- Name:
SERVICE_NOW_CLIENT_SECRET - Value: paste the Client Secret from the ServiceNow summary
- Turn on Encrypted value.
- Name:
ServiceNow only shows the secret in this summary, so add both entries before you close it.
- Client ID:
3. Add the MCP server to your gateway config
Go to your gateway in the Dtwo UI and open Configuration → Advanced. In the mcp_servers section add the following entry:
- name: servicenow
description: "ServiceNow MCP server."
url: "https://<SERVICENOW_INSTANCE>.service-now.com/sncapps/mcp-server/mcp/<SERVER_NAME>"
transport_type: streamablehttp
authentication:
type: oauth
grant_type: authorization_code
issuer: "https://<SERVICENOW_INSTANCE>.service-now.com"
scopes:
- mcp_server
client_id: <<SERVICE_NOW_CLIENT_ID>>
client_secret: <<SERVICE_NOW_CLIENT_SECRET>>
authorization_url: "https://<SERVICENOW_INSTANCE>.service-now.com/oauth_auth.do"
token_url: "https://<SERVICENOW_INSTANCE>.service-now.com/oauth_token.do"
redirect_uri: "<CALLBACK_URL>"
pkce_enabled: true
Replace the placeholder values:
<SERVICENOW_INSTANCE>— your ServiceNow instance name.<SERVER_NAME>— the server’s name, the last part of the Server URL you copied in step 1 (sn_mcp_server_defaultfor the Quickstart Server).<CALLBACK_URL>— your Dtwo gateway’s OAuth callback URL, found in the Overview tab for your gateway in the Dtwo UI.
4. Deploy and verify
Save the configuration and deploy the gateway.
Then, in your AI client, ask it to authorize ServiceNow via the gateway. This opens the ServiceNow login screen — sign in as the user whose permissions the agent should inherit, and approve the consent prompt. Once authorized, confirm the server’s tools appear and run a quick read-only call with one of the tools you added to make sure the connection works.
If the tools don’t appear after you authorize, refresh the tool list in your AI client — some clients don’t pick it up automatically.
If authorization works but the tools still don’t load, or tool calls fail with a 403, open the integration in All → Machine Identity Console → Inbound integrations. Make sure Allow access only to APIs in selected scope is cleared and that Token Format (under Advanced options) is set to JWT.
Tool calls run with the signed-in user’s ServiceNow roles and access controls, so if a single tool returns a 403, that user probably doesn’t have the roles that tool needs.