1.0.9 • Published 2 years ago

@msg-team/gauth-node v1.0.9

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

📚 Description

GAuth를 더 편하게 이용할 수 있도록 node 버전으로 만들어진 라이브러리입니다.

⚡ Requirements

  • axios

🛠️ Installation

// npm
> npm i @msg-team/gauth-node

// yarn
> yarn add @msg-team/gauth-node

🙋 How to use

code 발급

import Gauth from '@msg-team/gauth-node'

const result = await Gauth.issueCode({ email: 's12345', password: '1234' })

// { code: string }
console.log(result)

token 발급

import Gauth from '@msg-team/gauth-node'

const result = await Gauth.issueToken({
  code: 'string',
  clientId: 'string',
  redirectUri: 'string',
  clientSecret: 'string',
})

// { accessToken: string, refreshToken: string }
console.log(result)

token 재발급

import Gauth from '@msg-team/gauth-node'

const result = await Gauth.reissueToken({
  refreshToken: 'string',
})

// { accessToken: string, refreshToken: string }
console.log(result)

유저 정보 가져오기

import Gauth from '@msg-team/gauth-node'

const result = await Gauth.getUser({
  accessToken: 'string',
})

// { accessToken: string, refreshToken: string }
console.log(result)
1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago