Class: Twitch::ShoutoutsResource

Inherits:
Resource
  • Object
show all
Defined in:
lib/twitch/resources/shoutouts.rb

Instance Attribute Summary

Attributes inherited from Resource

#client

Instance Method Summary collapse

Methods inherited from Resource

#initialize

Constructor Details

This class inherits a constructor from Twitch::Resource

Instance Method Details

#create(from:, to:, moderator_id:) ⇒ Object

Moderator ID must match the user in the OAuth token From: the ID of the Broadcaster creating the Shoutout To: the ID of the Broadcaster the Shoutout will be for Required scope: moderator:manage:shoutouts



7
8
9
# File 'lib/twitch/resources/shoutouts.rb', line 7

def create(from:, to:, moderator_id:)
  post_request("chat/shoutouts?from_broadcaster_id=#{from}&to_broadcaster_id=#{to}&moderator_id=#{moderator_id}", body: nil)
end