Class: Spotted::Resources::Chapters
- Inherits:
-
Object
- Object
- Spotted::Resources::Chapters
- Defined in:
- lib/spotted/resources/chapters.rb
Instance Method Summary collapse
-
#bulk_retrieve(ids:, market: nil, request_options: {}) ⇒ Spotted::Models::ChapterBulkRetrieveResponse
Some parameter documentations has been truncated, see Models::ChapterBulkRetrieveParams for more details.
-
#initialize(client:) ⇒ Chapters
constructor
private
A new instance of Chapters.
-
#retrieve(id, market: nil, request_options: {}) ⇒ Spotted::Models::ChapterRetrieveResponse
Some parameter documentations has been truncated, see Models::ChapterRetrieveParams for more details.
Constructor Details
#initialize(client:) ⇒ Chapters
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Chapters.
67 68 69 |
# File 'lib/spotted/resources/chapters.rb', line 67 def initialize(client:) @client = client end |
Instance Method Details
#bulk_retrieve(ids:, market: nil, request_options: {}) ⇒ Spotted::Models::ChapterBulkRetrieveResponse
Some parameter documentations has been truncated, see Models::ChapterBulkRetrieveParams for more details.
Get Spotify catalog information for several audiobook chapters identified by their Spotify IDs. Chapters are only available within the US, UK, Canada, Ireland, New Zealand and Australia markets.
53 54 55 56 57 58 59 60 61 62 |
# File 'lib/spotted/resources/chapters.rb', line 53 def bulk_retrieve(params) parsed, = Spotted::ChapterBulkRetrieveParams.dump_request(params) @client.request( method: :get, path: "chapters", query: parsed, model: Spotted::Models::ChapterBulkRetrieveResponse, options: ) end |
#retrieve(id, market: nil, request_options: {}) ⇒ Spotted::Models::ChapterRetrieveResponse
Some parameter documentations has been truncated, see Models::ChapterRetrieveParams for more details.
Get Spotify catalog information for a single audiobook chapter. Chapters are only available within the US, UK, Canada, Ireland, New Zealand and Australia markets.
24 25 26 27 28 29 30 31 32 33 |
# File 'lib/spotted/resources/chapters.rb', line 24 def retrieve(id, params = {}) parsed, = Spotted::ChapterRetrieveParams.dump_request(params) @client.request( method: :get, path: ["chapters/%1$s", id], query: parsed, model: Spotted::Models::ChapterRetrieveResponse, options: ) end |