Accessing the individual's username from Python recipe?
![info-rchitect](https://us.v-cdn.net/6038231/uploads/lithium_attachments/n9089iA7C08C68990A5113.png)
info-rchitect
Registered Posts: 194 ✭✭✭✭✭✭
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
!