Module: ConnpassApiV2::Client::EventMethods
- Included in:
- ConnpassApiV2::Client
- Defined in:
- lib/connpass_api_v2/client/event_methods.rb
Overview
connpass event endpoints (/api/v2/events
)
Instance Method Summary collapse
-
#get_event_presentations(event_id, start: nil, count: nil) ⇒ ConnpassApiV2::Response
Get list of presentations submitted to the event.
-
#get_events(event_id: nil, keyword: nil, keyword_or: nil, ym: nil, ymd: nil, nickname: nil, owner_nickname: nil, group_id: nil, subdomain: nil, prefecture: nil, order: nil, start: nil, count: nil) ⇒ ConnpassApiV2::Response
Search events.
Instance Method Details
#get_event_presentations(event_id, start: nil, count: nil) ⇒ ConnpassApiV2::Response
Get list of presentations submitted to the event
70 71 72 73 74 75 76 77 |
# File 'lib/connpass_api_v2/client/event_methods.rb', line 70 def get_event_presentations(event_id, start: nil, count: nil) params = { start: start, count: count, } connection.get("events/#{event_id}/presentations/", params.compact).body # steep:ignore NoMethod end |
#get_events(event_id: nil, keyword: nil, keyword_or: nil, ym: nil, ymd: nil, nickname: nil, owner_nickname: nil, group_id: nil, subdomain: nil, prefecture: nil, order: nil, start: nil, count: nil) ⇒ ConnpassApiV2::Response
Search events
26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 |
# File 'lib/connpass_api_v2/client/event_methods.rb', line 26 def get_events(event_id: nil, keyword: nil, keyword_or: nil, ym: nil, ymd: nil, nickname: nil, owner_nickname: nil, group_id: nil, subdomain: nil, prefecture: nil, order: nil, start: nil, count: nil) params = { event_id: Client.joined_param(event_id), keyword: Client.joined_param(keyword), keyword_or: Client.joined_param(keyword_or), nickname: Client.joined_param(nickname), owner_nickname: Client.joined_param(owner_nickname), group_id: Client.joined_param(group_id), subdomain: Client.joined_param(subdomain), prefecture: Client.joined_param(prefecture), order: Client.to_order_num(order), start: start, count: count, } if ym values = Array(ym).map do |v| # @type var v: String | Date Client.to_ym(v) end params[:ym] = Client.joined_param(values) end if ymd values = Array(ymd).map do |v| # @type var v: String | Date Client.to_ymd(v) end params[:ymd] = Client.joined_param(values) end connection.get("events/", params.compact).body # steep:ignore NoMethod end |