Google Data Studio - 我可以在创建连接器视图时验证配置参数吗?

Google Data Studio - Can I validate config params on create connector view?

目前我正在 getData 函数中验证我的连接器配置,但它不是很用户友好。


RequestParamsValidator.prototype.validate = function validate(request) {
  if (!request.configParams || !request.configParams.account_id) {
    ErrorUtils.throwUserError('Account id is required. Please check connector config and try again.');
  }
};

您知道是否有任何方法(可能未记录)检查例如如果字段的值为空并且阻止用户创建连接器?

我检查了这个参考,但没有关于验证的内容: https://developers.google.com/apps-script/reference/data-studio/text-input

您可以验证getSchema开头的配置。这将防止用户越过配置屏幕。这是 Kaggle connector.

中的示例实现