From c9b06742461c95c036ed1041817d56e4ded1ab61 Mon Sep 17 00:00:00 2001 From: Josh McVey Date: Wed, 16 Oct 2024 08:39:17 -0500 Subject: [PATCH] provide Auth0 consent instructions --- opentrons-ai-client/README.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/opentrons-ai-client/README.md b/opentrons-ai-client/README.md index d6a2b9a697a..14a9d25f309 100644 --- a/opentrons-ai-client/README.md +++ b/opentrons-ai-client/README.md @@ -26,6 +26,23 @@ make teardown-js && make setup-js make -C opentrons-ai-client dev ``` +## Auth0 + +[Auth0 requires consent in the local application.](https://auth0.com/docs/get-started/applications/confidential-and-public-applications/user-consent-and-third-party-applications#skip-consent-for-first-party-applications) + +### Allow consent in the local application + +Alter the `authorizationParams` in `src/main.tsx`, provide consent, then remove the change. Once you provide consent in the local application, you will not be prompted for consent again. The consent is stored in Auth0. + +```ts +// src/main.tsx +authorizationParams={{ + redirect_uri: window.location.origin, + prompt: 'consent', + audience: 'sandbox-ai-api', + }} +``` + ## Stack and structure The UI stack is built using: