Create a simple processor

Create a simple processor to execute a script from a URL query.

About this task

The following steps assume that you have your own demonstration instance.

Procedure

  1. Navigate to System Definition > Processors.
  2. Click New.
  3. Enter the following information.
    FieldValue
    Name Hello
    Type Script
    Path Hello
    Script
    var name= g_request.getParameter("name");
    g_processor.writeOutput("text/plain","Hello "+name);
  4. Click Submit.
  5. Enter a URL query to the instance with the following format: https://instance.service-now.com/processor_name.do?parameter=value. For example: https://<instancename>.service-now.com/Hello.do?name=world.