Account Config extensions

Account Connector Config

Each Domo Dataset that pulls data into Vault must have a stream, which stores the configuration information related to which data is exctracted from a datasource. Each stream has an associated account which stores the source data’s authentication information.

Because each datasource may have different authentication parameters, there may be multiple versions of the same account type (with different credentials) or multiple account types deployed within a domo instance if the user is extracting data from multiple systems.

Account’s can be configured such that certain fields are designated as encrypted fields, and the user will never be able to see the encrypted values EXCEPT in Domo’s Jupyter Notebook integration.


source

DomoAccount_Config

 DomoAccount_Config (data_provider_type:str, is_oauth:bool, raw:dict=None,
                     parent:Any=None)

DomoAccount Config abstract base class


source

DomoAccount_NoConfig_OAuth

 DomoAccount_NoConfig_OAuth (data_provider_type:str=None,
                             is_oauth:bool=True, raw:dict=None,
                             parent:Any=None)

source

AccountConfig_UsesOauth

 AccountConfig_UsesOauth (data_provider_type)

base exception

try:
    dc = DomoAccount_NoConfig_OAuth._from_json(obj = {}, 
                                        data_provider_type='abc',
                                        parent = {}
                                        )

    dc

except dmde.DomoError as e:
    print(e)
🛑  AccountConfig_UsesOauth 🛑 - function: data provider type abc uses OAuth and therefore wouldn't return a Config object

source

DomoAccount_NoConfig

 DomoAccount_NoConfig (data_provider_type:str, is_oauth:bool=False,
                       raw:dict=None, parent:Any=None)

source

AccountConfig_ProviderTypeNotDefined

 AccountConfig_ProviderTypeNotDefined (data_provider_type)

base exception

try:
    dnc = DomoAccount_NoConfig._from_json(
        parent = None,
        obj = {},
        data_provider_type= 'ABC'
    )

    dnc

except dmde.DomoError as e: 
    print(e)
🛑  AccountConfig_ProviderTypeNotDefined 🛑 - function: data provider type ABC not defined yet. Extend the AccountConfig class

Utility Connector


source

DomoAccount_Config_AbstractCredential

 DomoAccount_Config_AbstractCredential (data_provider_type:str='abstract-
                                        credential-store',
                                        is_oauth:bool=False,
                                        raw:dict=None, parent:Any=None,
                                        credentials:dict=None)
DomoAccount_Config_AbstractCredential._from_json(
    obj = {"credentials" : 'hello world'}
)
DomoAccount_Config_AbstractCredential(data_provider_type='abstract-credential-store', is_oauth=False, credentials='hello world')

source

DomoAccount_Config_DomoAccessToken

 DomoAccount_Config_DomoAccessToken (data_provider_type:str='domo-access-
                                     token', is_oauth:bool=False,
                                     raw:dict=None, parent:Any=None,
                                     domo_access_token:str=None,
                                     username:str=None, password:str=None)

source

DomoAccount_Config_DatasetCopy

 DomoAccount_Config_DatasetCopy (data_provider_type:str,
                                 is_oauth:bool=False, raw:dict=None,
                                 parent:Any=None, domo_instance:str=None,
                                 access_token:str=None)
DomoAccount_Config_DatasetCopy._from_json(
    domo_instance='domo',
    obj =  {"accessToken" : '123'}
)
DomoAccount_Config_DatasetCopy(data_provider_type='dataset-copy', is_oauth=False, domo_instance=None)
DomoAccount_Config_DomoAccessToken._from_json(
    domo_instance='domo',
    obj =  {"domoAccessToken" : '123', 'username' : 'jae'}
)
DomoAccount_Config_DomoAccessToken(data_provider_type='domo-access-token', is_oauth=None, username='jae')

source

DomoAccount_Config_Governance

 DomoAccount_Config_Governance (data_provider_type:str='domo-
                                governance-d14c2fef-49a8-4898-8ddd-
                                f64998005600', is_oauth:bool=False,
                                raw:dict=None, parent:Any=None,
                                domo_instance:str=None,
                                access_token:str=None)
DomoAccount_Config_Governance._from_json(domo_instance="domo", obj={"apikey": 123})
DomoAccount_Config_Governance(data_provider_type='domo-governance-d14c2fef-49a8-4898-8ddd-f64998005600', is_oauth=False, domo_instance=None)

Amazon Connector


source

DomoAccount_Config_AmazonS3

 DomoAccount_Config_AmazonS3 (data_provider_type:str='amazon-s3',
                              is_oauth:bool=False, raw:dict=None,
                              parent:Any=None, access_key:str=None,
                              secret_key:str=None, bucket:str=None,
                              region:str='us-west-2')
DomoAccount_Config_AmazonS3._from_json(
    obj = {"access_key" : 'abc'}
)
DomoAccount_Config_AmazonS3(data_provider_type='amazon-s3', is_oauth=False, access_key=None, bucket=None, region=None)

source

DomoAccount_Config_AmazonS3Advanced

 DomoAccount_Config_AmazonS3Advanced
                                      (data_provider_type:str='amazons3-
                                      advanced', is_oauth:bool=False,
                                      raw:dict=None, parent:Any=None,
                                      access_key:str=None,
                                      secret_key:str=None,
                                      bucket:str=None, region:str='us-
                                      west-2')

source

DomoAccount_Config_AwsAthena

 DomoAccount_Config_AwsAthena (data_provider_type:str='aws-athena',
                               is_oauth:bool=False, raw:dict=None,
                               parent:Any=None, access_key:str=None,
                               secret_key:str=None, bucket:str=None,
                               workgroup:str=None, region:str='us-west-2')
DomoAccount_Config_AwsAthena._from_json(
    obj = {'abc' : 'abc'}
)
DomoAccount_Config_AwsAthena(data_provider_type='aws-athena', is_oauth=False, access_key=None, bucket=None, workgroup=None, region=None)

source

DomoAccount_Config_HighBandwidthConnector

 DomoAccount_Config_HighBandwidthConnector
                                            (data_provider_type:str='amazo
                                            n-athena-high-bandwidth',
                                            is_oauth:bool=False,
                                            raw:dict=None,
                                            parent:Any=None,
                                            access_key:str=None,
                                            secret_key:str=None,
                                            bucket:str=None,
                                            region:str='us-west-2')

this connector is not enabled by default contact your CSM / AE

sample domoaccount_config_amazons3

DomoAccount_Config_AmazonS3._from_json(
    obj = {'abc' : 'abc'}
)
DomoAccount_Config_AmazonS3(data_provider_type='amazon-s3', is_oauth=False, access_key=None, bucket=None, region=None)

Snowflake


source

DomoAccount_Config_Snowflake

 DomoAccount_Config_Snowflake (data_provider_type:str='snowflake',
                               is_oauth:bool=False, raw:dict=None,
                               parent:Any=None, account:str=None,
                               username:str=None, password:str=None,
                               role:str=None)

this connector is not enabled by default contact your CSM / AE

DomoAccount_Config_Snowflake._from_json(
    obj = {"account": "abc", "username": "doge", "password": "test_me", "role": None}
)
DomoAccount_Config_Snowflake(data_provider_type='snowflake', is_oauth=False, account='abc', username='doge', role=None)

source

DomoAccount_Config_SnowflakeUnload_V2

 DomoAccount_Config_SnowflakeUnload_V2 (data_provider_type:str='snowflake-
                                        unload-v2', is_oauth:bool=False,
                                        raw:dict=None, parent:Any=None,
                                        account:str=None,
                                        username:str=None,
                                        password:str=None,
                                        access_key:str=None,
                                        secret_key:str=None,
                                        region:str=None, bucket:str=None,
                                        role:str=None)

this connector is not enabled by default contact your CSM / AE

DomoAccount_Config_SnowflakeUnload_V2._from_json(
    obj = {"account": "abc", "username": "doge", "password": "test_me", "role": None}
)
DomoAccount_Config_SnowflakeUnload_V2(data_provider_type='snowflake-unload-v2', is_oauth=False, account='abc', username='doge', access_key=None, region=None, bucket=None, role=None)

source

DomoAccount_Config_SnowflakeUnloadAdvancedPartition

 DomoAccount_Config_SnowflakeUnloadAdvancedPartition
                                                      (data_provider_type:
                                                      str='snowflake-
                                                      internal-unload-
                                                      advanced-partition',
                                                      is_oauth:bool=False,
                                                      raw:dict=None,
                                                      parent:Any=None,
                                                      password:str=None,
                                                      account:str=None,
                                                      username:str=None,
                                                      role:str=None)
DomoAccount_Config_SnowflakeUnloadAdvancedPartition._from_json(
    obj = {"account": "abc", "username": "doge", "password": "test_me", "role": None}
)
DomoAccount_Config_SnowflakeUnloadAdvancedPartition(data_provider_type='snowflake-internal-unload-advanced-partition', is_oauth=False, account='abc', username='doge', role=None)

source

DomoAccount_Config_SnowflakeWriteback

 DomoAccount_Config_SnowflakeWriteback (data_provider_type:str='snowflake-
                                        writeback', is_oauth:bool=False,
                                        raw:dict=None, parent:Any=None,
                                        domo_client_secret:str=None,
                                        domo_client_id:str=None,
                                        account:str=None,
                                        password:str=None,
                                        username:str=None)

source

DomoAccount_Config_SnowflakeUnload

 DomoAccount_Config_SnowflakeUnload (data_provider_type:str='snowflake-
                                     unload', is_oauth:bool=False,
                                     raw:dict=None, parent:Any=None,
                                     secret_key:str=None,
                                     access_key:str=None,
                                     account:str=None, password:str=None,
                                     username:str=None, bucket:str=None)

source

DomoAccount_Config_SnowflakeFederated

 DomoAccount_Config_SnowflakeFederated (data_provider_type:str='snowflake-
                                        federated', is_oauth:bool=False,
                                        raw:dict=None, parent:Any=None,
                                        password:str=None, host:str=None,
                                        warehouse:str=None,
                                        username:str=None, port:str=None,
                                        role:str=None)

source

DomoAccount_Config_SnowflakeInternalUnload

 DomoAccount_Config_SnowflakeInternalUnload
                                             (data_provider_type:str='snow
                                             flake-internal-unload',
                                             is_oauth:bool=False,
                                             raw:dict=None,
                                             parent:Any=None,
                                             password:str=None,
                                             account:str=None,
                                             username:str=None,
                                             role:str=None)

source

DomoAccount_Config_SnowflakeKeyPairAuthentication

 DomoAccount_Config_SnowflakeKeyPairAuthentication
                                                    (data_provider_type:st
                                                    r='snowflakekeypairaut
                                                    hentication',
                                                    is_oauth:bool=False,
                                                    raw:dict=None,
                                                    parent:Any=None,
                                                    private_key:str=None,
                                                    account:str=None,
                                                    passphrase:str=None,
                                                    username:str=None,
                                                    role:str=None)

ConfigEnum


source

AccountConfig

 AccountConfig (value, names=None, module=None, qualname=None, type=None,
                start=1)

Enum provides appropriate spelling for data_provider_type and config object. The name of the enum should correspond with the data_provider_type with hyphens replaced with underscores.


Enum.generate_alt_search_str

 Enum.generate_alt_search_str (raw_value)
[member.name for member in AccountConfig]
['abstract_credential_store',
 'dataset_copy',
 'domo_access_token',
 'domo_governance_d14c2fef_49a8_4898_8ddd_f64998005600',
 'aws_athena',
 'amazon_athena_high_bandwidth',
 'amazon_s3',
 'amazons3_advanced',
 'snowflake',
 'snowflake_unload',
 'snowflake_unload_v2',
 'snowflake_internal_unload_advanced_partition',
 'snowflake_internal_unload',
 'snowflakekeypairauthentication',
 'snowflake_writeback',
 'snowflake_federated',
 '_uses_oauth',
 '_config_oauth',
 '_config_notdefined']

the _missing_ dunder method will return the results of an alternative search if it can match

domo_config = AccountConfig("ABSTRACT-CREDENTIAL-STORE").value
domo_config._from_json( 
    obj = {"credentials" : "abc123"})
DomoAccount_Config_AbstractCredential(data_provider_type='abstract-credential-store', is_oauth=False, credentials='abc123')

the _missing_ dunder method will also check if the account type uses OAauth in which case it raises an Error which can be captured and dealth with in class methods downstream

AccountConfig("google-spreadsheets").value
🛑  AccountConfig_UsesOauth 🛑 - function: data provider type google-spreadsheets uses OAuth and therefore wouldn't return a Config object
__main__.DomoAccount_NoConfig_OAuth

the _missing_ dunder method will throw an error if the config has not been accounted

AccountConfig("abc").value
🛑  AccountConfig_ProviderTypeNotDefined 🛑 - function: data provider type abc not defined yet. Extend the AccountConfig class
__main__.DomoAccount_NoConfig