Class: Zype::Players

Inherits:
BaseModel show all
Defined in:
lib/zype/models/players.rb

Overview

This class does not support all, create, update or delete methods. Read more at docs.zype.com/v1.0/reference#players

Since:

  • 0.10.0

Constant Summary

Constants inherited from BaseModel

BaseModel::ACCEPTED_KEYS

Instance Attribute Summary

Attributes inherited from BaseModel

#client

Instance Method Summary collapse

Methods inherited from BaseModel

#all, #auth=, #create, #delete, #initialize, #update

Constructor Details

This class inherits a constructor from Zype::BaseModel

Instance Method Details

#find(id:, format:) ⇒ Hash|String

Retrieve formatted player responses

Parameters:

  • id (String)

    ID of the video

  • format (String)

    format to return the response in. Valid options are html, js, json

Returns:

  • (Hash|String)

Since:

  • 0.10.0



18
19
20
# File 'lib/zype/models/players.rb', line 18

def find(id:, format:)
  client.execute(method: :get, path: "/#{path}/#{id}.#{format}")
end