Module: DBLista::User::Verification
- Included in:
- Client
- Defined in:
- lib/dblista/user/verification.rb
Overview
User client - verification (only for staff)
Instance Method Summary collapse
-
#approve(id, reason = 'Brak powodu') ⇒ Boolean
Approves specified bot.
-
#reject(id, reason = 'Brak powodu') ⇒ Boolean
Rejects specified bot.
-
#set_pending(id) ⇒ Boolean
Sets specified bot verification status to pending.
Instance Method Details
#approve(id, reason = 'Brak powodu') ⇒ Boolean
Approves specified bot
13 14 15 16 17 18 |
# File 'lib/dblista/user/verification.rb', line 13 def approve(id, reason = 'Brak powodu') DBLista._validate_id id DBLista._post("/bots/verify/#{id}/approve?reason=#{CGI.escape reason}", nil, @token) true end |
#reject(id, reason = 'Brak powodu') ⇒ Boolean
Rejects specified bot
25 26 27 28 29 30 |
# File 'lib/dblista/user/verification.rb', line 25 def reject(id, reason = 'Brak powodu') DBLista._validate_id id DBLista._post("/bots/verify/#{id}/reject?reason=#{CGI.escape reason}", nil, @token) true end |
#set_pending(id) ⇒ Boolean
Sets specified bot verification status to pending
36 37 38 39 40 41 |
# File 'lib/dblista/user/verification.rb', line 36 def set_pending(id) DBLista._validate_id id DBLista._post("/bots/#{id}/set-pending", nil, @token) true end |