ServiceNow integration - HTTP 401 unauthorized errors

Question

We are getting "HTTP 401 - Unauthorized" errors when sending signals into xMatters from ServiceNow, and new alert injections are not working. Manual POST requests using the same password work, so it's definitely an issue with the integration.

Environment

  • All versions of xMatters

  • ServiceNow integration 5.x

Answer

HTTP 401 errors between ServiceNow and xMatters are commonly caused by authentication or credential configuration issues between the two systems. Before changing the password, verify the following:

  • The integration user credentials are correct and active in both xMatters and ServiceNow, and there have been no recent password resets that were not updated everywhere the account is referenced.

  • The ServiceNow integration user has the required roles and permissions for the integration (for example, the appropriate xMatters integration roles, such as x_xma_xmatters.xmatters_rest, and standard ITSM roles like itil, if applicable).

  • The authentication method configured in ServiceNow matches what xMatters expects for that endpoint (for example, basic authentication vs. API key or OAuth, depending on your integration version and design).

  • Endpoint URLs and connection settings in both xMatters and ServiceNow are correct and point to the right instances.

  • In xMatters, check the Alert details and activity logs for the affected alert and confirm that the outbound call to ServiceNow is actually failing with HTTP 401. Look for entries such as HTTP/1.1 401 Unauthorized or ServiceNow error messages like User is not authenticated or Required to provide Auth information. These confirm that the failure is authentication-related, not a workflow logic issue.

  • In ServiceNow, open the error details (for example, in the integration logs or Flow activity) and confirm the same 401 "User Not Authenticated" response is being returned to or from xMatters. This indicates ServiceNow is rejecting the credentials being supplied.

Option 1:

Manually set the password

  1. In the Filter navigator, enter sys_properties.list.

  2. Scroll down until you find the property to update; for example, x_xma_xmatters.xmatters.reb.password.

  3. In the Value column, type the new password in plain text.

  4. Click Update to save the change. ServiceNow automatically encrypts the value.

Option 2:

Using a background script similar to the following, replace NewPassword with the password you want:

gs.setProperty('x_xma_xmatters.xmatters.reb.password', 'NewPassword');

After updating passwords and configuration, verify the integration again from both sides:

  • In xMatters, use the ServiceNow endpoint's test function (for example, in Flow Designer > Endpoints) to make sure xMatters can authenticate successfully and is no longer receiving HTTP 401 responses.

  • In ServiceNow, confirm it can still create alerts in xMatters using the service account, and that the same account is used by any outbound calls to xMatters endpoints.

  • Send a test update from xMatters back to ServiceNow (for example, by responding to a test alert) and check that:

    • The HTTP response from ServiceNow is no longer 401 Unauthorized.

    • The Flow Designer/workflow logs in xMatters show a successful response from the ServiceNow API.

    • The corresponding ServiceNow incident shows the expected field updates (such as state changes, assignee updates, or other integration-specific fields).

Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Article is closed for comments.