Using OAuth, you can pass a user ID and password once, and then use a token for
subsequent REST requests instead of submitting credentials with each request
-
Log in to the ServiceNow instance.
-
Activate the OAuth 2.0 plugin.
-
In the sys_properties table, set the system property
com.snc.platform.security.oauth.is.active to true.
-
Click .
-
Click NEW and then click an OAuth API endpoint for external
clients.
-
Specify the following parameters:
- Name
- Enter a unique name.
- Client ID
- Client ID automatically generated by ServiceNow OAuth server.
- Client secret Key
- Client secret for the OAuth application.
- Refresh Token Lifespan
- Time in seconds the refresh token is valid.
- Access Token Lifespan
- Time in seconds the access token is valid.
-
Record the value of client ID and client Secret from the previous step.
-
Click Submit.
Note: OAuth configuration is not mandatory to establish connection with ServiceNow. OAuth
Configuration is required only for token-based login, otherwise ServiceNow credentials are used to
establish the connection.