podcast_api 3.0.0 → 3.1.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.
- checksums.yaml +4 -4
- data/README.md +25 -0
- data/lib/api-contract.json +20 -1
- data/lib/api_methods.rb +5 -0
- data/lib/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: a2c89e8fa63772c37d9acb31bfa776e209dba6378b95be19f0ff0973c49a320a
|
|
4
|
+
data.tar.gz: 65bda14d6a80ce94f6c6f1339e8c25f64a17f9cf3d443755995b98f290412753
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 410c234d102a5625c2e3cf018de11c35770ee3bf610fbf501de3f96cb5baffe73873793afab8f9621df46261d012b66de7f63c2994aafe6ba5b1644409b13a68
|
|
7
|
+
data.tar.gz: 0316f3078d519980810a76256fcef9bf76792d0ef2ade10c7e57059282e9a2eab337c2453c262a8f1f88a7fefba5153e90158739aafe80e23c36a04e73f90a0a
|
data/README.md
CHANGED
|
@@ -53,6 +53,7 @@ If you have any questions, please contact [hello@listennotes.com](hello@listenno
|
|
|
53
53
|
- [`fetch_podcasts_by_domain`](#fetch_podcasts_by_domain) — `GET /podcasts/domains/{domain_name}`
|
|
54
54
|
- [`create_playlist`](#create_playlist) — `POST /playlists`
|
|
55
55
|
- [`update_playlist`](#update_playlist) — `PUT /playlists/{id}`
|
|
56
|
+
- [`delete_playlist`](#delete_playlist) — `DELETE /playlists/{id}`
|
|
56
57
|
- [`add_playlist_item`](#add_playlist_item) — `POST /playlists/{id}/items`
|
|
57
58
|
- [`delete_playlist_item`](#delete_playlist_item) — `DELETE /playlists/{id}/items/{item_id}`
|
|
58
59
|
- [`update_playlist_item_notes`](#update_playlist_item_notes) — `PUT /playlists/{id}/items/{item_id}`
|
|
@@ -791,6 +792,30 @@ puts response.parsed_response
|
|
|
791
792
|
|
|
792
793
|
[Full API documentation](https://www.listennotes.com/api/docs/#put-api-v2-playlists-id)
|
|
793
794
|
|
|
795
|
+
### delete_playlist
|
|
796
|
+
|
|
797
|
+
Delete a playlist.
|
|
798
|
+
|
|
799
|
+
`DELETE /playlists/{id}`
|
|
800
|
+
|
|
801
|
+
Permanently delete a playlist, including all episode and podcast references saved in this specific playlist and their notes. The actual episodes and podcasts remain in the Listen Notes podcast database.
|
|
802
|
+
|
|
803
|
+
**Warning: Deletion cannot be undone. Once deleted, the playlist is gone, regardless of how many episodes or podcasts it contains. You, the developer, are responsible for adding a confirmation step in your app's UI before calling this endpoint to prevent accidental deletion.**
|
|
804
|
+
|
|
805
|
+
Only playlists owned by your admin API account can be modified; contributor membership does not grant write access.
|
|
806
|
+
|
|
807
|
+
```ruby
|
|
808
|
+
require "podcast_api"
|
|
809
|
+
|
|
810
|
+
client = PodcastApi::Client.new(api_key: ENV["LISTEN_API_KEY"])
|
|
811
|
+
response = client.delete_playlist(**{
|
|
812
|
+
'id' => 'm1pe7z60bsw'
|
|
813
|
+
})
|
|
814
|
+
puts response.parsed_response
|
|
815
|
+
```
|
|
816
|
+
|
|
817
|
+
[Full API documentation](https://www.listennotes.com/api/docs/#delete-api-v2-playlists-id)
|
|
818
|
+
|
|
794
819
|
### add_playlist_item
|
|
795
820
|
|
|
796
821
|
Add an episode or podcast to a playlist.
|
data/lib/api-contract.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schema_version": 1,
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.1.0",
|
|
4
4
|
"operations": [
|
|
5
5
|
{
|
|
6
6
|
"operationId": "search",
|
|
@@ -815,6 +815,25 @@
|
|
|
815
815
|
"summary": "Update playlist metadata.",
|
|
816
816
|
"description": "Update any subset of name, description, visibility, and type. Omitted fields remain unchanged; at least one field is required. Switching to private rotates the playlist RSS secret. Type selects the saved default view (episode_list or podcast_list) and the returned listennotes_url; changing it preserves all existing episodes and podcasts.\n\nOnly playlists owned by your admin API account can be modified; contributor membership does not grant write access."
|
|
817
817
|
},
|
|
818
|
+
{
|
|
819
|
+
"operationId": "deletePlaylist",
|
|
820
|
+
"func": "delete_playlist",
|
|
821
|
+
"available_from": "3.1.0",
|
|
822
|
+
"method": "DELETE",
|
|
823
|
+
"path": "/playlists/{id}",
|
|
824
|
+
"parameters": [
|
|
825
|
+
{
|
|
826
|
+
"name": "id",
|
|
827
|
+
"in": "path",
|
|
828
|
+
"required": true
|
|
829
|
+
}
|
|
830
|
+
],
|
|
831
|
+
"example_params": {
|
|
832
|
+
"id": "m1pe7z60bsw"
|
|
833
|
+
},
|
|
834
|
+
"summary": "Delete a playlist.",
|
|
835
|
+
"description": "Permanently delete a playlist, including all episode and podcast references saved in this specific playlist and their notes. The actual episodes and podcasts remain in the Listen Notes podcast database.\n\n**Warning: Deletion cannot be undone. Once deleted, the playlist is gone, regardless of how many episodes or podcasts it contains. You, the developer, are responsible for adding a confirmation step in your app's UI before calling this endpoint to prevent accidental deletion.**\n\nOnly playlists owned by your admin API account can be modified; contributor membership does not grant write access."
|
|
836
|
+
},
|
|
818
837
|
{
|
|
819
838
|
"operationId": "addPlaylistItem",
|
|
820
839
|
"func": "add_playlist_item",
|
data/lib/api_methods.rb
CHANGED
|
@@ -138,6 +138,11 @@ module PodcastApi
|
|
|
138
138
|
[], kwargs)
|
|
139
139
|
end
|
|
140
140
|
|
|
141
|
+
def delete_playlist(**kwargs)
|
|
142
|
+
request_api('DELETE', '/playlists/{id}',
|
|
143
|
+
[], kwargs)
|
|
144
|
+
end
|
|
145
|
+
|
|
141
146
|
def add_playlist_item(**kwargs)
|
|
142
147
|
request_api('POST', '/playlists/{id}/items',
|
|
143
148
|
[], kwargs)
|
data/lib/version.rb
CHANGED