Page Summary
-
The
CommunityConnectorclass provides builders and utilities for developing Community Connectors for Data Studio. -
You can get references to
Fields,FieldType, andAggregationTypethrough theCommunityConnectorobject. -
The
CommunityConnectorclass has properties likeAggregationType,AuthType,BigQueryParameterType, andFieldType. -
Useful methods like
getConfig(),getFields(),newGetDataResponse(), andnewGetSchemaResponse()are available for connector development.
CommunityConnector enables scripts to access builders and utilities to help with development of
Community Connectors for Data Studio. Use this class to get a reference to the Fields
object and the FieldType and AggregationType enums so they can be used in the
construction of Fields.
const cc = DataStudioApp.createCommunityConnector(); const fields = cc.getFields(); fields.newMetric() .setAggregation(cc.AggregationType.AVG) .setType(cc.FieldType.CURRENCY_USD);
Properties
| Property | Type | Description |
|---|---|---|
Aggregation | Aggregation | The Aggregation enumeration. |
Auth | Auth | The Auth enumeration. |
Big | Big | The Big enumeration. |
Field | Field | The Field enumeration. |
Methods
| Method | Return type | Brief description |
|---|---|---|
get | Config | Returns a Config object. |
get | Fields | Returns a Fields object. |
new | Get | Returns a new Get object. |
new | Big | Returns a new Big object. |
new | Debug | Returns a new Debug object. |
new | Get | Returns a new Get object. |
new | Get | Returns a new Get object. |
new | Set | Returns a new Set object. |
new | User | Returns a new User object. |
Detailed documentation
getConfig()
getFields()
newAuthTypeResponse()
Returns a new GetAuthTypeResponse object. Use this object to create a response for the
getAuthType() function you implement in your script project.
Return
GetAuthTypeResponse — A new GetAuthTypeResponse object.
newBigQueryConfig()
Returns a new BigQueryConfig object. Use this object to create a response for the
getData() function you implement in your script project.
Return
BigQueryConfig — A new BigQueryConfig object.
newDebugError()
Returns a new DebugError object. Use this object to create debug errors.
Return
DebugError — A new DebugError object.
newGetDataResponse()
Returns a new GetDataResponse object. Use this object to create a response for the
getData() function you implement in your script project.
Return
GetDataResponse — A new GetDataResponse object.
newGetSchemaResponse()
Returns a new GetSchemaResponse object. Use this object to create a response for the
getSchema() function you implement in your script project.
Return
GetSchemaResponse — A new GetSchemaResponse object.
newSetCredentialsResponse()
Returns a new SetCredentialsResponse object. Use this object to create a response for
the setCredentials() function you implement in your script project.
Return
SetCredentialsResponse — A new SetCredentialsResponse object.