Create spoke and build actions by importing a Postman collection
Automate an integration and generate reusable actions by importing a Postman collection.
Before you begin
- Install the Spoke Generator app from the ServiceNow Store.
- Confirm that ServiceNow Integration Hub Professional Pack Installer (com.glide.hub.integrations.professional) is installed and the license is entitled.
- Role required: admin
Procedure
- Navigate to All > Process Automation > Workflow Studio.
- Click Create new > Spoke.
-
On the Spoke Info screen, specify if you want to create the spoke in a new scope or an existing scope.
-
If you choose to create the spoke in a new scope, select an image as the logo for your integration and fill in the fields.
Here, we will go through an integration with Notion as an example.
Field Description Spoke name Name to identify the custom spoke. Description Description about the custom spoke. System Search and select the external system to integrate. Connector type Select Spoke from the list. Note:The value of App scope name is the format: x_<company-code>_<spoke-name>_<spoke>. By default, the <company-code> is, snc. You can configure the company code by configuring Value of the system property, glide.appcreator.company.code.
This configured value is used when the value App scope name is generated.
-
If you choose to create the spoke in an existing scope, select an image as the logo for your integration and fill in the fields.
Here, we will go through an integration with AWS as an example.
Field Description Application name An existing application name or scope. App scope name Scope name that is auto-populated based in the selected Application name. Description Description about the custom spoke. System Search and select the external system to integrate. Connector type Select Spoke from the list.
-
If you choose to create the spoke in a new scope, select an image as the logo for your integration and fill in the fields.
-
Click Continue.
Based on the provided name and description, if there are any matching spokes on Store, the spoke details are displayed.
-
Click View details on Store to see the details of the matching spokes.
Details of the matching spokes are displayed in a new browser tab.
-
Install the spoke from the Store.
For more details, see Install a ServiceNow Store application.
-
After installing the spoke, navigate to the Workflow Studio tab.
The system displays the message Have you installed a spoke from the Store?.
-
Select one of these options and click Continue.
Option Description Yes, view the installed spoke. Option to redirect to the Spokes dashboard under Integrations. No, I will build custom spoke. Option to continue with spoke creation. No, I want to exit spoke creation. Option to close the current tab.
-
Click View details on Store to see the details of the matching spokes.
-
Click Skip if you want to build the custom spoke.
Note:These following steps are also applicable if you have selected the No, I will build custom spoke. option.
The spoke is created and a confirmation message is displayed.
-
On the Build Info screen, select the method using which you want to build your spoke.
You can choose to build your spoke using OpenAPI specification or Postman collection.
-
Select Postman collection and click Continue to import a Postman collection.
- For Postman collection source, click Import new.
-
On the Import new postman collection source screen, perform one of these two steps.
-
If you want to import using an URL, select Import from URL for Import method and specify the URL in Postman collection URL.
-
If you want to import manually using JSON code, select Import from JSON manually for Import method and provide the code in JSON.
-
If you want to import using an URL, select Import from URL for Import method and specify the URL in Postman collection URL.
-
Click Import.
The Postman collection source is imported.
- For Connection and credential alias, click Create new.
-
On the Create new connection and credential alias screen, fill in the fields and provide the alias information.
Field Description Connection & Credential name Name to identify the connection and credential alias record. Configuration Template for authentication Required authentication mechanism for this integration. Ensure that the authentication mechanism is compatible with the OpenAPI source. Note:The configuration template is auto-populated based on the OpenAPI specification you had provided. You can continue with the default option or change it as per your requirement. - Click Create alias and continue.
-
On the same screen, fill in the fields to configure the alias.
Field Description Connection Information Connection Name Name to identify the connection record. Connection URL Base URL to connect to the third-party instance or server. This URL is auto-populated based on the Postman collection source you had provided. Credential Information Based on the configuration template you had selected, the relevant credential fields are displayed. Provide the required values to configure the credential record. If you want configure the alias record later, click Do it later.
-
Click Submit.
The connection alias record is created.
-
Click Generate operations.
All the operations that can be performed using the OpenAPI Specification are listed.
-
Select the required operations.
You can search for the required actions by entering the required term in the search bar. The actions that match the specified search term are displayed.
-
Click Publish.
Alternatively, you can also select Save actions as Draft to save the actions as draft, modify them as per your requirement, and publish them later.
-
Click Done: Go to spoke to go the Spokes page and view the publish status.
- Actions with the OpenAPI step are created. For information about the OpenAPI step, see OpenAPI support in the REST step.
- Action inputs and outputs are mapped.
- Actions are published and listed in the spoke details page under Actions > Published.
You can start using these published actions to create flows and subflows as per your requirement.
- If you have saved actions as draft, you can access these draft actions in the spoke details page under Actions > Draft.
- To view run-time information about the spoke activities, click Spoke activity log in the spoke details page. Every time a spoke activity is performed, the system generates its information
as a spoke activity log. Click the required Number to view the activity log. Every operation in the spoke activity log has one of these status values:
Status Description new An event for the operation is created and this operation will be executed soon. error The operation has failed to execute. processing The operation execution is in progress. success The operation has been executed successfully.
You can create flows and subflows in the spoke details page and use them in your integration. For more information, see Building flows and Building subflows.
Along with Spoke activity log, you can also view details of the available flows, subflows, and actions in the spoke details page.