Skip to main content
A newer version of this page is available. .

Server-Side API Overview

  • 6 minutes to read

The Web Dashboard comprises client and server parts:

  • The client part supplies end-users with a user interface for designing a dashboard and interacting with it.
  • The server part handles client data requests and provides various backend capabilities such as accessing data, storing dashboards, etc.

The Web Dashboard requires configuring various server-side options before first use. These include preparing a dashboard storage, registering predefined data sources, etc. Each platform (Web Forms, MVC, .NET Core) has a different approach to utilizing a server-side API.

If you use the ASP.NET MVC Dashboard extension, select one of the following approaches:

  • The ASP.NET MVC Dashboard uses an API exposed by the DashboardConfigurator class. In this case, the DashboardConfigurator.Default object provides access to shared server-side settings (data source settings, data connections, etc.).
  • You can create and initialize separate DashboardConfigurator instances within an application to provide different server-side settings. For instance, you can use separate settings for different views. To learn more, see the example below.

The MVCxDashboard uses the DashboardExtensionSettings class to configure the specific extension’s settings.

Example

This example shows how to use separate DashboardConfigurator instances within an ASP.NET MVC Dashboard application to provide different server-side settings. In this example, the Sales and Marketing views use different dashboard storage and different data connections.

using System.Web.Mvc;

namespace MVCDashboard_ServerSideAPI.Controllers {
    public class HomeController : Controller {
        public ActionResult Index() {
            return View();
        }

        public ActionResult SalesDashboards() {
            return View("SalesView");
        }
        public ActionResult MarketingDashboards() {
            return View("MarketingView");
        }
    }
}