REST HTTP Method Illegal Access in Scoped Application

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-01-2016 05:38 AM
Hi all,
I have an issue with custom scoped application.
When I send a REST outbound message from a Async business rule, things are good and messages are sent from ServiceNow and received at third party. Same when run from after insert/update business rule - I receive the below error.
Illegal access to outbound HTTP in Telegram Autobot. Use an async business rule to perform outbound HTTP requests.
Table , Business Rule on the table (Where REST Outbound message is sent) and REST Message record - are all on same application scope.
Any idea whats the issue here? If it works on ASYNC why not on after insert / update?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-02-2016 03:29 AM
Hi Elango,
Did u get any resolution for this.? Even i have a requirement where i am running a after insert business rule and using rest message in that.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-02-2016 03:42 AM
Nope.
Am using an ASYNC Business rule as of now and of course response is a bit slower when compared to after insert / update.
I will keep you posted if I find a resolution for the same. You could also update the thread if you find a work around.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-22-2020 07:43 AM
Adding following code in my after BR worked for me:
var response = r.executeAsync();
response.waitForResponse(10);