Module: Zulip::Client::StreamSubscriptions

Included in:
Zulip::Client
Defined in:
lib/zulip/client/stream_subscriptions.rb

Instance Method Summary collapse

Instance Method Details

#get_subscriptionsObject



5
6
7
8
9
# File 'lib/zulip/client/stream_subscriptions.rb', line 5

def get_subscriptions
  get_subscriptions_response.map do |subscription|
    Zulip::StreamSubscription.new(subscription)
  end
end

#subscribe(streams) ⇒ Object



11
12
13
# File 'lib/zulip/client/stream_subscriptions.rb', line 11

def subscribe(streams)
  patch_subscriptions subscribe_params(streams)
end