Class: DogapiDemo::V1::ScreenboardService
Constant Summary
collapse
- API_VERSION =
"v1"
Instance Method Summary
collapse
Methods inherited from APIService
#connect, #initialize, #request, #suppress_error_if_silent
Instance Method Details
#create_screenboard(description) ⇒ Object
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
# File 'lib/dogapi-demo/v1/screenboard.rb', line 10
def create_screenboard(description)
begin
params = {
:api_key => @api_key,
:application_key => @application_key
}
body = description
request(Net::HTTP::Post, "/api/#{API_VERSION}/screen", params, description, true)
rescue Exception => e
suppress_error_if_silent e
end
end
|
#delete_screenboard(board_id) ⇒ Object
68
69
70
71
72
73
74
75
76
77
78
79
|
# File 'lib/dogapi-demo/v1/screenboard.rb', line 68
def delete_screenboard(board_id)
begin
params = {
:api_key => @api_key,
:application_key => @application_key
}
request(Net::HTTP::Delete, "/api/#{API_VERSION}/screen/#{board_id}", params, nil, false)
rescue Exception => e
suppress_error_if_silent e
end
end
|
#get_all_screenboards ⇒ Object
55
56
57
58
59
60
61
62
63
64
65
66
|
# File 'lib/dogapi-demo/v1/screenboard.rb', line 55
def get_all_screenboards()
begin
params = {
:api_key => @api_key,
:application_key => @application_key
}
request(Net::HTTP::Get, "/api/#{API_VERSION}/screen", params, nil, false)
rescue Exception => e
suppress_error_if_silent e
end
end
|
#get_screenboard(board_id) ⇒ Object
42
43
44
45
46
47
48
49
50
51
52
53
|
# File 'lib/dogapi-demo/v1/screenboard.rb', line 42
def get_screenboard(board_id)
begin
params = {
:api_key => @api_key,
:application_key => @application_key
}
request(Net::HTTP::Get, "/api/#{API_VERSION}/screen/#{board_id}", params, nil, false)
rescue Exception => e
suppress_error_if_silent e
end
end
|
#revoke_screenboard(board_id) ⇒ Object
94
95
96
97
98
99
100
101
102
103
104
105
|
# File 'lib/dogapi-demo/v1/screenboard.rb', line 94
def revoke_screenboard(board_id)
begin
params = {
:api_key => @api_key,
:application_key => @application_key
}
request(Net::HTTP::Delete, "/api/#{API_VERSION}/screen/share/#{board_id}", params, nil, false)
rescue Exception => e
suppress_error_if_silent e
end
end
|
#share_screenboard(board_id) ⇒ Object
81
82
83
84
85
86
87
88
89
90
91
92
|
# File 'lib/dogapi-demo/v1/screenboard.rb', line 81
def share_screenboard(board_id)
begin
params = {
:api_key => @api_key,
:application_key => @application_key
}
request(Net::HTTP::Get, "/api/#{API_VERSION}/screen/share/#{board_id}", params, nil, false)
rescue Exception => e
suppress_error_if_silent e
end
end
|
#update_screenboard(board_id, description) ⇒ Object
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
# File 'lib/dogapi-demo/v1/screenboard.rb', line 26
def update_screenboard(board_id, description)
begin
params = {
:api_key => @api_key,
:application_key => @application_key
}
body = description
request(Net::HTTP::Put, "/api/#{API_VERSION}/screen/#{board_id}", params, body, true)
rescue Exception => e
suppress_error_if_silent e
end
end
|