Project

cliskip2

0.0
No commit activity in last 3 years
No release in over 3 years
A Ruby wrapper for the SKIP2 REST APIs
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

Runtime

~> 1.8.1
= 0.4.6
~> 0.1.8
 Project Readme

Dependency Status

cliskip2

A Ruby wrapper for the SKIP2 REST APIs

[Important] It is not maintained now.

Installation

gem install cliskip2

Configration

Cliskip2.configure do |config|
  config.endpoint = 'http://localhost:3000'
  config.consumer_key = YOUR_CONSUMER_KEY
  config.consumer_secret = YOUR_CONSUMER_SECRET
  config.xauth_username = SKIP2_ADMIN_USER_NAME
  config.xauth_password = SKIP2_ADMIN_USER_PASSWORD
end

Examples

get the authorized user

client = Cliskip2::Client.new
client.current_user

create new user

client = Cliskip2::Client.new
client.create_user :user => {:name => 'hoge', :email => 'hoge@hoge.com'}

get the user by email

client = Cliskip2::Client.new
client.get_user :email => 'hoge@hoge.com'

update the user by email

client = Cliskip2::Client.new
client.update_user :user => {:name => 'foobar', :email => 'hoge@hoge.com'}

update the email by params_email

client = Cliskip2::Client.new
client.update_email 'before@hoge.com', 'after@hoge.com'

delete the user by email

client = Cliskip2::Client.new
client.delete_user :user => {:email => 'hoge@hoge.com'}

search communities by the community-name

client = Cliskip2::Client.new
client.search_communities({:search => {:name => 'I love ruby'} })

get a community member

client = Cliskip2::Client.new
client.get_community_member(community, {:email => 'hoge@hoge.com'})

join new member to the community

client = Cliskip2::Client.new
community = client.search_communities({:search => {:name => 'I love ruby'} }).first
user = client.get_user :email => 'hoge@hoge.com'
client.join_community(community, user)

leave the member from the community

client = Cliskip2::Client.new
community = client.search_communities({:search => {:name => 'I love ruby'} }).first
member = client.get_community_member(community, {:email => 'hoge@hoge.com'})
client.leave_community(community, member)

Update rubygems

vi lib/cliskip2/version.rb bundle exec rake build bundle exec rake release