2sxc: All custom API calls return 404 in the last couple updates

I’m submitting a … [x] bug report

…about [x] APIs like REST

Current behavior I get this error in every single call I try to make:

template: $2sxc(@Dnn.Module.ModuleID).webApi.post("demo/returnDxInfo", {}, woundtype, true).then(handleState);

API (api/demoController.cs):

[HttpPost]
    [DnnModuleAuthorize(AccessLevel = SecurityAccessLevel.Anonymous)]
    [ValidateAntiForgeryToken]
    public DxData returnDxInfo([FromBody]int dx)
    {

Response: {"Message":"No HTTP resource was found that matches the request URI 'https://site.pt/pt-pt/API/2sxc/app/auto/api/demo/returnDxInfo'.","MessageDetail":"No controller was created to handle this request."}

Expected behavior API works fine. This is actually old code that worked fine until now.

  • 2sxc version(s): 10.06
  • DNN: [9.4]

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 19 (11 by maintainers)

Commits related to this issue

Most upvoted comments

The DNN team seems to fear breaking new things if they fix this. So they don’t want to do this. Because of this, we’ll fix it in 2sxc in 10.08. We already have a solution.

How does that make sense? They changed things that broke your stuff. They need to fix it. I realize its more complicated than I can imagine, but still. #sigh (no response necessary)

Just to be clear on the decision point from the DNN Platform team, the changes that we introduced in 9.4.0 introduced improved functionality for the platform as a whole, and was done in a manner to limit any impacts to third parties.

We have chosen to not support the requested change for 2sxc, as the changes in 9.4.0+ actually provide a more secure infrastructure for the entire DNN Platform community, which is the number one priority of the DNN Platform team.

I’ve spent some time on this, and it looks like 2sic is doing everything right, but DNN 9.4 does something differently. I’ll try to ask for help of people who worked on DNN 9.4