Hmmm, I'm having some trouble doing this. If I set the connection id directly like this then it throws an error: composio.exceptions.InvalidConnectedAccount: Invalid connected accounts found: [('GOOGLEDRIVE', 'ca_66ijRVZPelrW')]. This is the ID I took from the composio dashboard.
` toolset = ComposioToolSet(
api_key=api_key,
connected_account_ids={'GOOGLEDRIVE': "ca_66ijRVZPelrW"}
)
# Get the connected account ID
res = toolset.execute_action(
"GOOGLEDRIVE_DOWNLOAD_FILE",
params={
"file_id": "17l9yE2dRZe-LAbm3B4id7Mn9SDOUC9Pe"
}
)`
However this approach.
` entity_id = "67f520e362d29ee4a1d79c92"
toolset = ComposioToolSet(entity_id=entity_id, api_key=api_key)
conns = toolset.get_connected_accounts()
conns = [c for c in conns if c.appName == 'googledrive']
toolset = ComposioToolSet(
api_key=api_key,
connected_account_ids={'GOOGLEDRIVE': conns[0].id}
)
res = toolset.execute_action(
"GOOGLEDRIVE_DOWNLOAD_FILE",
params={
"file_id": "17l9yE2dRZe-LAbm3B4id7Mn9SDOUC9Pe"
}
)`
Then throws an error in execute_action. composio.exceptions.ConnectedAccountNotFoundError: No connected account found for app GOOGLEDRIVE; Run composio add googledrive to fix this