Sandbox Routes

token_auth = dmda.DomoTokenAuth(
    domo_instance=os.environ['DOMO_INSTANCE'],
    domo_access_token=os.environ["DOMO_ACCESS_TOKEN"],
)

source

get_is_allow_same_instance_promotion_enabled

 get_is_allow_same_instance_promotion_enabled
                                               (auth:domolibrary.client.Do
                                               moAuth.DomoAuth, session:ht
                                               tpx.AsyncClient=None,
                                               return_raw:bool=False, debu
                                               g_num_stacks_to_drop:int=1,
                                               debug_api:bool=False,
                                               parent_class:str=None)

source

Sandbox_GET_Error

 Sandbox_GET_Error (res:Any, entity_id:str=None,
                    is_exception_not_error:bool=False, message=None)

base exception

# import domolibrary.client.DomoAuth as dmda


await get_is_allow_same_instance_promotion_enabled(auth=token_auth, debug_api=False)
ResponseGetData(status=200, response={'name': 'allow_same_instance_promotion', 'is_enabled': True}, is_success=True, parent_class=None)

source

toggle_allow_same_instance_promotion

 toggle_allow_same_instance_promotion (is_enabled:bool,
                                       auth:domolibrary.client.DomoAuth.Do
                                       moAuth,
                                       session:httpx.AsyncClient=None,
                                       debug_num_stacks_to_drop:int=1,
                                       debug_api:bool=False,
                                       parent_class:str=None)

source

Sandbox_ToggleSameInstancePromotion_Error

 Sandbox_ToggleSameInstancePromotion_Error
                                            (res:domolibrary.client.Respon
                                            seGetData.ResponseGetData,
                                            message:str=None)

base exception

# import domolibrary.client.DomoAuth as dmda

token_auth = dmda.DomoTokenAuth(
    domo_instance=os.environ['DOMO_INSTANCE'],
    domo_access_token=os.environ["DOMO_ACCESS_TOKEN"],
)

await toggle_allow_same_instance_promotion(
    is_enabled=True, auth=token_auth, debug_api=False
)
ResponseGetData(status=200, response={'allowSelfPromotion': True, 'requireApprovals': False, 'domain': 'domo-community.domo.com'}, is_success=True, parent_class=None)

source

get_shared_repos

 get_shared_repos (auth:domolibrary.client.DomoAuth.DomoAuth,
                   session:httpx.AsyncClient=None, return_raw:bool=False,
                   parent_class:str=None, debug_api:bool=False,
                   debug_num_stacks_to_drop:bool=False)

Sample of getting shared repos

# import domolibrary.client.DomoAuth as dmda

token_auth = dmda.DomoTokenAuth(
    domo_instance=os.environ['DOMO_INSTANCE'],
    domo_access_token=os.environ["DOMO_ACCESS_TOKEN"],
)


pd.DataFrame((await get_shared_repos(auth=token_auth,debug_api = False)).response[0:5])
id domain name accessCount type repositoryContent userId created updated seeded lastCommit permission
0 d3387e59-4672-4495-a428-535c18264ca6 domo-community.domo.com TestDash 0 page {'pageIds': [1720579712, 1715703200, 112967236... 1728973208 2024-07-26T12:09:45.353Z 2024-07-26T12:09:45.353Z False {'id': 'ae1a5534-35b5-4110-8a53-1d10fc0e16ab',... OWNER
1 abd4cb2b-ec72-4373-a471-2a04db500713 domo-community.domo.com Landing Page_PROD 1 dataflow {'pageIds': [], 'viewIds': [], 'dataflowIds': ... 1893952720 2023-06-15T21:09:00.244Z 2023-06-15T21:09:00.244Z False {'id': 'bc2b2d41-f1b8-4eb8-93f6-ecdf3074c00a',... OWNER
2 bc9b553c-ea02-4fce-ba63-2a4a63b455ef domo-community.domo.com Landing Page_QA 1 dataflow {'pageIds': [], 'viewIds': [], 'dataflowIds': ... 1893952720 2023-06-15T21:11:39.941Z 2023-06-15T21:11:39.941Z False {'id': '7823a38c-55f6-4df8-a068-0ee892e18127',... OWNER
3 0c6fd62b-6c27-4397-b487-55d4e0179d69 domo-community.domo.com Domo Variables Use Cases 2 page {'pageIds': [1880852133], 'viewIds': [], 'data... 805381129 2022-11-30T22:58:54.099Z 2022-11-30T22:58:54.099Z False {'id': '55cc1ea3-43e5-4e17-a450-87030287287d',... OWNER

source

get_repo_from_id

 get_repo_from_id (auth:domolibrary.client.DomoAuth.DomoAuth,
                   repository_id:str, debug_api:bool=False,
                   debug_num_stacks_to_drop:int=1, parent_class:str=None,
                   session:httpx.AsyncClient=None)
res = await get_shared_repos(auth=token_auth)


(await get_repo_from_id(
    auth=token_auth, repository_id=res.response[0]["id"]
)).response
{'id': 'd3387e59-4672-4495-a428-535c18264ca6',
 'domain': 'domo-community.domo.com',
 'name': 'TestDash',
 'accessCount': 0,
 'type': 'page',
 'repositoryContent': {'pageIds': [1720579712,
   1715703200,
   1129672369,
   2014015212,
   180062981],
  'viewIds': [],
  'dataflowIds': [],
  'streamIds': [],
  'cardIds': [],
  'dataAppIds': []},
 'userId': 1728973208,
 'created': '2024-07-26T12:09:45.353Z',
 'updated': '2024-07-26T12:09:45.353Z',
 'seeded': False,
 'lastCommit': {'id': 'ae1a5534-35b5-4110-8a53-1d10fc0e16ab',
  'repositoryId': 'd3387e59-4672-4495-a428-535c18264ca6',
  'commitName': 'v1',
  'hidden': False,
  'summary': 'Initial commit',
  'started': '2024-07-26T12:09:47.088Z',
  'completed': '2024-07-26T12:10:03.682Z',
  'status': 'COMPLETED',
  'pusherEventId': '8e9b071b-46fb-45c5-aabc-37d9a7fee91b'},
 'deployments': [],
 'permission': 'OWNER'}