You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Readme.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -43,7 +43,7 @@ $params = @{
43
43
New-ServiceNowSession @params
44
44
```
45
45
46
-
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.
46
+
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. The access token will be refreshed automatically when it expires.
Copy file name to clipboardExpand all lines: ServiceNow/Public/New-ServiceNowSession.ps1
+7-1Lines changed: 7 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -6,8 +6,11 @@ Create a new ServiceNow session
6
6
Create a new ServiceNow session via credentials, OAuth, or access token.
7
7
This session will be used by default for all future calls.
8
8
Optionally, you can specify the api version you'd like to use; the default is the latest.
9
+
9
10
To use OAuth, ensure you've set it up, https://docs.servicenow.com/bundle/quebec-platform-administration/page/administer/security/task/t_SettingUpOAuth.html.
10
11
12
+
If using OAuth, the client credential will be stored in the script scoped variable ServiceNowSession and the access token will be automatically refreshed.
13
+
11
14
.PARAMETERUrl
12
15
Base domain for your ServiceNow instance, eg. tenant.domain.com
13
16
@@ -200,8 +203,11 @@ function New-ServiceNowSession {
0 commit comments