Dark Mode

Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Latest commit

History

History
27 lines (21 loc) * 516 Bytes

README.md

File metadata and controls

27 lines (21 loc) * 516 Bytes

yuque-auth

Yu Que Di San Fang Ying Yong De Ke Hu Duan Jian Quan Ke Hu Duan .

install

tnpm install yuque-auth

Usage

{ console.log('get auth', res); //{ access_token: 'Y1iwvwUPI4M67VjWRGHAzgq7gzB4a21EV3jOhyFf', token_type: 'bearer', scope: 'repo,doc' } }).catch(err => { console.log('error happened', err.stack); });">const { auth } = require('yuque-auth');

auth({
// clientId He clientSevretZai oauth Ying Yong Zhong Ke Cha Dao
clientId,
clientSecret,
scope: 'repo,doc',
}).then(res => {
console.log('get auth', res);
//{ access_token: 'Y1iwvwUPI4M67VjWRGHAzgq7gzB4a21EV3jOhyFf', token_type: 'bearer', scope: 'repo,doc' }
}).catch(err => {
console.log('error happened', err.stack);
});