All Projects → Snow-Shell → servicenow-powershell

Snow-Shell / servicenow-powershell

Licence: Apache-2.0 license
PowerShell module to automate ServiceNow service and asset management. This module can be used standalone, with Azure Automation, or Docker.

Programming Languages

powershell
5483 projects
Dockerfile
14818 projects

Projects that are alternatives of or similar to servicenow-powershell

Sso
sso, aka S.S.Octopus, aka octoboi, is a single sign-on solution for securing internal services
Stars: ✭ 2,835 (+814.52%)
Mutual labels:  oauth
undertow-pac4j
Security library for Undertow: OAuth, CAS, SAML, OpenID Connect, LDAP, JWT...
Stars: ✭ 35 (-88.71%)
Mutual labels:  oauth
google-oauth2-web-client
Login with Google using OAuth2 for client-side web app
Stars: ✭ 32 (-89.68%)
Mutual labels:  oauth
Gocialite
Social oAuth login in Go has never been so easy
Stars: ✭ 237 (-23.55%)
Mutual labels:  oauth
Apijam
GitHub repo for API Jam Workshop
Stars: ✭ 254 (-18.06%)
Mutual labels:  oauth
Device-Flow-Proxy-Server
Add the OAuth 2.0 Device Flow to any OAuth server
Stars: ✭ 64 (-79.35%)
Mutual labels:  oauth
Angularmaterialfirebase
🔥 Full stack starter app with Angular 8, Material Design and Firebase (+ demo)
Stars: ✭ 229 (-26.13%)
Mutual labels:  oauth
shopify-node-express-app
Simple Shopify app with Express and Node.js that connects to a Shopify store via OAuth.
Stars: ✭ 20 (-93.55%)
Mutual labels:  oauth
react-linkedin-login-oauth2
Easily get Authorization Code from Linked In to log in without redirecting.
Stars: ✭ 83 (-73.23%)
Mutual labels:  oauth
servicenow-instance-wakeup
Wake up your servicenow instance from hibernation
Stars: ✭ 35 (-88.71%)
Mutual labels:  servicenow
Golang Url Shortener
URL Shortener written in Golang using Bolt DB or Redis. Provides features such as Deletion, Expiration, OAuth and is of course Dockerizable.
Stars: ✭ 240 (-22.58%)
Mutual labels:  oauth
Bus
Bus 是一个基础框架、服务套件,它基于Java8编写,参考、借鉴了大量已有框架、组件的设计,可以作为后端服务的开发基础中间件。代码简洁,架构清晰,非常适合学习使用。
Stars: ✭ 253 (-18.39%)
Mutual labels:  oauth
ApiJwtWithTwoSts
Web API authorization, multi-IDP solutions in ASP.NET Core
Stars: ✭ 43 (-86.13%)
Mutual labels:  oauth
Pow assent
Multi-provider authentication for your Pow enabled app
Stars: ✭ 236 (-23.87%)
Mutual labels:  oauth
cli-cube-timer
Time your solves, without leaving the terminal
Stars: ✭ 19 (-93.87%)
Mutual labels:  oauth
Spring Security Pac4j
pac4j security library for Spring Security: OAuth, CAS, SAML, OpenID Connect, LDAP, JWT...
Stars: ✭ 231 (-25.48%)
Mutual labels:  oauth
ada-security
Ada Security - OAuth 2.0 client and server framework to secure web applications
Stars: ✭ 18 (-94.19%)
Mutual labels:  oauth
okta-microservice-security-examples
Demos from Oktane18: API and Microservices Best Practices
Stars: ✭ 17 (-94.52%)
Mutual labels:  oauth
oauther
OAuth 1.0 for Elixir
Stars: ✭ 64 (-79.35%)
Mutual labels:  oauth
cb4
Joint Online Judge
Stars: ✭ 20 (-93.55%)
Mutual labels:  oauth

ServiceNow

PowerShell Gallery Version PowerShell Gallery GitHub license

This PowerShell module provides a series of cmdlets for interacting with the ServiceNow REST API.

IMPORTANT: Neither this module nor its creator are in any way affiliated with ServiceNow.

Requirements

Requires PowerShell 5.1 or above.

Requires authorization in your ServiceNow tenant. Due to the custom nature of ServiceNow your organization may have REST access restricted. The following are some tips to ask for if you're having to go to your admin for access:

  • Out of the box tables should be accessible by granting the ITIL role.
  • Custom tables may require adjustments to the ACL.
  • The Web_Service_Admin role may also be an option.

Usage

The ServiceNow module should be installed from the PowerShell Gallery with install-module ServiceNow.

A docker image is also available with Microsoft's PowerShell base image and the ServiceNow module preinstalled. The following environment variables should be used:

  • SNOW_SERVER: the ServiceNow instance, eg. instance.service-now.com
  • SNOW_TOKEN: pre-generated oauth token. Provide this or SNOW_USER/SNOW_PASS.
  • SNOW_USER: username to connect to SNOW_SERVER
  • SNOW_PASS: password for SNOW_USER

When using the docker image, creating a new session is not required.

Creating a new session

Creating a new session will create a script scoped variable $ServiceNowSession which will be used by default in other functions.

Basic authentication with just a credential...

$params = @{
    Url = 'instance.service-now.com'
    Credential = $userCred
}
New-ServiceNowSession @params

Oauth authentication with user credential as well as application/client credential. The application/client credential can be found in the System OAuth->Application Registry section of ServiceNow.

$params = @{
    Url = 'instance.service-now.com'
    Credential = $userCred
    ClientCredential = $clientCred
}
New-ServiceNowSession @params

Note: ServiceNow's API does not support SSO

All examples below assume a new session has already been created.

Getting incidents opened in the last 30 days

$filter = @('opened_at', '-ge', (Get-Date).AddDays(-30))
Get-ServiceNowRecord -Table incident -Filter $filter

Retrieving an Incident Containing the Word 'PowerShell'

Get-ServiceNowRecord -Table incident -Filter @('short_description','-like','PowerShell')

Update a Ticket

Get-ServiceNowRecord -First 1 -Filter @('short_description','-eq','PowerShell') | Update-ServiceNowIncident -Values @{comments='Updated via PowerShell'}

Creating an Incident with custom table entries

$IncidentParams = @{Caller = "UserName"
            ShortDescription = "New PS Incident"
            Description = "This incident was created from Powershell"
            CustomFields = @{u_service = "MyService"
                            u_incident_type = "Request"}
            }
New-ServiceNowIncident @Params

Azure Connection Object (Automation Integration Module Support)

The module can use the Connection parameter in conjunction with the included ServiceNow-Automation.json file for use as an Azure automation integration module. Details of the process is available at Authoring Integration Modules for Azure Automation.

The Connection parameter accepts a hashtable object that requires a username, password, and ServiceNowURL.

Scope & Contributing

Contributions are gratefully received, so please feel free to submit a pull request with additional features or amendments.

Authors

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].