Scheduler api controller not found

I am currently coding an MVC c# project that requires an events calendar. I followed the directions on dhtmlxScheduler with ASP.NET MVC Scheduler Docs
and I am still unable to add events to my database. I think the error I am getting is in my calendar views script. Bellow is a screenshot of the error messages I am getting.


Any help will be appreciated
Thanks

Hello,
Most likely, it is connected to DataProcessor which has moved from the global dataProcessor function to the scheduler.DataProcessor function:
https://docs.dhtmlx.com/scheduler/migration_from_older_version.html#5360 1 ;
Try to replace the following code:

var dp = scheduler.createDataProcessor("/api/scheduler");
// and attaching it to scheduler
dp.init(scheduler);
// setting the REST mode for dataProcessor
dp.setTransactionMode("REST");

by this one:

var dp = scheduler.createDataProcessor({
    url: "/api/scheduler",
    mode: "REST"
});

Also, you can face exception occurred while initializing the database. There is a special article that can help you (also for scheduler):
https://docs.dhtmlx.com/gantt/desktop__howtostart_dotnet.html#troubleshooting:~:text=An%20exception%20occurred%20while%20initializing%20the%20database ;
If it doesn’t help you, please send me a ready demo with all the necessary files so that I can reproduce the issue locally.

After examining the error a bit more, it is caused by “scheduler.load(“api/scheduler”);” I have replaced the code with the code you suggested and I still get the same error. I don’t think initializing the database is the issue as I can make use of it in other parts of the application.