Powershell with Service Now

This topic contains 4 replies, has 2 voices, and was last updated by  Paul 4 months ago.

  • Author
    Posts
  • #89702

    Paul
    Participant

    Hello everyone

    I'm very new to PowerShell – a complete newbie to be honest.

    I'd like to use PowerShell to automate some repetitive tasks in an application we use – Service Now.

    A quick check in service Now shows we are running the "Jakarta" build.

    The first thing i want to try and automate is a change request form. I do a few of these each month and it would be great to have a script that creates them. I appreciate I'd still need to manually enter/change a few details but to have an almost completed change form automated through PowerShell would be amazing.

    I found a Service Now Module online but have no idea if it will work.

    https://github.com/Sam-Martin/servicenow-powershell

    The first problem I have is that I cannot import the module. My company laptop is set to remotesigned and I cannot change it. I don't fancy messing around in the registry. My next step then is to try it on a personal PC.

    In the mean time, I'd be very grateful if anyone could share some tips or advice on how I can achieve this task.
    Would also like to hear if anyone has done this yet?

    Thank you

  • #89714

    Simon B
    Participant

    assuming your admin has not locked down you machine too much, you maybe able to use the below to import the modulw

    Set-ExecutionPolicy -executionpolicy RemoteSigned -Scope CurrentUser
    Install-Module PSServiceNow -Force -scope Currentuser
    Import-Module PSServiceNow

  • #89720

    Paul
    Participant

    Hi Simon

    Brilliant – that worked!
    Big thanks.

    Now I'm staring at the screen wondering how to proceed.

    Thanks again!

  • #89729

    Simon B
    Participant

    NP, I don't have access to ServiceNow anymore, but their website offered quite a bit of help if I remember.. Good luck

  • #89743

    Paul
    Participant

    Thanks again – Ill have a look and see if they have anything helpful for what I want to achieve.

You must be logged in to reply to this topic.