@creamery/gitlabclient
A simply gitlab client
Last updated 3 years ago by creamidea .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @creamery/gitlabclient 
SYNC missed versions from official npm registry.

@creamery/gitlabclient

A simple gitlab client

But now, it should be used with middleware like koa-session.

Usage

const GitlabClient = require('@creamery/gitlabclient')

const gitlabClient = new GitlabClient({
  baseUrl,
  appId,
  appSecret,
  [oauthPath],
  [tokenPath],
  [redirectURI],
  [apiPath],
  [scope]
})

...

app.use(async (ctx, next) => {
  const token = ctx.session.accessToken
  try {
    const user = await gitlabClient.request({ path: '/user' }, token)
  } catch (err) {
    console.log(err)
  }
  ...
})

Current Tags

  • 1.1.1                                ...           latest (3 years ago)

3 Versions

  • 1.1.1                                ...           3 years ago
  • 1.1.0                                ...           3 years ago
  • 1.0.0                                ...           3 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 6
Last Day 0
Last Week 4
Last Month 3
Dependencies (2)
Dev Dependencies (7)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |