Looker Embedded User Authentication Fails with Gemini Conversational Data Analytics

we are integrating Looker with Gemini Data Analytics and running into an issue that happens only for embedded Looker users—standard Looker users work fine.
Here’s the simplified code snippet:

access_token = sdk.login_user(user_id=user_id).access_token

looker_credentials = geminidataanalytics.Credentials(
    oauth=geminidataanalytics.OAuthCredentials(
        token=geminidataanalytics.OAuthCredentials.TokenBased(
            access_token=access_token
        )
    )
)

conversation_reference = geminidataanalytics.ConversationReference(
    conversation=data_chat_client.conversation_path(
        billing_project, location, conversation_id
    ),
    data_agent_context=geminidataanalytics.DataAgentContext(
        data_agent=data_chat_client.data_agent_path(
            billing_project, location, data_agent_id
        ),
        credentials=looker_credentials
    ),
)

When I use an embedded Looker user, the chat request fails with:

NotFound: 404 SCHEMA_RESOLUTION: failed due to NOT_FOUND error
...

If I run the exact same code with a standard Looker user, it works without errors.
Could you advise on:

  1. Do we need to provide any roles or specific permission that are specific to embed users ?

Please let me know if more details (logs, existing permissions.., etc.) would help.
Thanks in advance,

@Vamsi_Panchada have you found a solution for this issue?

@Pawel_Malon - it does looks like this is the issue at google system so at a moment the feature to auth with embed user is not available. But there is a workaround which is not optimal, like you can create and delete a standard user using looker_sdk on the fly. It works but it’s optimal ..

1 Like