Class: XingApi::User::School

Inherits:
Base
  • Object
show all
Defined in:
lib/xing_api/user/school.rb

Class Method Summary collapse

Methods inherited from Base

request, request_with_body

Class Method Details

.create(name, options = {}) ⇒ Object



4
5
6
# File 'lib/xing_api/user/school.rb', line 4

def self.create(name, options = {})
  request(:post, '/v1/users/me/educational_background/schools', { name: name }.merge(options))
end

.delete(school_id, options = {}) ⇒ Object



12
13
14
# File 'lib/xing_api/user/school.rb', line 12

def self.delete(school_id, options = {})
  request(:delete, "/v1/users/me/educational_background/schools/#{school_id}", options)
end

.primary_school(school_id, options = {}) ⇒ Object



16
17
18
# File 'lib/xing_api/user/school.rb', line 16

def self.primary_school(school_id, options = {})
  request(:put, '/v1/users/me/educational_background/schools', { school_id: school_id }.merge(options))
end

.update(school_id, options = {}) ⇒ Object



8
9
10
# File 'lib/xing_api/user/school.rb', line 8

def self.update(school_id, options = {})
  request(:put, "/v1/users/me/educational_background/schools/#{school_id}", options)
end