Free, Simple URL Shortener for ServiceNow Nerds (snc.guru)

đŸ› ïžThat’s right folks, it's yet another FREE ServiceNow tool on SN Pro Tips!🔧

This one is a URL Shortener that uses the fancy-fun-fresh "snc.guru" domain, so you can look like a really heckin' hoopy frood when you share a link to your blog post, a resource you found, etc.

Create short, memorable, easy quick-links with the easy-to-remember pattern: go.snc.guru/your_thing
Start creating your own custom ServiceNow-ey short-URLs with snc.guru with just a few clicks. Head over to short.snc.guru, or click “Read more” to use what might be the world’s simplest URL shortener!

Read more

How to Get and Parse ServiceNow Journal Entries as Strings/HTML

I come across this question all the time in the ServiceNow community forums, and in the ServiceNow developer community Discord, Slack, and Telegram groups.

“How do I get the last N journal entries from a record in ServiceNow, in a script?”
“How do I print the last N journal entries in my notification email or mail script in ServiceNow?”
“How do I parse journal entries for HTML so special characters and line-breaks will show up properly in HTML or an email?”

I’ve helped people create so many one-off solutions to these questions that it felt more efficient to, finally, just create a single function that can do it all!

Click below to be taken to the article, and get the free tool that you can add your instance!

Read more

New tool: Get Latest Version of ServiceNow Docs Page

Imagine you’re searching for an issue you’re researching in ServiceNow, and the first result you find on Google is a ServiceNow documentation page
 from the Jakarta version of ServiceNow. It’s totally out of date.

How do you make sure that you’re getting the latest version of this same page in the documentation?
And what if you want to share the link to the latest version of that doc with someone else?
What if, for example, you’re posting to the community forums and you want to make sure that the link you post will always go to the latest version of that doc, even if someone sees the link years later?

With this extension (or bookmarklet script), you can be on any ServiceNow Docs page and simply click one button to (1) have the URL of the latest version of that article copied to your clipboard, and (2) be redirected to the latest version of that page.
The best thing about that generated link is that even if you were to navigate to it again years later, it would still take you to the latest version of that page, even if the “latest version” is newer than the version that was the latest when you generated the link!

Read more

How to Set or Change ServiceNow Application's Repository URL, Credentials, or SSH Key

Unfortunately, ServiceNow has made the interesting (see: baffling) decision to make it confoundingly difficult to figure out how to change the Git repo your application is associated with, once it’s been linked to one. I can’t fathom why they might’ve done this, but that is unfortunately not an unusual sentiment when it comes to ServiceNow.

Knowing that I’m liable to let this article devolve into a 10-page ranting, rambling manifesto lamenting the unnecessarily opaque and undocumented process for doing basic things like changing the repo your application is associated with, let’s instead get straight on in to how to do it anyway.

Generating an SSH Key

If you haven’t already got one set up (such as if your new repo is associated to a new Github account), you’ll need to first generate an SSH public/private key pair. This will allow your ServiceNow instance to authenticate to your your Github account and repositories.

  1. Using a tool such as this one, enter a passphrase and click Generate-SSH-Keys. Save the Public and Private keys somewhere temporarily, and don't forget the passphrase! You’ll need all three of these in a bit.

  2. From Github, click your profile icon and go to Settings


Read more

How to return a CSV file from a Scripted REST API (SRAPI) in ServiceNow

I recently dealt with a requirement whereby I needed to export only certain columns from records on a given table that match a given query, to a CSV file.

“No problem”, I said; “that’s easy. You just add ‘?CSV’ to the end of the table URL.”

Oh, but it’s never that easy, is it? In this case, there were a few odd stipulations:

  • The header names need to be specific strings (not the same as their column names in ServiceNow)

  • Some of the columns need to have calculated or static values; values not in ServiceNow (and we don’t want to make calculated columns for them)

  • The endpoint must not return CSV data embedded in a JSON response body, but must actually return a CSV file. Or to put it more precisely, the endpoint URL must resolve to a CSV file.

Because of the nature of this requirement, I was going to need to create a Scripted REST API (SRAPI); so I did


Click below to read more!

Read more

Adding a Guided Setup to Your ServiceNow Application

Very often, we’ll find ourselves writing a custom application (whether scoped or global) that requires some “setup” by the admin who installs it. Maybe we’re writing the app to be distributed to multiple ServiceNow customers, each with their own environments and needs; or maybe the app just requires a unique setup process in each instance we promote it to. Whatever the case, I’ve often had cause to want to build my own “guided setup”.
Unfortunately, for some reason, ServiceNow has made it difficult to create a guided setup in our own development instances.
In this article, we’re going to learn how to get around those limitations; then, we’re going to learn how to build a guided setup ourselves!

Read more

Use Automated Tests to Validate "Guided Setup" Completion & Functionality.

Here's a Quick Pro-Tip:

If you have an application which requires some setup or initial configuration, write ATF tests specifically to validate that the application is set up properly. Add executing the tests as a final step in your application's Guided Setup, and provide some meaningful output that directs the admin to the right place(s) to fix any issues identified by the tests.

For example, I'm building an application now which connects to an outside application running on


Read more

"Processors", SRAPIs, and How to Run a Script and Redirect a User From a URL in ServiceNow

Processors in ServiceNow are (were) actually extremely useful things, though they’re surprisingly not very well-known. They give you a URL you can hit (like my_processor.do) and allow you to run a server-side script, then redirect the user to some other page.

Processors are quite useful for situations like generating a record and then redirecting the user to that record just by navigating to one URL, or - by adding some URL parameters (like my_processor.do?some_param=some_value) automating some simple or complex processes with nothing more than a single click of a URL! You can generate that URL dynamically and present it in the UI somewhere (for example, by using gs.addInfoMessage()), or link to the processor in an email. You could even use something like my “Set Catalog Variables from URL Parameters” tool in conjunction with this functionality to dynamically populate and submit RITMs from a single click of a link in a Knowledge Article!

Some pre-existing useful processors are:

  • System cache flush (cache.do)

  • Attachment processor for constructing and viewing attachments (sys_attachment.do)

  • Content search (content_search.do)

  • Customer service chat (CustomerServiceChat.do)

  • Export Wizard (export_wizard.do)

While it’s possible to modify the ACLs on the Processor table to allow you to create them again (for now), that may not be the best idea for long-term support.

So, if we don’t use a processor, how can we accomplish this functionality in our app? The answer is Scripted REST APIs (SRAPIs) plus a little bit of http header magic!

In this article, we’re going to show you how to accomplish (mostly) the same functionality as a processor using an SRAPI, and provide some code you can use to get your pseudo-processor SRAPI up-and-running within minutes! We’ll also provide some best-practice advice for how to use SRAPIs in this way, and outline some specific use-cases for this sort of thing.

Read more

SN Guys is now part of Jahnel Group!

It’s finally here! We’re thrilled to announce that The SN Guys (which runs SN Pro Tips)will be joining forces with our new parent company, Jahnel Group!
The Jahnel Group team is a passionate and dedicated group of over 100 software engineers with 20+ years of experience in the industry. Jahnel Group has worked closely with SN Guys for the past three years, and it’s been an exciting adventure to grow together. This new collaboration will allow our team to further deliver in the ServiceNow space and bring even more horsepower to our customers and community.

We look forward to starting out this new chapter together, to accomplish a bigger and better vision in the ServiceNow space and beyond.

More great stuff is coming soon. Don’t forget to subscribe to our newsletter, to stay informed!

Read more

Better ServiceNow Notifications (& Another FREE Tool!)

You’ve just implemented a new instance, process, catalog item, or workflow.
You put all that time and thought, and effort into making sure that everything that anyone could possibly want to know about, results in an email notification to all potentially-interested parties, so that nothing can possibly slip through the cracks!
And yet
 somehow
 you notice that users are still, often, not taking action where appropriate. Didn’t they get the email!?
You look through the email logs, and find that - indeed - among the sea of notifications that had been sent to them, there it is: the email telling them that they need to do something.

You: "Hey [approver], it looks like we've been waiting for you to approve this request for a couple of weeks now. Haven't you got any of the notification or reminder emails?"
Approver: "Uh... I have notifications from ServiceNow filtered to junk..."

Most of us have had some variation of this conversation.
Maybe they’ve filtered emails from ServiceNow to their junk folder. Maybe they’ve got a separate “special” folder just for SN emails, where they can be auto-routed and never looked at. Maybe they’ve just got so accustomed to 90% of the emails they get from ServiceNow being irrelevant or non-actionable for them, that they’ve got into the habit of just deleting them as soon as they show up.
The result is the same: your users aren’t getting your emails!

A notification that’s never read, is worse than no notification at all.


So, how do we stop this vicious cycle? -- Let’s talk about notifications in ServiceNow.

Read more