Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[8.x] [ResponseOps][Cases] Add additional fields to ServiceNow cases integration (#201948) #205385

Merged
merged 1 commit into from
Jan 2, 2025

Conversation

kibanamachine
Copy link
Contributor

Backport

This will backport the following commits from main to 8.x:

Questions ?

Please refer to the Backport tool documentation

…ation (elastic#201948)

Closes elastic/enhancements#22091

## Summary

The ServiceNow ITSM and SecOps connector for cases now supports the
`Additional fields` JSON field. This is an object where the keys
correspond to the internal names of the table columns in ServiceNow.

## How to test

1. Cases with an existing ServiceNow connector configuration should not
break.
2. The additional fields' validation works as expected.
3. Adding additional fields to the ServiceNow connector works as
expected and these fields are sent to ServiceNow.

Testing can be tricky because ServiceNow ignores additional fields where
the key is not known or the value is not accepted. You need to make sure
the key matches an existing column and that the value is allowed **on
ServiceNow**.

### SecOps

The original issue concerned the fields `Configuration item`, `Affected
user`, and `Location` so these must work.

An example request **for SecOps** with these fields' keys is the
following:

```
{
  "u_cmdb_ci": "*ANNIE-IBM",
  "u_location": "815 E Street, San Diego,CA",
  "u_affected_user": "Antonio Coelho"
}
```

This should result in:

<img width="901" alt="Screenshot 2024-11-27 at 12 52 37"
src="https://github.com/user-attachments/assets/6734a50b-b413-4587-b5e2-2caf2e30ad67">

**The tricky part here is that they should be the names of existing
resources in ServiceNow so the values cannot be arbitrary.**

### ITSM

ITSM fields are different than the ones in SecOps. An example object is:

```
{
  "u_assignment_group": "Database"
}
```

This results in:

<img width="1378" alt="Screenshot 2024-11-27 at 13 46 56"
src="https://github.com/user-attachments/assets/8064f882-2ab5-4fd6-b123-90938ab3bb83">

## Release Notes

Pass any field to ServiceNow using the ServiceNow SecOps connector with
a JSON field called "additional fields".

---------

Co-authored-by: kibanamachine <[email protected]>
(cherry picked from commit d209afd)
@kibanamachine kibanamachine merged commit 3e26821 into elastic:8.x Jan 2, 2025
11 checks passed
@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
cases 838 840 +2

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
cases 533.0KB 539.8KB +6.8KB

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
cases 161.7KB 162.1KB +418.0B
Unknown metric groups

ESLint disabled line counts

id before after diff
cases 62 63 +1

Total ESLint disabled count

id before after diff
cases 80 81 +1

cc @adcoelho

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants