Skip to content

Make API key more easily available after creating a new account #19

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Gankra opened this issue Oct 28, 2014 · 6 comments
Closed

Make API key more easily available after creating a new account #19

Gankra opened this issue Oct 28, 2014 · 6 comments
Assignees
Labels
A-frontend 🐹 C-enhancement ✨ Category: Adding new behavior or a change to the way an existing feature works E-has-mentor E-help-wanted

Comments

@Gankra
Copy link
Contributor

Gankra commented Oct 28, 2014

Not very discoverable, especially since this is probably the first thing you're interested in getting after registering. Resetting it should definitely be in there, but that's certainly not where I would expect to go for "what is my API key".

Possible solution: redirect new logins and/or registrations to there.

@wycats
Copy link
Contributor

wycats commented Oct 28, 2014

@gankro agreed.

@wycats
Copy link
Contributor

wycats commented Oct 28, 2014

The CLI should also make it discoverable.

@alexcrichton
Copy link
Member

Right now you can type cargo login <token> at the CLI, but you can't discover your own token through the CLI b/c we require a github login (which cargo itself doesn't want to mess with)

@carols10cents carols10cents changed the title API key only being available in "Account Settings" is odd Make API key more easily available after creating a new account Aug 2, 2017
@locks locks self-assigned this Sep 6, 2019
@locks
Copy link
Contributor

locks commented Sep 12, 2019

What needs to happen to resolve this issue?

@carols10cents
Copy link
Member

What happens today when you're a new user of crates.io:

You visit crates.io and see this:

crates.io homepage

So you click "Log in with GitHub", do the oAuth dance, and you're taken... back to the homepage, only now your icon is in the upper right:

crates.io homepage but logged in

There's not really a call to action, you have to notice there's a little triangle next to your icon that opens this menu:

user menu open

and the menu item you want is "account settings", which is the crates.io/me page where you can verify your email and create API tokens:

account settings page

The smallest change is probably adding a notice at the top of the page that says something like "Welcome to crates.io! Visit account settings to verify your email address and create an API token!".

Ideally, we'd only show that if we just created an account rather than updating one in the NewUser create_or_update method. I think we can send that info to the frontend here from the backend controller action associated with /authorize.

Other changes I could see that seem more complex:

  • Always redirecting to /me after logging in (not sure if that's the best experience either)
  • Customizing the message shown based on whether the user needs to verify their email, create an API token, or both (account completion percentage sort of?)
  • Always showing a notice on every page until the user verifies their email and creates an API token, could be annoying

I'm open to thoughts based on what people think the best experience would be and what seems possible/easy to implement!

Mordorreal pushed a commit to Mordorreal/crates.io that referenced this issue Dec 14, 2019
- Add new types for flash message
- Show info type flash message after login via github
- Add missed tests

Small initial step to address rust-lang#19
@Turbo87 Turbo87 added C-enhancement ✨ Category: Adding new behavior or a change to the way an existing feature works and removed C-feature-request labels Feb 11, 2021
Turbo87 added a commit that referenced this issue Dec 8, 2022
This avoids broken development environments due to transitive dependencies. renovatebot will take care of regularly updating the lockfile and showing us incompatibilities in those transitive dependencies.
Turbo87 pushed a commit that referenced this issue Jan 4, 2023
@Turbo87
Copy link
Member

Turbo87 commented Jan 29, 2024

These days, cargo tells you to go to https://crates.io/me to create an API token. If you do that without being logged in it shows a page like this:

Bildschirmfoto 2024-01-29 um 10 48 40

If you press the "Login" button/link it will perform the login flow and afterwards direct you to the API tokens settings page where you can create your API token.

It seems to me like this covers most of the discoverability issues here. Let me know if you think that there is more that we can do :)

@Turbo87 Turbo87 closed this as completed Jan 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-frontend 🐹 C-enhancement ✨ Category: Adding new behavior or a change to the way an existing feature works E-has-mentor E-help-wanted
Projects
None yet
Development

No branches or pull requests

6 participants