Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Why am I receiving WebAPI response status as 204 (No Content)

(0) ShareShare
ReportReport
Posted on by 80

We have created a custom action(OOB with two input and one output parameter) and called the same from JavaScript through WebAPI.If the call is synchronous the response status is 200 and able to get output parameter as the response text.

But if the call is asynchronous then the behaviour is weird sometimes it gives response status as 204 and sometimes 200.

Could someone let us know why we are receiving 204(No Content) status as we are expecting output parameter as response text always.

*This post is locked for comments

  • Suggested answer
    RE: Why am I receiving WebAPI response status as 204 (No Content)

    This is a known issue for v8.2 on-premise. Upgrading to v9 on-premise will resolve the issue. To work-around it in v8.2 you can recycle the app pool.

  • Suggested answer
    Yusi Profile Picture
    Yusi 100 on at
    RE: Why am I receiving WebAPI response status as 204 (No Content)

    I faced the same issue and restarting the app server alone solved my problem. Now getting 200 instead of 204 with a valid returned content value

  • Suggested answer
    RE: Why am I receiving WebAPI response status as 204 (No Content)

    I had the same error.

    I deleted the plugin registration and deleted the process. Then I created it again, but with the same result.

    My solution was to create the process with a new name. Registered the plugin and everything worked again.

    I think that there is something like a caching on the server, that only recreating is not enough. Maybe deleting the process, restart the system (iisreset) and recreation my help.

  • Peter Widmer Profile Picture
    Peter Widmer 40 on at
    RE: Why am I receiving WebAPI response status as 204 (No Content)

    There seems to be a bug (which Laszlo Penzes pointed out already).

    The workaround is like this: Create a new action and get all parameters (input and output) right before saving the action. After doing so I correctly received the content (200)

  • LaszloPenzes Profile Picture
    LaszloPenzes on at
    RE: Why am I receiving WebAPI response status as 204 (No Content)

    Same here.

    Created a custom action with one output parameter. Assigned a value to that param and activated -> worked ok.

    Made a minor change to the action (amended the value assigned to output param) -> stopped working and the only thing it returns is 204 No Content.

    Some folks wrote that there's a problem with WF editor that makes the XAML file to have invalid content. I exported both versions of the solution and compared the files, but no difference.

  • Fede Jousset Profile Picture
    Fede Jousset 30 on at
    RE: Why am I receiving WebAPI response status as 204 (No Content)

    Hi there,

    Were you able to find the root cause or fix this issue? I'm having the same problem calling a Custom Action using the WebAPI endpoint, but in our scenario it's a synchronous execution.

    Thank you!

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

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,516 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,409 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans