+++
# -----------------------------------------------------------------------
# Do not edit this file. It is automatically generated by API Documenter.
# -----------------------------------------------------------------------
title = "DataSourceWithBackend"
keywords = ["grafana","documentation","sdk","@grafana/runtime"]
type = "docs"
draft = true
+++
## DataSourceWithBackend class
Signature
```typescript
export declare class DataSourceWithBackend extends DataSourceApi
```
Import
```typescript
import { DataSourceWithBackend } from '@grafana/runtime';
```
Constructors
| Constructor | Modifiers | Description |
| --- | --- | --- |
| [constructor(instanceSettings)](#constructor-instancesettings) | | Constructs a new instance of the DataSourceWithBackend
class |
Methods
| Method | Modifiers | Description |
| --- | --- | --- |
| [query(request)](#query-method) | | Ideally final -- any other implementation would be wrong! |
| [testDatasource()](#testdatasource-method) | | |
| [toDataQueryResponse(rsp)](#todataqueryresponse-method) | | This makes the arrow library loading async. |
### constructor(instanceSettings)
Constructs a new instance of the `DataSourceWithBackend` class
Signature
```typescript
constructor(instanceSettings: DataSourceInstanceSettings);
```
Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| instanceSettings | DataSourceInstanceSettings<TOptions>
| |
### query method
Ideally final -- any other implementation would be wrong!
Signature
```typescript
query(request: DataQueryRequest): Observable;
```
Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| request | DataQueryRequest
| |
Returns:
`Observable`
### testDatasource method
Signature
```typescript
testDatasource(): Promise<{}>;
```
Returns:
`Promise<{}>`
### toDataQueryResponse method
This makes the arrow library loading async.
Signature
```typescript
toDataQueryResponse(rsp: any): Promise;
```
Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| rsp | any
| |
Returns:
`Promise`