Alert description, node, source, resource fields are not getting set via table api
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-06-2024 02:50 PM
Hi All,
I just started playing with REST API on development instance and I found that when I'm creating new alert using client. Alert is getting created successfully but noticed that some of the important fields like description, node, source, resource are populating as empty.
What roles I should assign to my client to be able to populate mentioned fields assuming that client don't want to use admin?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-07-2024 06:27 PM
Hi, unfortunately your post contains no clear details of your configuration or payloads.
Did you pass valid\correct values in your payloads for these fields?
Or are you using a scripted rest api to evaluate and populate these values?
Normally I would expect REST type functionality without addition of specific roles, but you can check\test simply by applying roles that match the target tables ACL write requirement to the integration user account.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-07-2024 08:42 PM
Hi @Tony Chatfield1,
Thanks for the response. Here is the POST call that I am trying out:
Endpoint: <serviceNowUrl>/api/now/table/em_alert
Body:
{
"description": "This is a test alert created via API",
"node": "Server1",
"source": "MonitoringTool",
"resource": "Resource_1",
"state": "Open",
"severity": "3"
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-14-2025 02:35 PM
Did you get this resolved? I am experiencing the same issue. I'm using the Rest API explorer and when I test a post on the Alert table, the alert itself gets created, but none of the fields are being populated. I gave myself admin rights but still no success.