Firebase Data Connect service.
Functions
| Function | Description | 
|---|---|
| getDataConnect(connectorConfig, app) | Gets the DataConnect service with the provided connector configuration for the default app or a given app. getDataConnect(connectorConfig)can be called with no app argument to access the default app'sDataConnectservice or asgetDataConnect(connectorConfig, app)to access theDataConnectservice associated with a specific app. | 
Classes
| Class | Description | 
|---|---|
| DataConnect | The Firebase DataConnectservice interface. | 
Interfaces
| Interface | Description | 
|---|---|
| ConnectorConfig | Interface representing a Data Connect connector configuration. | 
| ExecuteGraphqlResponse | Interface representing GraphQL response. | 
| GraphqlOptions | Interface representing GraphQL options. | 
| ImpersonateAuthenticated | Interface representing the impersonation of an authenticated user. | 
| ImpersonateUnauthenticated | Interface representing the impersonation of an unauthenticated user. | 
Type Aliases
| Type Alias | Description | 
|---|---|
| AuthClaims | Type representing the partial claims of a Firebase Auth token used to evaluate the Data Connect auth policy. | 
getDataConnect(connectorConfig, app)
Gets the DataConnect service with the provided connector configuration for the default app or a given app.
getDataConnect(connectorConfig) can be called with no app argument to access the default app's DataConnect service or as getDataConnect(connectorConfig, app) to access the DataConnect service associated with a specific app.
Signature:
export declare function getDataConnect(connectorConfig: ConnectorConfig, app?: App): DataConnect;
Parameters
| Parameter | Type | Description | 
|---|---|---|
| connectorConfig | ConnectorConfig | Connector configuration for the DataConnectservice. | 
| app | App | Optional app for which to return the DataConnectservice. If not provided, the defaultDataConnectservice is returned. | 
Returns:
The default DataConnect service with the provided connector configuration if no app is provided, or the DataConnect service associated with the provided app.
Example 1
const connectorConfig: ConnectorConfig = {
 location: 'us-west2',
 serviceId: 'my-service',
};
// Get the `DataConnect` service for the default app
const defaultDataConnect = getDataConnect(connectorConfig);
Example 2
// Get the `DataConnect` service for a given app
const otherDataConnect = getDataConnect(connectorConfig, otherApp);
AuthClaims
Type representing the partial claims of a Firebase Auth token used to evaluate the Data Connect auth policy.
Signature:
export type AuthClaims = Partial<DecodedIdToken>;