Flow Action: Run Scheduled Data Import#260
Merged
Lacah merged 1 commit intoServiceNowDevProgram:mainfrom Oct 31, 2025
Merged
Conversation
|
✅ Valid PR for ActionPack Thank you for your contribution. This PR complies with the CONTRIBUTING.md. |
Lacah
approved these changes
Oct 31, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR Summary: feat(flow): Add 'Run Scheduled Data Import' Action
Description:
This PR introduces a new custom Flow Designer action, "Run Scheduled Data Import," within the "Action Pack" application. This action allows developers to programmatically trigger a specific Scheduled Data Import (Data Source) on-demand as part of a flow or subflow.
The primary use case is for ad-hoc execution of data imports that are normally on a fixed schedule, providing greater flexibility for integrations and automated processes.
Key Components:
Action: Run Scheduled Data Import
Description: "Ad-hoc trigger Scheduled Data Import"
Accessibility: Available from all application scopes.
Action Inputs:
import): A mandatory reference field to the 'Scheduled Data Import' (scheduled_import_set) record that needs to be executed.Action Outputs:
Import Ran (
import_ran): A True/False boolean value indicating whether the import was successfully triggered.true: TheSncTriggerSynchronizer.executeNow()API returned a job ID, implying the import was initiated.false: TheSncTriggerSynchronizer.executeNow()API did not return a value, indicating the import failed to start.Logic (Script Step):
The action uses a script step to retrieve the specified
scheduled_import_setrecord.It executes the import using
SncTriggerSynchronizer.executeNow().It then checks the return value from
executeNow()to populate theimport_ranoutput variable.Error Handling:
import_ranoutput isfalse.How to Test:
Create a new Flow.
Add the "Run Scheduled Data Import" action.
In the "Import" input, select a valid, existing Scheduled Data Import (e.g., a test data source).
Run the flow and check the execution details.
Verify that the
import_ranoutput istrue.Navigate to the "Import Sets" module and confirm that a new import set was created and processed for the triggered data source.