spotted-ts 0.1.0 → 0.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (247) hide show
  1. package/CHANGELOG.md +183 -3
  2. package/README.md +50 -4
  3. package/client.d.mts +33 -25
  4. package/client.d.mts.map +1 -1
  5. package/client.d.ts +33 -25
  6. package/client.d.ts.map +1 -1
  7. package/client.js +16 -9
  8. package/client.js.map +1 -1
  9. package/client.mjs +17 -10
  10. package/client.mjs.map +1 -1
  11. package/package.json +2 -2
  12. package/resources/albums.d.mts +34 -2
  13. package/resources/albums.d.mts.map +1 -1
  14. package/resources/albums.d.ts +34 -2
  15. package/resources/albums.d.ts.map +1 -1
  16. package/resources/artists.d.mts +15 -7
  17. package/resources/artists.d.mts.map +1 -1
  18. package/resources/artists.d.ts +15 -7
  19. package/resources/artists.d.ts.map +1 -1
  20. package/resources/artists.js +2 -2
  21. package/resources/artists.js.map +1 -1
  22. package/resources/artists.mjs +2 -2
  23. package/resources/artists.mjs.map +1 -1
  24. package/resources/audio-analysis.d.mts +32 -0
  25. package/resources/audio-analysis.d.mts.map +1 -1
  26. package/resources/audio-analysis.d.ts +32 -0
  27. package/resources/audio-analysis.d.ts.map +1 -1
  28. package/resources/audio-features.d.mts +22 -6
  29. package/resources/audio-features.d.mts.map +1 -1
  30. package/resources/audio-features.d.ts +22 -6
  31. package/resources/audio-features.d.ts.map +1 -1
  32. package/resources/audio-features.js +1 -1
  33. package/resources/audio-features.js.map +1 -1
  34. package/resources/audio-features.mjs +1 -1
  35. package/resources/audio-features.mjs.map +1 -1
  36. package/resources/audiobooks.d.mts +32 -8
  37. package/resources/audiobooks.d.mts.map +1 -1
  38. package/resources/audiobooks.d.ts +32 -8
  39. package/resources/audiobooks.d.ts.map +1 -1
  40. package/resources/audiobooks.js +1 -1
  41. package/resources/audiobooks.js.map +1 -1
  42. package/resources/audiobooks.mjs +1 -1
  43. package/resources/audiobooks.mjs.map +1 -1
  44. package/resources/browse/browse.d.mts +27 -3
  45. package/resources/browse/browse.d.mts.map +1 -1
  46. package/resources/browse/browse.d.ts +27 -3
  47. package/resources/browse/browse.d.ts.map +1 -1
  48. package/resources/browse/browse.js.map +1 -1
  49. package/resources/browse/browse.mjs.map +1 -1
  50. package/resources/browse/categories.d.mts +45 -53
  51. package/resources/browse/categories.d.mts.map +1 -1
  52. package/resources/browse/categories.d.ts +45 -53
  53. package/resources/browse/categories.d.ts.map +1 -1
  54. package/resources/browse/categories.js +5 -1
  55. package/resources/browse/categories.js.map +1 -1
  56. package/resources/browse/categories.mjs +5 -1
  57. package/resources/browse/categories.mjs.map +1 -1
  58. package/resources/browse/index.d.mts +1 -1
  59. package/resources/browse/index.d.mts.map +1 -1
  60. package/resources/browse/index.d.ts +1 -1
  61. package/resources/browse/index.d.ts.map +1 -1
  62. package/resources/browse/index.js.map +1 -1
  63. package/resources/browse/index.mjs.map +1 -1
  64. package/resources/chapters.d.mts +22 -6
  65. package/resources/chapters.d.mts.map +1 -1
  66. package/resources/chapters.d.ts +22 -6
  67. package/resources/chapters.d.ts.map +1 -1
  68. package/resources/chapters.js +1 -1
  69. package/resources/chapters.js.map +1 -1
  70. package/resources/chapters.mjs +1 -1
  71. package/resources/chapters.mjs.map +1 -1
  72. package/resources/episodes.d.mts +4 -4
  73. package/resources/episodes.d.mts.map +1 -1
  74. package/resources/episodes.d.ts +4 -4
  75. package/resources/episodes.d.ts.map +1 -1
  76. package/resources/episodes.js +1 -1
  77. package/resources/episodes.js.map +1 -1
  78. package/resources/episodes.mjs +1 -1
  79. package/resources/episodes.mjs.map +1 -1
  80. package/resources/index.d.mts +8 -8
  81. package/resources/index.d.mts.map +1 -1
  82. package/resources/index.d.ts +8 -8
  83. package/resources/index.d.ts.map +1 -1
  84. package/resources/index.js.map +1 -1
  85. package/resources/index.mjs +1 -1
  86. package/resources/index.mjs.map +1 -1
  87. package/resources/me/albums.d.mts +41 -1
  88. package/resources/me/albums.d.mts.map +1 -1
  89. package/resources/me/albums.d.ts +41 -1
  90. package/resources/me/albums.d.ts.map +1 -1
  91. package/resources/me/audiobooks.d.mts +17 -1
  92. package/resources/me/audiobooks.d.mts.map +1 -1
  93. package/resources/me/audiobooks.d.ts +17 -1
  94. package/resources/me/audiobooks.d.ts.map +1 -1
  95. package/resources/me/episodes.d.mts +24 -0
  96. package/resources/me/episodes.d.mts.map +1 -1
  97. package/resources/me/episodes.d.ts +24 -0
  98. package/resources/me/episodes.d.ts.map +1 -1
  99. package/resources/me/following.d.mts +39 -7
  100. package/resources/me/following.d.mts.map +1 -1
  101. package/resources/me/following.d.ts +39 -7
  102. package/resources/me/following.d.ts.map +1 -1
  103. package/resources/me/following.js +2 -2
  104. package/resources/me/following.js.map +1 -1
  105. package/resources/me/following.mjs +2 -2
  106. package/resources/me/following.mjs.map +1 -1
  107. package/resources/me/index.d.mts +1 -1
  108. package/resources/me/index.d.mts.map +1 -1
  109. package/resources/me/index.d.ts +1 -1
  110. package/resources/me/index.d.ts.map +1 -1
  111. package/resources/me/me.d.mts +18 -2
  112. package/resources/me/me.d.mts.map +1 -1
  113. package/resources/me/me.d.ts +18 -2
  114. package/resources/me/me.d.ts.map +1 -1
  115. package/resources/me/me.js.map +1 -1
  116. package/resources/me/me.mjs.map +1 -1
  117. package/resources/me/player/player.d.mts +72 -0
  118. package/resources/me/player/player.d.mts.map +1 -1
  119. package/resources/me/player/player.d.ts +72 -0
  120. package/resources/me/player/player.d.ts.map +1 -1
  121. package/resources/me/player/player.js.map +1 -1
  122. package/resources/me/player/player.mjs.map +1 -1
  123. package/resources/me/player/queue.d.mts +8 -0
  124. package/resources/me/player/queue.d.mts.map +1 -1
  125. package/resources/me/player/queue.d.ts +8 -0
  126. package/resources/me/player/queue.d.ts.map +1 -1
  127. package/resources/me/shows.d.mts +24 -0
  128. package/resources/me/shows.d.mts.map +1 -1
  129. package/resources/me/shows.d.ts +24 -0
  130. package/resources/me/shows.d.ts.map +1 -1
  131. package/resources/me/tracks.d.mts +24 -0
  132. package/resources/me/tracks.d.mts.map +1 -1
  133. package/resources/me/tracks.d.ts +24 -0
  134. package/resources/me/tracks.d.ts.map +1 -1
  135. package/resources/playlists/followers.d.mts +4 -3
  136. package/resources/playlists/followers.d.mts.map +1 -1
  137. package/resources/playlists/followers.d.ts +4 -3
  138. package/resources/playlists/followers.d.ts.map +1 -1
  139. package/resources/playlists/images.d.mts +7 -12
  140. package/resources/playlists/images.d.mts.map +1 -1
  141. package/resources/playlists/images.d.ts +7 -12
  142. package/resources/playlists/images.d.ts.map +1 -1
  143. package/resources/playlists/images.js +11 -7
  144. package/resources/playlists/images.js.map +1 -1
  145. package/resources/playlists/images.mjs +11 -7
  146. package/resources/playlists/images.mjs.map +1 -1
  147. package/resources/playlists/index.d.mts +1 -1
  148. package/resources/playlists/index.d.mts.map +1 -1
  149. package/resources/playlists/index.d.ts +1 -1
  150. package/resources/playlists/index.d.ts.map +1 -1
  151. package/resources/playlists/index.js.map +1 -1
  152. package/resources/playlists/index.mjs.map +1 -1
  153. package/resources/playlists/playlists.d.mts +17 -8
  154. package/resources/playlists/playlists.d.mts.map +1 -1
  155. package/resources/playlists/playlists.d.ts +17 -8
  156. package/resources/playlists/playlists.d.ts.map +1 -1
  157. package/resources/playlists/playlists.js.map +1 -1
  158. package/resources/playlists/playlists.mjs.map +1 -1
  159. package/resources/playlists/tracks.d.mts +24 -0
  160. package/resources/playlists/tracks.d.mts.map +1 -1
  161. package/resources/playlists/tracks.d.ts +24 -0
  162. package/resources/playlists/tracks.d.ts.map +1 -1
  163. package/resources/recommendations.d.mts +16 -0
  164. package/resources/recommendations.d.mts.map +1 -1
  165. package/resources/recommendations.d.ts +16 -0
  166. package/resources/recommendations.d.ts.map +1 -1
  167. package/resources/search.d.mts +73 -17
  168. package/resources/search.d.mts.map +1 -1
  169. package/resources/search.d.ts +73 -17
  170. package/resources/search.d.ts.map +1 -1
  171. package/resources/search.js +1 -1
  172. package/resources/search.js.map +1 -1
  173. package/resources/search.mjs +1 -1
  174. package/resources/search.mjs.map +1 -1
  175. package/resources/shared.d.mts +214 -5
  176. package/resources/shared.d.mts.map +1 -1
  177. package/resources/shared.d.ts +214 -5
  178. package/resources/shared.d.ts.map +1 -1
  179. package/resources/shows.d.mts +13 -5
  180. package/resources/shows.d.mts.map +1 -1
  181. package/resources/shows.d.ts +13 -5
  182. package/resources/shows.d.ts.map +1 -1
  183. package/resources/shows.js +1 -1
  184. package/resources/shows.js.map +1 -1
  185. package/resources/shows.mjs +1 -1
  186. package/resources/shows.mjs.map +1 -1
  187. package/resources/tracks.d.mts +4 -4
  188. package/resources/tracks.d.mts.map +1 -1
  189. package/resources/tracks.d.ts +4 -4
  190. package/resources/tracks.d.ts.map +1 -1
  191. package/resources/tracks.js +1 -1
  192. package/resources/tracks.js.map +1 -1
  193. package/resources/tracks.mjs +1 -1
  194. package/resources/tracks.mjs.map +1 -1
  195. package/resources/users/playlists.d.mts +18 -11
  196. package/resources/users/playlists.d.mts.map +1 -1
  197. package/resources/users/playlists.d.ts +18 -11
  198. package/resources/users/playlists.d.ts.map +1 -1
  199. package/resources/users/users.d.mts +8 -0
  200. package/resources/users/users.d.mts.map +1 -1
  201. package/resources/users/users.d.ts +8 -0
  202. package/resources/users/users.d.ts.map +1 -1
  203. package/resources/users/users.js.map +1 -1
  204. package/resources/users/users.mjs.map +1 -1
  205. package/src/client.ts +71 -55
  206. package/src/resources/albums.ts +40 -4
  207. package/src/resources/artists.ts +24 -12
  208. package/src/resources/audio-analysis.ts +36 -0
  209. package/src/resources/audio-features.ts +28 -7
  210. package/src/resources/audiobooks.ts +41 -11
  211. package/src/resources/browse/browse.ts +31 -2
  212. package/src/resources/browse/categories.ts +54 -62
  213. package/src/resources/browse/index.ts +1 -0
  214. package/src/resources/chapters.ts +28 -7
  215. package/src/resources/episodes.ts +8 -5
  216. package/src/resources/index.ts +21 -16
  217. package/src/resources/me/albums.ts +47 -2
  218. package/src/resources/me/audiobooks.ts +20 -2
  219. package/src/resources/me/episodes.ts +27 -0
  220. package/src/resources/me/following.ts +47 -8
  221. package/src/resources/me/index.ts +2 -2
  222. package/src/resources/me/me.ts +22 -4
  223. package/src/resources/me/player/player.ts +81 -0
  224. package/src/resources/me/player/queue.ts +9 -0
  225. package/src/resources/me/shows.ts +27 -0
  226. package/src/resources/me/tracks.ts +27 -0
  227. package/src/resources/playlists/followers.ts +4 -3
  228. package/src/resources/playlists/images.ts +16 -15
  229. package/src/resources/playlists/index.ts +1 -1
  230. package/src/resources/playlists/playlists.ts +19 -13
  231. package/src/resources/playlists/tracks.ts +27 -0
  232. package/src/resources/recommendations.ts +18 -0
  233. package/src/resources/search.ts +86 -26
  234. package/src/resources/shared.ts +241 -6
  235. package/src/resources/shows.ts +19 -7
  236. package/src/resources/tracks.ts +8 -5
  237. package/src/resources/users/playlists.ts +20 -12
  238. package/src/resources/users/users.ts +9 -0
  239. package/src/version.ts +1 -1
  240. package/version.d.mts +1 -1
  241. package/version.d.mts.map +1 -1
  242. package/version.d.ts +1 -1
  243. package/version.d.ts.map +1 -1
  244. package/version.js +1 -1
  245. package/version.js.map +1 -1
  246. package/version.mjs +1 -1
  247. package/version.mjs.map +1 -1
@@ -11,9 +11,9 @@ export declare class Tracks extends APIResource {
11
11
  /**
12
12
  * Get Spotify catalog information for multiple tracks based on their Spotify IDs.
13
13
  */
14
- list(query: TrackListParams, options?: RequestOptions): APIPromise<TrackListResponse>;
14
+ bulkRetrieve(query: TrackBulkRetrieveParams, options?: RequestOptions): APIPromise<TrackBulkRetrieveResponse>;
15
15
  }
16
- export interface TrackListResponse {
16
+ export interface TrackBulkRetrieveResponse {
17
17
  tracks: Array<Shared.TrackObject>;
18
18
  }
19
19
  export interface TrackRetrieveParams {
@@ -30,7 +30,7 @@ export interface TrackRetrieveParams {
30
30
  */
31
31
  market?: string;
32
32
  }
33
- export interface TrackListParams {
33
+ export interface TrackBulkRetrieveParams {
34
34
  /**
35
35
  * A comma-separated list of the
36
36
  * [Spotify IDs](/documentation/web-api/concepts/spotify-uris-ids). For example:
@@ -51,6 +51,6 @@ export interface TrackListParams {
51
51
  market?: string;
52
52
  }
53
53
  export declare namespace Tracks {
54
- export { type TrackListResponse as TrackListResponse, type TrackRetrieveParams as TrackRetrieveParams, type TrackListParams as TrackListParams, };
54
+ export { type TrackBulkRetrieveResponse as TrackBulkRetrieveResponse, type TrackRetrieveParams as TrackRetrieveParams, type TrackBulkRetrieveParams as TrackBulkRetrieveParams, };
55
55
  }
56
56
  //# sourceMappingURL=tracks.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tracks.d.ts","sourceRoot":"","sources":["../src/resources/tracks.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB,qBAAa,MAAO,SAAQ,WAAW;IACrC;;;OAGG;IACH,QAAQ,CACN,EAAE,EAAE,MAAM,EACV,KAAK,GAAE,mBAAmB,GAAG,IAAI,GAAG,SAAc,EAClD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,MAAM,CAAC,WAAW,CAAC;IAIjC;;OAEG;IACH,IAAI,CAAC,KAAK,EAAE,eAAe,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,iBAAiB,CAAC;CAGtF;AAED,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC;CACnC;AAED,MAAM,WAAW,mBAAmB;IAClC;;;;;;;;;;OAUG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,eAAe;IAC9B;;;;OAIG;IACH,GAAG,EAAE,MAAM,CAAC;IAEZ;;;;;;;;;;OAUG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EACL,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,eAAe,IAAI,eAAe,GACxC,CAAC;CACH"}
1
+ {"version":3,"file":"tracks.d.ts","sourceRoot":"","sources":["../src/resources/tracks.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB,qBAAa,MAAO,SAAQ,WAAW;IACrC;;;OAGG;IACH,QAAQ,CACN,EAAE,EAAE,MAAM,EACV,KAAK,GAAE,mBAAmB,GAAG,IAAI,GAAG,SAAc,EAClD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,MAAM,CAAC,WAAW,CAAC;IAIjC;;OAEG;IACH,YAAY,CACV,KAAK,EAAE,uBAAuB,EAC9B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,yBAAyB,CAAC;CAGzC;AAED,MAAM,WAAW,yBAAyB;IACxC,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC;CACnC;AAED,MAAM,WAAW,mBAAmB;IAClC;;;;;;;;;;OAUG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,uBAAuB;IACtC;;;;OAIG;IACH,GAAG,EAAE,MAAM,CAAC;IAEZ;;;;;;;;;;OAUG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EACL,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,uBAAuB,IAAI,uBAAuB,GACxD,CAAC;CACH"}
@@ -15,7 +15,7 @@ class Tracks extends resource_1.APIResource {
15
15
  /**
16
16
  * Get Spotify catalog information for multiple tracks based on their Spotify IDs.
17
17
  */
18
- list(query, options) {
18
+ bulkRetrieve(query, options) {
19
19
  return this._client.get('/tracks', { query, ...options });
20
20
  }
21
21
  }
@@ -1 +1 @@
1
- {"version":3,"file":"tracks.js","sourceRoot":"","sources":["../src/resources/tracks.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;AAI/C,oDAA8C;AAE9C,MAAa,MAAO,SAAQ,sBAAW;IACrC;;;OAGG;IACH,QAAQ,CACN,EAAU,EACV,QAAgD,EAAE,EAClD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,WAAW,EAAE,EAAE,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACtE,CAAC;IAED;;OAEG;IACH,IAAI,CAAC,KAAsB,EAAE,OAAwB;QACnD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,SAAS,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5D,CAAC;CACF;AAnBD,wBAmBC"}
1
+ {"version":3,"file":"tracks.js","sourceRoot":"","sources":["../src/resources/tracks.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;AAI/C,oDAA8C;AAE9C,MAAa,MAAO,SAAQ,sBAAW;IACrC;;;OAGG;IACH,QAAQ,CACN,EAAU,EACV,QAAgD,EAAE,EAClD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,WAAW,EAAE,EAAE,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACtE,CAAC;IAED;;OAEG;IACH,YAAY,CACV,KAA8B,EAC9B,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,SAAS,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5D,CAAC;CACF;AAtBD,wBAsBC"}
@@ -12,7 +12,7 @@ export class Tracks extends APIResource {
12
12
  /**
13
13
  * Get Spotify catalog information for multiple tracks based on their Spotify IDs.
14
14
  */
15
- list(query, options) {
15
+ bulkRetrieve(query, options) {
16
16
  return this._client.get('/tracks', { query, ...options });
17
17
  }
18
18
  }
@@ -1 +1 @@
1
- {"version":3,"file":"tracks.mjs","sourceRoot":"","sources":["../src/resources/tracks.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAIf,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,MAAO,SAAQ,WAAW;IACrC;;;OAGG;IACH,QAAQ,CACN,EAAU,EACV,QAAgD,EAAE,EAClD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,WAAW,EAAE,EAAE,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACtE,CAAC;IAED;;OAEG;IACH,IAAI,CAAC,KAAsB,EAAE,OAAwB;QACnD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,SAAS,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5D,CAAC;CACF"}
1
+ {"version":3,"file":"tracks.mjs","sourceRoot":"","sources":["../src/resources/tracks.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAIf,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,MAAO,SAAQ,WAAW;IACrC;;;OAGG;IACH,QAAQ,CACN,EAAU,EACV,QAAgD,EAAE,EAClD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,WAAW,EAAE,EAAE,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACtE,CAAC;IAED;;OAEG;IACH,YAAY,CACV,KAA8B,EAC9B,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,SAAS,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5D,CAAC;CACF"}
@@ -78,12 +78,13 @@ export interface PlaylistCreateResponse {
78
78
  */
79
79
  owner?: PlaylistCreateResponse.Owner;
80
80
  /**
81
- * The playlist's public/private status (if it is added to the user's profile):
82
- * `true` the playlist is public, `false` the playlist is private, `null` the
83
- * playlist status is not relevant. For more about public/private status, see
81
+ * The playlist's public/private status (if it should be added to the user's
82
+ * profile or not): `true` the playlist will be public, `false` the playlist will
83
+ * be private, `null` the playlist status is not relevant. For more about
84
+ * public/private status, see
84
85
  * [Working with Playlists](/documentation/web-api/concepts/playlists)
85
86
  */
86
- public?: boolean;
87
+ published?: boolean;
87
88
  /**
88
89
  * The version identifier for the current playlist. Can be supplied in other
89
90
  * requests to target a specific playlist version
@@ -121,7 +122,6 @@ export declare namespace PlaylistCreateResponse {
121
122
  * A link to the Web API endpoint returning the full result of the request
122
123
  */
123
124
  href: string;
124
- items: Array<Shared.PlaylistTrackObject>;
125
125
  /**
126
126
  * The maximum number of items in the response (as set in the query or by default).
127
127
  */
@@ -142,6 +142,15 @@ export declare namespace PlaylistCreateResponse {
142
142
  * The total number of items available to return.
143
143
  */
144
144
  total: number;
145
+ items?: Array<Shared.PlaylistTrackObject>;
146
+ /**
147
+ * The playlist's public/private status (if it should be added to the user's
148
+ * profile or not): `true` the playlist will be public, `false` the playlist will
149
+ * be private, `null` the playlist status is not relevant. For more about
150
+ * public/private status, see
151
+ * [Working with Playlists](/documentation/web-api/concepts/playlists)
152
+ */
153
+ published?: boolean;
145
154
  }
146
155
  }
147
156
  export interface PlaylistCreateParams {
@@ -165,15 +174,13 @@ export interface PlaylistCreateParams {
165
174
  */
166
175
  description?: string;
167
176
  /**
168
- * Defaults to `true`. The playlist's public/private status (if it should be added
169
- * to the user's profile or not): `true` the playlist will be public, `false` the
170
- * playlist will be private. To be able to create private playlists, the user must
171
- * have granted the `playlist-modify-private`
172
- * [scope](/documentation/web-api/concepts/scopes/#list-of-scopes). For more about
177
+ * The playlist's public/private status (if it should be added to the user's
178
+ * profile or not): `true` the playlist will be public, `false` the playlist will
179
+ * be private, `null` the playlist status is not relevant. For more about
173
180
  * public/private status, see
174
181
  * [Working with Playlists](/documentation/web-api/concepts/playlists)
175
182
  */
176
- public?: boolean;
183
+ published?: boolean;
177
184
  [k: string]: unknown;
178
185
  }
179
186
  export interface PlaylistListParams {
@@ -1 +1 @@
1
- {"version":3,"file":"playlists.d.mts","sourceRoot":"","sources":["../../src/resources/users/playlists.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,EAAE,sCAAsC,EAAE;OAC1C,EAAE,UAAU,EAAE;OACd,EAAiB,WAAW,EAAE;OAC9B,EAAE,cAAc,EAAE;AAGzB,qBAAa,SAAU,SAAQ,WAAW;IACxC;;;;;;;;;;;;OAYG;IACH,MAAM,CACJ,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,oBAAoB,EAC1B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,sBAAsB,CAAC;IAIrC;;;;;;;;;;;;OAYG;IACH,IAAI,CACF,MAAM,EAAE,MAAM,EACd,KAAK,GAAE,kBAAkB,GAAG,IAAI,GAAG,SAAc,EACjD,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,sCAAsC,EAAE,MAAM,CAAC,wBAAwB,CAAC;CAOxF;AAED,MAAM,WAAW,sBAAsB;IACrC;;;OAGG;IACH,EAAE,CAAC,EAAE,MAAM,CAAC;IAEZ;;OAEG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;IAExB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAE5B;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC,iBAAiB,CAAC;IAEzC;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC,eAAe,CAAC;IAEnC;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;;;;OAMG;IACH,MAAM,CAAC,EAAE,KAAK,CAAC,MAAM,CA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CAAC,EAAE,OAAO,CAAC;IAExB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB,CAAC,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;CACtB;AAED,MAAM,WAAW,kBAAkB;IACjC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,kBAAkB,IAAI,kBAAkB,GAC9C,CAAC;CACH;AAED,OAAO,EAAE,KAAK,sCAAsC,EAAE,CAAC"}
@@ -78,12 +78,13 @@ export interface PlaylistCreateResponse {
78
78
  */
79
79
  owner?: PlaylistCreateResponse.Owner;
80
80
  /**
81
- * The playlist's public/private status (if it is added to the user's profile):
82
- * `true` the playlist is public, `false` the playlist is private, `null` the
83
- * playlist status is not relevant. For more about public/private status, see
81
+ * The playlist's public/private status (if it should be added to the user's
82
+ * profile or not): `true` the playlist will be public, `false` the playlist will
83
+ * be private, `null` the playlist status is not relevant. For more about
84
+ * public/private status, see
84
85
  * [Working with Playlists](/documentation/web-api/concepts/playlists)
85
86
  */
86
- public?: boolean;
87
+ published?: boolean;
87
88
  /**
88
89
  * The version identifier for the current playlist. Can be supplied in other
89
90
  * requests to target a specific playlist version
@@ -121,7 +122,6 @@ export declare namespace PlaylistCreateResponse {
121
122
  * A link to the Web API endpoint returning the full result of the request
122
123
  */
123
124
  href: string;
124
- items: Array<Shared.PlaylistTrackObject>;
125
125
  /**
126
126
  * The maximum number of items in the response (as set in the query or by default).
127
127
  */
@@ -142,6 +142,15 @@ export declare namespace PlaylistCreateResponse {
142
142
  * The total number of items available to return.
143
143
  */
144
144
  total: number;
145
+ items?: Array<Shared.PlaylistTrackObject>;
146
+ /**
147
+ * The playlist's public/private status (if it should be added to the user's
148
+ * profile or not): `true` the playlist will be public, `false` the playlist will
149
+ * be private, `null` the playlist status is not relevant. For more about
150
+ * public/private status, see
151
+ * [Working with Playlists](/documentation/web-api/concepts/playlists)
152
+ */
153
+ published?: boolean;
145
154
  }
146
155
  }
147
156
  export interface PlaylistCreateParams {
@@ -165,15 +174,13 @@ export interface PlaylistCreateParams {
165
174
  */
166
175
  description?: string;
167
176
  /**
168
- * Defaults to `true`. The playlist's public/private status (if it should be added
169
- * to the user's profile or not): `true` the playlist will be public, `false` the
170
- * playlist will be private. To be able to create private playlists, the user must
171
- * have granted the `playlist-modify-private`
172
- * [scope](/documentation/web-api/concepts/scopes/#list-of-scopes). For more about
177
+ * The playlist's public/private status (if it should be added to the user's
178
+ * profile or not): `true` the playlist will be public, `false` the playlist will
179
+ * be private, `null` the playlist status is not relevant. For more about
173
180
  * public/private status, see
174
181
  * [Working with Playlists](/documentation/web-api/concepts/playlists)
175
182
  */
176
- public?: boolean;
183
+ published?: boolean;
177
184
  [k: string]: unknown;
178
185
  }
179
186
  export interface PlaylistListParams {
@@ -1 +1 @@
1
- {"version":3,"file":"playlists.d.ts","sourceRoot":"","sources":["../../src/resources/users/playlists.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,EAAE,sCAAsC,EAAE;OAC1C,EAAE,UAAU,EAAE;OACd,EAAiB,WAAW,EAAE;OAC9B,EAAE,cAAc,EAAE;AAGzB,qBAAa,SAAU,SAAQ,WAAW;IACxC;;;;;;;;;;;;OAYG;IACH,MAAM,CACJ,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,oBAAoB,EAC1B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,sBAAsB,CAAC;IAIrC;;;;;;;;;;;;OAYG;IACH,IAAI,CACF,MAAM,EAAE,MAAM,EACd,KAAK,GAAE,kBAAkB,GAAG,IAAI,GA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H,UAAiB,MAAM;QACrB;;WAEG;QACH,IAAI,EAAE,MAAM,CAAC;QAEb;;WAEG;QACH,KAAK,EAAE,MAAM,CAAC;QAEd;;WAEG;QACH,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;QAEpB;;WAEG;QACH,MAAM,EAAE,MAAM,CAAC;QAEf;;WAEG;QACH,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;QAExB;;WAEG;QACH,KAAK,EAAE,MAAM,CAAC;QAEd,KAAK,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,mBAAmB,CAAC,CAAC;QAE1C;;;;;;WAMG;QACH,SAAS,CAAC,EAAE,OAAO,CAAC;KACrB;CACF;AAED,MAAM,WAAW,oBAAoB;IACnC;;;;OAIG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;;;;;OAMG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;IAExB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB,CAAC,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;CACtB;AAED,MAAM,WAAW,kBAAkB;IACjC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,kBAAkB,IAAI,kBAAkB,GAC9C,CAAC;CACH;AAED,OAAO,EAAE,KAAK,sCAAsC,EAAE,CAAC"}
@@ -44,6 +44,14 @@ export interface UserRetrieveProfileResponse {
44
44
  * The user's profile image.
45
45
  */
46
46
  images?: Array<Shared.ImageObject>;
47
+ /**
48
+ * The playlist's public/private status (if it should be added to the user's
49
+ * profile or not): `true` the playlist will be public, `false` the playlist will
50
+ * be private, `null` the playlist status is not relevant. For more about
51
+ * public/private status, see
52
+ * [Working with Playlists](/documentation/web-api/concepts/playlists)
53
+ */
54
+ published?: boolean;
47
55
  /**
48
56
  * The object type.
49
57
  */
@@ -1 +1 @@
1
- {"version":3,"file":"users.d.mts","sourceRoot":"","sources":["../../src/resources/users/users.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,KAAK,YAAY;OACjB,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,kBAAkB,EAAE,SAAS,EAAE;OAC/E,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB,qBAAa,KAAM,SAAQ,WAAW;IACpC,SAAS,EAAE,YAAY,CAAC,SAAS,CAA4C;IAE7E;;;;;;;;;OASG;IACH,eAAe,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,2BAA2B,CAAC;CAGnG;AAED,MAAM,WAAW,2BAA2B;IAC1C;;;OAGG;IACH,EAAE,CAAC,EAAE,MAAM,CAAC;IAEZ;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAE7B;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC,iBAAiB,CAAC;IAEzC;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC,eAAe,CAAC;IAEnC;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,MAAM,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC;IAEnC;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAID,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,OAAO,EAAE,KAAK,2BAA2B,IAAI,2BAA2B,EAAE,CAAC;IAE3E,OAAO,EACL,SAAS,IAAI,SAAS,EACtB,KA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SAAS,IAAI,SAAS,EACtB,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,kBAAkB,IAAI,kBAAkB,GAC9C,CAAC;CACH"}
@@ -44,6 +44,14 @@ export interface UserRetrieveProfileResponse {
44
44
  * The user's profile image.
45
45
  */
46
46
  images?: Array<Shared.ImageObject>;
47
+ /**
48
+ * The playlist's public/private status (if it should be added to the user's
49
+ * profile or not): `true` the playlist will be public, `false` the playlist will
50
+ * be private, `null` the playlist status is not relevant. For more about
51
+ * public/private status, see
52
+ * [Working with Playlists](/documentation/web-api/concepts/playlists)
53
+ */
54
+ published?: boolean;
47
55
  /**
48
56
  * The object type.
49
57
  */
@@ -1 +1 @@
1
- {"version":3,"file":"users.d.ts","sourceRoot":"","sources":["../../src/resources/users/users.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,KAAK,YAAY;OACjB,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,kBAAkB,EAAE,SAAS,EAAE;OAC/E,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB,qBAAa,KAAM,SAAQ,WAAW;IACpC,SAAS,EAAE,YAAY,CAAC,SAAS,CAA4C;IAE7E;;;;;;;;;OASG;IACH,eAAe,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,2BAA2B,CAAC;CAGnG;AAED,MAAM,WAAW,2BAA2B;IAC1C;;;OAGG;IACH,EAAE,CAAC,EAAE,MAAM,CAAC;IAEZ;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAE7B;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC,iBAAiB,CAAC;IAEzC;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC,eAAe,CAAC;IAEnC;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;OA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AAK,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC;IAEnC;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAID,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,OAAO,EAAE,KAAK,2BAA2B,IAAI,2BAA2B,EAAE,CAAC;IAE3E,OAAO,EACL,SAAS,IAAI,SAAS,EACtB,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,kBAAkB,IAAI,kBAAkB,GAC9C,CAAC;CACH"}
@@ -1 +1 @@
1
- {"version":3,"file":"users.js","sourceRoot":"","sources":["../../src/resources/users/users.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,qDAAkD;AAElD,qEAA4C;AAC5C,8CAA0G;AAG1G,uDAAiD;AAEjD,MAAa,KAAM,SAAQ,sBAAW;IAAtC;;QACE,cAAS,GAA2B,IAAI,YAAY,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAe/E,CAAC;IAbC;;;;;;;;;OASG;IACH,eAAe,CAAC,MAAc,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,UAAU,MAAM,EAAE,EAAE,OAAO,CAAC,CAAC;IAC3D,CAAC;CACF;AAhBD,sBAgBC;AA8CD,KAAK,CAAC,SAAS,GAAG,qBAAS,CAAC"}
1
+ {"version":3,"file":"users.js","sourceRoot":"","sources":["../../src/resources/users/users.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,qDAAkD;AAElD,qEAA4C;AAC5C,8CAA0G;AAG1G,uDAAiD;AAEjD,MAAa,KAAM,SAAQ,sBAAW;IAAtC;;QACE,cAAS,GAA2B,IAAI,YAAY,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAe/E,CAAC;IAbC;;;;;;;;;OASG;IACH,eAAe,CAAC,MAAc,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,UAAU,MAAM,EAAE,EAAE,OAAO,CAAC,CAAC;IAC3D,CAAC;CACF;AAhBD,sBAgBC;AAuDD,KAAK,CAAC,SAAS,GAAG,qBAAS,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"users.mjs","sourceRoot":"","sources":["../../src/resources/users/users.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAEf,KAAK,YAAY;OACjB,EAAoE,SAAS,EAAE;OAG/E,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,KAAM,SAAQ,WAAW;IAAtC;;QACE,cAAS,GAA2B,IAAI,YAAY,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAe/E,CAAC;IAbC;;;;;;;;;OASG;IACH,eAAe,CAAC,MAAc,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,UAAU,MAAM,EAAE,EAAE,OAAO,CAAC,CAAC;IAC3D,CAAC;CACF;AA8CD,KAAK,CAAC,SAAS,GAAG,SAAS,CAAC"}
1
+ {"version":3,"file":"users.mjs","sourceRoot":"","sources":["../../src/resources/users/users.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAEf,KAAK,YAAY;OACjB,EAAoE,SAAS,EAAE;OAG/E,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,KAAM,SAAQ,WAAW;IAAtC;;QACE,cAAS,GAA2B,IAAI,YAAY,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAe/E,CAAC;IAbC;;;;;;;;;OASG;IACH,eAAe,CAAC,MAAc,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,UAAU,MAAM,EAAE,EAAE,OAAO,CAAC,CAAC;IAC3D,CAAC;CACF;AAuDD,KAAK,CAAC,SAAS,GAAG,SAAS,CAAC"}
package/src/client.ts CHANGED
@@ -28,27 +28,27 @@ import {
28
28
  Albums,
29
29
  } from './resources/albums';
30
30
  import {
31
+ ArtistBulkRetrieveParams,
32
+ ArtistBulkRetrieveResponse,
31
33
  ArtistListAlbumsParams,
32
34
  ArtistListAlbumsResponse,
33
35
  ArtistListAlbumsResponsesCursorURLPage,
34
- ArtistListParams,
35
36
  ArtistListRelatedArtistsResponse,
36
- ArtistListResponse,
37
- ArtistListTopTracksParams,
38
- ArtistListTopTracksResponse,
37
+ ArtistTopTracksParams,
38
+ ArtistTopTracksResponse,
39
39
  Artists,
40
40
  } from './resources/artists';
41
41
  import { AudioAnalysis, AudioAnalysisRetrieveResponse, TimeIntervalObject } from './resources/audio-analysis';
42
42
  import {
43
- AudioFeatureListParams,
44
- AudioFeatureListResponse,
43
+ AudioFeatureBulkRetrieveParams,
44
+ AudioFeatureBulkRetrieveResponse,
45
45
  AudioFeatureRetrieveResponse,
46
46
  AudioFeatures,
47
47
  } from './resources/audio-features';
48
48
  import {
49
+ AudiobookBulkRetrieveParams,
50
+ AudiobookBulkRetrieveResponse,
49
51
  AudiobookListChaptersParams,
50
- AudiobookListParams,
51
- AudiobookListResponse,
52
52
  AudiobookRetrieveParams,
53
53
  AudiobookRetrieveResponse,
54
54
  Audiobooks,
@@ -56,15 +56,15 @@ import {
56
56
  SimplifiedChapterObjectsCursorURLPage,
57
57
  } from './resources/audiobooks';
58
58
  import {
59
- ChapterListParams,
60
- ChapterListResponse,
59
+ ChapterBulkRetrieveParams,
60
+ ChapterBulkRetrieveResponse,
61
61
  ChapterRetrieveParams,
62
62
  ChapterRetrieveResponse,
63
63
  Chapters,
64
64
  } from './resources/chapters';
65
65
  import {
66
- EpisodeListParams,
67
- EpisodeListResponse,
66
+ EpisodeBulkRetrieveParams,
67
+ EpisodeBulkRetrieveResponse,
68
68
  EpisodeRetrieveParams,
69
69
  Episodes,
70
70
  } from './resources/episodes';
@@ -75,16 +75,21 @@ import {
75
75
  RecommendationListAvailableGenreSeedsResponse,
76
76
  Recommendations,
77
77
  } from './resources/recommendations';
78
- import { Search, SearchRetrieveParams, SearchRetrieveResponse } from './resources/search';
78
+ import { Search, SearchQueryParams, SearchQueryResponse } from './resources/search';
79
79
  import {
80
+ ShowBulkRetrieveParams,
81
+ ShowBulkRetrieveResponse,
80
82
  ShowListEpisodesParams,
81
- ShowListParams,
82
- ShowListResponse,
83
83
  ShowRetrieveParams,
84
84
  ShowRetrieveResponse,
85
85
  Shows,
86
86
  } from './resources/shows';
87
- import { TrackListParams, TrackListResponse, TrackRetrieveParams, Tracks } from './resources/tracks';
87
+ import {
88
+ TrackBulkRetrieveParams,
89
+ TrackBulkRetrieveResponse,
90
+ TrackRetrieveParams,
91
+ Tracks,
92
+ } from './resources/tracks';
88
93
  import {
89
94
  Browse,
90
95
  BrowseGetFeaturedPlaylistsParams,
@@ -118,12 +123,17 @@ export interface ClientOptions {
118
123
  /**
119
124
  * Defaults to process.env['SPOTIFY_CLIENT_ID'].
120
125
  */
121
- clientID?: string | undefined;
126
+ clientID?: string | null | undefined;
122
127
 
123
128
  /**
124
129
  * Defaults to process.env['SPOTIFY_CLIENT_SECRET'].
125
130
  */
126
- clientSecret?: string | undefined;
131
+ clientSecret?: string | null | undefined;
132
+
133
+ /**
134
+ * Defaults to process.env['SPOTIFY_ACCESS_TOKEN'].
135
+ */
136
+ accessToken?: string | null | undefined;
127
137
 
128
138
  /**
129
139
  * Override the default base URL for the API, e.g., "https://api.example.com/v2/"
@@ -198,13 +208,14 @@ export interface ClientOptions {
198
208
  * API Client for interfacing with the Spotted API.
199
209
  */
200
210
  export class Spotted {
201
- clientID: string;
202
- clientSecret: string;
211
+ clientID: string | null;
212
+ clientSecret: string | null;
213
+ accessToken: string | null;
203
214
 
204
215
  baseURL: string;
205
216
  maxRetries: number;
206
217
  timeout: number;
207
- logger: Logger | undefined;
218
+ logger: Logger;
208
219
  logLevel: LogLevel | undefined;
209
220
  fetchOptions: MergedRequestInit | undefined;
210
221
 
@@ -216,8 +227,9 @@ export class Spotted {
216
227
  /**
217
228
  * API Client for interfacing with the Spotted API.
218
229
  *
219
- * @param {string | undefined} [opts.clientID=process.env['SPOTIFY_CLIENT_ID'] ?? undefined]
220
- * @param {string | undefined} [opts.clientSecret=process.env['SPOTIFY_CLIENT_SECRET'] ?? undefined]
230
+ * @param {string | null | undefined} [opts.clientID=process.env['SPOTIFY_CLIENT_ID'] ?? null]
231
+ * @param {string | null | undefined} [opts.clientSecret=process.env['SPOTIFY_CLIENT_SECRET'] ?? null]
232
+ * @param {string | null | undefined} [opts.accessToken=process.env['SPOTIFY_ACCESS_TOKEN'] ?? null]
221
233
  * @param {string} [opts.baseURL=process.env['SPOTTED_BASE_URL'] ?? https://api.spotify.com/v1] - Override the default base URL for the API.
222
234
  * @param {number} [opts.timeout=1 minute] - The maximum amount of time (in milliseconds) the client will wait for a response before timing out.
223
235
  * @param {MergedRequestInit} [opts.fetchOptions] - Additional `RequestInit` options to be passed to `fetch` calls.
@@ -228,24 +240,15 @@ export class Spotted {
228
240
  */
229
241
  constructor({
230
242
  baseURL = readEnv('SPOTTED_BASE_URL'),
231
- clientID = readEnv('SPOTIFY_CLIENT_ID'),
232
- clientSecret = readEnv('SPOTIFY_CLIENT_SECRET'),
243
+ clientID = readEnv('SPOTIFY_CLIENT_ID') ?? null,
244
+ clientSecret = readEnv('SPOTIFY_CLIENT_SECRET') ?? null,
245
+ accessToken = readEnv('SPOTIFY_ACCESS_TOKEN') ?? null,
233
246
  ...opts
234
247
  }: ClientOptions = {}) {
235
- if (clientID === undefined) {
236
- throw new Errors.SpottedError(
237
- "The SPOTIFY_CLIENT_ID environment variable is missing or empty; either provide it, or instantiate the Spotted client with an clientID option, like new Spotted({ clientID: 'My Client ID' }).",
238
- );
239
- }
240
- if (clientSecret === undefined) {
241
- throw new Errors.SpottedError(
242
- "The SPOTIFY_CLIENT_SECRET environment variable is missing or empty; either provide it, or instantiate the Spotted client with an clientSecret option, like new Spotted({ clientSecret: 'My Client Secret' }).",
243
- );
244
- }
245
-
246
248
  const options: ClientOptions = {
247
249
  clientID,
248
250
  clientSecret,
251
+ accessToken,
249
252
  ...opts,
250
253
  baseURL: baseURL || `https://api.spotify.com/v1`,
251
254
  };
@@ -269,6 +272,7 @@ export class Spotted {
269
272
 
270
273
  this.clientID = clientID;
271
274
  this.clientSecret = clientSecret;
275
+ this.accessToken = accessToken;
272
276
  }
273
277
 
274
278
  /**
@@ -286,6 +290,7 @@ export class Spotted {
286
290
  fetchOptions: this.fetchOptions,
287
291
  clientID: this.clientID,
288
292
  clientSecret: this.clientSecret,
293
+ accessToken: this.accessToken,
289
294
  ...options,
290
295
  });
291
296
  client.oauth2_0AuthState = this.oauth2_0AuthState;
@@ -307,6 +312,17 @@ export class Spotted {
307
312
  return;
308
313
  }
309
314
 
315
+ protected async authHeaders(opts: FinalRequestOptions): Promise<NullableHeaders | undefined> {
316
+ return buildHeaders([await this.bearerAuth(opts), await this.oauth2_0Auth(opts)]);
317
+ }
318
+
319
+ protected async bearerAuth(opts: FinalRequestOptions): Promise<NullableHeaders | undefined> {
320
+ if (this.accessToken == null) {
321
+ return undefined;
322
+ }
323
+ return buildHeaders([{ Authorization: `Bearer ${this.accessToken}` }]);
324
+ }
325
+
310
326
  private oauth2_0AuthState:
311
327
  | {
312
328
  promise: Promise<{
@@ -320,7 +336,7 @@ export class Spotted {
320
336
  clientSecret: string;
321
337
  }
322
338
  | undefined;
323
- protected async authHeaders(opts: FinalRequestOptions): Promise<NullableHeaders | undefined> {
339
+ protected async oauth2_0Auth(opts: FinalRequestOptions): Promise<NullableHeaders | undefined> {
324
340
  if (!this.clientID || !this.clientSecret) {
325
341
  return undefined;
326
342
  }
@@ -942,40 +958,40 @@ export declare namespace Spotted {
942
958
 
943
959
  export {
944
960
  Artists as Artists,
945
- type ArtistListResponse as ArtistListResponse,
961
+ type ArtistBulkRetrieveResponse as ArtistBulkRetrieveResponse,
946
962
  type ArtistListAlbumsResponse as ArtistListAlbumsResponse,
947
963
  type ArtistListRelatedArtistsResponse as ArtistListRelatedArtistsResponse,
948
- type ArtistListTopTracksResponse as ArtistListTopTracksResponse,
964
+ type ArtistTopTracksResponse as ArtistTopTracksResponse,
949
965
  type ArtistListAlbumsResponsesCursorURLPage as ArtistListAlbumsResponsesCursorURLPage,
950
- type ArtistListParams as ArtistListParams,
966
+ type ArtistBulkRetrieveParams as ArtistBulkRetrieveParams,
951
967
  type ArtistListAlbumsParams as ArtistListAlbumsParams,
952
- type ArtistListTopTracksParams as ArtistListTopTracksParams,
968
+ type ArtistTopTracksParams as ArtistTopTracksParams,
953
969
  };
954
970
 
955
971
  export {
956
972
  Shows as Shows,
957
973
  type ShowRetrieveResponse as ShowRetrieveResponse,
958
- type ShowListResponse as ShowListResponse,
974
+ type ShowBulkRetrieveResponse as ShowBulkRetrieveResponse,
959
975
  type ShowRetrieveParams as ShowRetrieveParams,
960
- type ShowListParams as ShowListParams,
976
+ type ShowBulkRetrieveParams as ShowBulkRetrieveParams,
961
977
  type ShowListEpisodesParams as ShowListEpisodesParams,
962
978
  };
963
979
 
964
980
  export {
965
981
  Episodes as Episodes,
966
- type EpisodeListResponse as EpisodeListResponse,
982
+ type EpisodeBulkRetrieveResponse as EpisodeBulkRetrieveResponse,
967
983
  type EpisodeRetrieveParams as EpisodeRetrieveParams,
968
- type EpisodeListParams as EpisodeListParams,
984
+ type EpisodeBulkRetrieveParams as EpisodeBulkRetrieveParams,
969
985
  };
970
986
 
971
987
  export {
972
988
  Audiobooks as Audiobooks,
973
989
  type SimplifiedChapterObject as SimplifiedChapterObject,
974
990
  type AudiobookRetrieveResponse as AudiobookRetrieveResponse,
975
- type AudiobookListResponse as AudiobookListResponse,
991
+ type AudiobookBulkRetrieveResponse as AudiobookBulkRetrieveResponse,
976
992
  type SimplifiedChapterObjectsCursorURLPage as SimplifiedChapterObjectsCursorURLPage,
977
993
  type AudiobookRetrieveParams as AudiobookRetrieveParams,
978
- type AudiobookListParams as AudiobookListParams,
994
+ type AudiobookBulkRetrieveParams as AudiobookBulkRetrieveParams,
979
995
  type AudiobookListChaptersParams as AudiobookListChaptersParams,
980
996
  };
981
997
 
@@ -984,22 +1000,22 @@ export declare namespace Spotted {
984
1000
  export {
985
1001
  Chapters as Chapters,
986
1002
  type ChapterRetrieveResponse as ChapterRetrieveResponse,
987
- type ChapterListResponse as ChapterListResponse,
1003
+ type ChapterBulkRetrieveResponse as ChapterBulkRetrieveResponse,
988
1004
  type ChapterRetrieveParams as ChapterRetrieveParams,
989
- type ChapterListParams as ChapterListParams,
1005
+ type ChapterBulkRetrieveParams as ChapterBulkRetrieveParams,
990
1006
  };
991
1007
 
992
1008
  export {
993
1009
  Tracks as Tracks,
994
- type TrackListResponse as TrackListResponse,
1010
+ type TrackBulkRetrieveResponse as TrackBulkRetrieveResponse,
995
1011
  type TrackRetrieveParams as TrackRetrieveParams,
996
- type TrackListParams as TrackListParams,
1012
+ type TrackBulkRetrieveParams as TrackBulkRetrieveParams,
997
1013
  };
998
1014
 
999
1015
  export {
1000
1016
  Search as Search,
1001
- type SearchRetrieveResponse as SearchRetrieveResponse,
1002
- type SearchRetrieveParams as SearchRetrieveParams,
1017
+ type SearchQueryResponse as SearchQueryResponse,
1018
+ type SearchQueryParams as SearchQueryParams,
1003
1019
  };
1004
1020
 
1005
1021
  export {
@@ -1022,8 +1038,8 @@ export declare namespace Spotted {
1022
1038
  export {
1023
1039
  AudioFeatures as AudioFeatures,
1024
1040
  type AudioFeatureRetrieveResponse as AudioFeatureRetrieveResponse,
1025
- type AudioFeatureListResponse as AudioFeatureListResponse,
1026
- type AudioFeatureListParams as AudioFeatureListParams,
1041
+ type AudioFeatureBulkRetrieveResponse as AudioFeatureBulkRetrieveResponse,
1042
+ type AudioFeatureBulkRetrieveParams as AudioFeatureBulkRetrieveParams,
1027
1043
  };
1028
1044
 
1029
1045
  export {