ServiceNow authentication action
- Updated: 2024/09/25
ServiceNow authentication action
Use the Authentication action to connect to your ServiceNow instance. After the authentication is successful, you can use other command actions to perform various operations in ServiceNow.
Prerequisites
- You must have the Client ID and Client secret generated in your ServiceNow instance. To generate the Client details, see Create an OAuth API endpoint for external clients.
- You must have the Bot creator role for your Automation Anywhere Control Room to use the ServiceNow package in a bot.
You can use different connection methods to connect to ServiceNow:
- OAuth2 - Client Credentials: Use this connection method by providing the ServiceNow account credentials. You need a ServiceNow username and password to establish a connection.
- Control room OAuth connection: Use this connection method by creating an OAuth connection and storing it in the Control Room. You must configure an OAuth connection in ServiceNow before creating the OAuth connection in Control Room. For more details, see Create an endpoint for clients to access the instance.
Procedure
- Log in to the Control Room.
- Create a new bot or edit an existing bot. See Create your first bot.
- From the Actions pane, select and place it under the start of the bot flow.
- In the Authentication Type field, select the authentication method from the drop down.
-
To view client ID and client secret details in ServiceNow for OAuth2 -
Client Credentials authentication, complete the following steps:
- Log in to your ServiceNow instance.
- Click .
- Select the OAuth you created.
- Use the Client ID and Client Secret in your Authentication action from the Control Room.
-
To connect using OAuth2 - Client Credentials, complete the following steps:
-
To configure a Control room OAuth connection in ServiceNow,
complete the following steps:
- To connect using Control room OAuth connection, pick a custom connection you have created and stored in the Control Room. For more details, see Configure OAuth connections in Control Room.
- Enter Default as the Session name.
- You can assign the authorization header to a variable by creating either a Multiple or Dictionary variable.
- Click Run to save and run your bot. Once authenticated, you can use the token to call other ServiceNow API services.