Accessing the individual's username from Python recipe?
info-rchitect
Registered Posts: 184 ✭✭✭✭✭✭
Hi,
I am trying to access the individual user's username in a Python recipe.
username = getpass.getuser()
It returns an admin type of username. How can I access the correct username of the actual individual?
Operating system used: Windows 10
Tagged:
Best Answer
-
import dataiku
client = dataiku.api_client()
username = client.get_auth_info()['authIdentifier']
Answers
-
CoreyS Dataiker Alumni, Dataiku DSS Core Designer, Dataiku DSS Core Concepts, Registered Posts: 1,150 ✭✭✭✭✭✭✭✭✭
Thank you for sharing your solution with the community @info-rchitect
!