aaron-wolmutt commented on issue #57966: URL: https://github.com/apache/airflow/issues/57966#issuecomment-3549513848
> There is an endpoint to return menus allowed with the UI disabling them menus not accessible in the UI. Perhaps there could be new API to dump the permissions relevant to UI like create a dagrun to disable/enable trigger button, delete a dagrun to enable/disable delete dagrun button etc. > > https://github.com/apache/airflow/blob/main/airflow-core/src/airflow/api_fastapi/core_api/routes/ui/auth.py > > [airflow/airflow-core/src/airflow/ui/src/layouts/Nav/Nav.tsx](https://github.com/apache/airflow/blob/efa1084a4e0197c6a767b520df2d54136c955566/airflow-core/src/airflow/ui/src/layouts/Nav/Nav.tsx#L163-L168) > > Lines 163 to 168 in [efa1084](/apache/airflow/commit/efa1084a4e0197c6a767b520df2d54136c955566) > > <NavButton > disabled={!authLinks?.authorized_menu_items.includes("Dags")} > icon={DagIcon} > title={translate("nav.dags")} > to="dags" > /> Hey guys, check out this [PR](https://github.com/apache/airflow/pull/58292/files) I've developed a private api endpoint /ui/auth/me to get the current users roles when they are logged in. It's integrated with SimpleAuth and FabAuth. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
