github-username
Get a GitHub username from an email address
Last updated 9 years ago by sindresorhus .
MIT · Repository · Bugs · Original npm
$ cnpm install github-username 
SYNC missed versions from official npm registry.

github-username Build Status

Get a GitHub username from an email address

Install

$ npm install github-username

Usage

const githubUsername = require('github-username');

(async () => {
	console.log(await githubUsername('sindresorhus@gmail.com'));
	//=> 'sindresorhus'
})();

API

githubUsername(email, [token])

Returns a Promise<string> with the username.

email

Type: string

Email address for the user of whom you want the username.

token

Type: string

GitHub personal access token.

Related

License

MIT © Sindre Sorhus

Current Tags

  • 5.0.1                                ...           latest (6 years ago)

3 Versions

  • 2.1.0                                ...           10 years ago
  • 5.0.1                                ...           6 years ago
  • 3.0.0                                ...           9 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (1)
Dev Dependencies (2)
Dependents (0)
None

Copyright 2013 - present © cnpmjs.org