web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Suggested Answer

Workflow Not Returning Response Despite Successful Execution via JavaScript in Dynamics 365

(4) ShareShare
ReportReport
Posted on by 21

Hello Dynamics 365 Community,

I am encountering an issue in a Dynamics 365 where a custom action (or workflow) triggered via JavaScript executes successfully, but does not return the expected response to the JavaScript code. This delay or absence of response is affecting critical functionality in our application. Interestingly, the response is received correctly 4-5 hours later, the solution has been imported, and the behavior varies depending on how the solution is imported. I’m seeking assistance to diagnose the root cause and identify a solution.

Issue:


  • The action executes successfully (verified in System Jobs or Process Sessions), and server-side logic (e.g., field updates) completes as expected.

  • However, the JavaScript success callback does not receive the expected response immediately; it’s either empty or undefined.
 
Solution Import Behavior:

  • When the solution is imported via Power Apps (make.powerapps.com), the issue does not occur, and the response is returned immediately.

  • When imported via Package Deployer or Legacy UI, the issue persists (no immediate response).

 

I’m hoping someone can help me identify what I might be missing or suggest a solution.

I have the same question (0)
  • Ramesh Kumar Profile Picture
    7,527 Super User 2025 Season 2 on at
    Its hard to predict but I would suggest Reimport the solution using Power Apps (since that path works consistently), then publish all customizations.
     
    if issue still persists I would raise ticket with Microsoft.
     
    Thanks
    Ramesh
     
     
  • Suggested answer
    Mansi Soni Profile Picture
    8,907 Super User 2025 Season 2 on at
  • Suggested answer
    DAnny3211 Profile Picture
    11,397 on at

    Hello,

    Thank you for providing a detailed description of the issue. Based on your observations, it appears that the custom action or workflow is executing successfully on the server side, but the JavaScript callback is not receiving the expected response immediately—particularly when the solution is imported via Package Deployer or the Legacy UI.

    Possible Causes and Recommendations:

    1. Solution Import Differences
      The discrepancy in behavior between imports via Power Apps and Package Deployer/Legacy UI may be due to differences in how metadata and dependencies are registered. Ensure that:

      • All components (including custom actions, workflows, and plugin steps) are published correctly after import.
      • The solution layering is consistent and does not leave components in an unmanaged or partially updated state.
    2. Callback Configuration in JavaScript
      Verify that the JavaScript code is correctly handling the asynchronous response from the action. Ensure that:

      • The successCallback function is properly defined and attached.
      • The response.getReturnValue() or equivalent method is used to extract the result.
    3. Caching or Propagation Delay
      The delayed response (4–5 hours later) may indicate a caching issue or delayed propagation of metadata changes. Consider:

      • Performing a full publish of all customizations after import.
      • Restarting the environment or clearing server-side cache if applicable.
    4. Plugin or Action Configuration
      Review the configuration of the custom action:

      • Ensure that the output parameters are correctly defined and returned.
      • Check for any plugin steps that may be intercepting or modifying the response.
    5. Environment-Specific Behavior
      If the issue is environment-specific, compare the solution import logs, customization settings, and security roles across environments to identify discrepancies.

    If this guidance helps resolve the issue, please consider marking the response as accepted so it may assist others encountering similar challenges.

    Best regards.

  • ARMC Profile Picture
    21 on at

    @Mansi Soni & @Ramesh Kumar – thank you for your insightful responses!

     

    As I’m using Package Deployer to import the solution along with an additional data.zip file, I’m unable to include the data file through PowerApps, since it doesn’t support importing external data packages.

     

    Note: Importing the data file is essential, as much of the solution’s functionality depends on it.

     

    Regarding the code suggestion, @Mansi Soni, that’s actually the same approach I’ve already implemented, please see the code snippet below for reference.
     

     var response = Xrm.WebApi.online.execute(request).then(
                    function (data) {
                        data.json().then(function (formattedData) {
                            if (formattedData != null && formattedData["OutputData"] != null) {
                                onSuccesstrialActivation(JSON.parse(formattedData["OutputData"]));
                            }
                        });
                    },
                    function (error) {
                        throwError(response, "");
                    }
                );

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Microsoft Dynamics 365 | Integration, Dataverse, and general topics

#1
Siv Sagar Profile Picture

Siv Sagar 93 Super User 2025 Season 2

#2
#ManoVerse Profile Picture

#ManoVerse 76

#3
Martin Dráb Profile Picture

Martin Dráb 64 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans