apify-cli icon indicating copy to clipboard operation
apify-cli copied to clipboard

Apify CLI `whoami`

Open netmilk opened this issue 1 year ago • 2 comments

I'm working with multiple Apify accounts. I'd appreciate to know what user I'm logged in as in the CLI.

To find it out I need to do:

$ cat ~/.apify/auth.json | jq -r .username
netmilk

A simple whoami would be convenient.

$ apify whoami
netmilk

netmilk avatar Nov 19 '24 08:11 netmilk

FYI apify info will give you both the user name and user id

➜  store-website-content-crawler git:(main) ✗ npx apify-cli@beta info
username: adamek
userId: xxxxx

B4nan avatar Nov 19 '24 09:11 B4nan

This also opens up the fact our current auth system is really meant for 1 user only, while people may use multiple accounts (think org accounts for instance). We probs should reconsider it

vladfrangu avatar Nov 19 '24 11:11 vladfrangu

Let's close this one, the apify info seems enough and we have other issues about the multi user support

B4nan avatar Dec 04 '25 09:12 B4nan