Skip to main content
All docs
V24.2

FetchRemoteServiceOptions Interface

Provides options for customizing the FetchRemoteService.

Declaration

export interface FetchRemoteServiceOptions

Remarks

The Fetch remote service is a default IRemoteService<TResponse> implementation that exchanges information between client and server sides. You can get different information from a server (data sources, export information, a dashboard model), obtain a dashboard request time, pass custom HTTP headers, and more.

Refer to the following topics for information on how to set the server’s URL and pass a custom Authorization header from the client:

You can also view the following example on GitHub:

View Example: ASP.NET Core Dashboard - How to implement authentication

You can use Web Forms, MVC, and ASP.NET Core dashboard applications as a client for a server. See the following topic to learn more: DashboardBackendOptions.

Properties

beforeSend Property

Specifies a pre-request callback function that allows you to modify the options parameter before the request is sent.

Declaration

beforeSend?: (settings: RequestInit) => void

Property Value

Type Description
(settings: RequestInit) => void

A function that can be used to modify the options parameter before the Fetch request is sent.

headers Property

Specifies an object with additional headers (key/value pairs) to send along with requests.

Declaration

headers?: {
    [key: string]: any;
}

Property Value

Type Description
[key: string]: any

A collection of header key/value pairs.