Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

gitlab

Package Overview
Dependencies
Maintainers
1
Versions
169
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gitlab

GitLab API Nodejs library.

  • 0.8.6
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
87K
decreased by-1.64%
Maintainers
1
Weekly downloads
 
Created
Source

node-gitlab

Build Status Dependency Status authors library users Total views Views in the last 24 hours Bitdeli Badge

NPM Badge

GitLab API Nodejs library. It wraps the HTTP api library described here.

Install

# Install from npm
npm install gitlab

Usage

Coffee-Script

# Connection
gitlab = new require('gitlab')
  url:   'http://example.com'
  token: 'abcdefghij123456'
  
# Listing users
gitlab.users.all (users) ->
  console.log "##{user.id}: #{user.email}, #{user.name}, #{user.created_at}" for user in users

# Listing projects
gitlab.projects.all (projects) ->
  for project in projects
    console.log "##{project.id}: #{project.name}, path: #{project.path}, default_branch: #{project.default_branch}, private: #{project.private}, owner: #{project.owner.name} (#{project.owner.email}), date: #{project.created_at}"

Javascript

// Connection
var gitlab = new require('gitlab')({
  url:   'http://example.com',
  token: 'abcdefghij123456'
});
  
// Listing users
gitlab.users.all(function(users) {
  for (var i = 0; i < users.length; i++) {
    console.log("#" + user.id + ": " + user.email + ", " + user.name + ", " + user.created_at));
  }
});

// Listing projects
gitlab.projects.all(function(projects) {
  for (var i = 0; i < projects.length; i++) {
    console.log("#" + project.id + ": " + project.name + ", path: " + project.path + ", default_branch: " + project.default_branch + ", private: " + project["private"] + ", owner: " + project.owner.name + " (" + project.owner.email + "), date: " + project.created_at);
  }
});

See Examples directory for more examples

Develop

Gitter chat

Edit the Coffee-Script files in src, then build them using cake build. Use cake watch to build files continuously while developing.

Contributors

License

MIT

Keywords

FAQs

Package last updated on 28 Apr 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc