summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/SevereCloud/vksdk/v2/api/podcasts.go
diff options
context:
space:
mode:
authorIvanik <ivan170102@gmail.com>2021-01-29 04:25:14 +0500
committerGitHub <noreply@github.com>2021-01-29 00:25:14 +0100
commit8764be74616bde87bbbf6c32901cd9f43264d1e0 (patch)
tree88902ba17d6a6d245cadb7e0b277bee7ef424f99 /vendor/github.com/SevereCloud/vksdk/v2/api/podcasts.go
parent5dd15ef8e716c65accb6cd021095c0e19913d55f (diff)
downloadmatterbridge-msglm-8764be74616bde87bbbf6c32901cd9f43264d1e0.tar.gz
matterbridge-msglm-8764be74616bde87bbbf6c32901cd9f43264d1e0.tar.bz2
matterbridge-msglm-8764be74616bde87bbbf6c32901cd9f43264d1e0.zip
Add vk bridge (#1372)
* Add vk bridge * Vk bridge attachments * Vk bridge forwarded messages * Vk bridge sample config and code cleanup * Vk bridge add vendor * Vk bridge message edit * Vk bridge: fix fetching names of other bots * Vk bridge: code cleanup * Vk bridge: fix shadows declaration * Vk bridge: remove UseFileURL
Diffstat (limited to 'vendor/github.com/SevereCloud/vksdk/v2/api/podcasts.go')
-rw-r--r--vendor/github.com/SevereCloud/vksdk/v2/api/podcasts.go179
1 files changed, 179 insertions, 0 deletions
diff --git a/vendor/github.com/SevereCloud/vksdk/v2/api/podcasts.go b/vendor/github.com/SevereCloud/vksdk/v2/api/podcasts.go
new file mode 100644
index 00000000..8534d0fc
--- /dev/null
+++ b/vendor/github.com/SevereCloud/vksdk/v2/api/podcasts.go
@@ -0,0 +1,179 @@
+package api // import "github.com/SevereCloud/vksdk/v2/api"
+
+import (
+ "github.com/SevereCloud/vksdk/v2/object"
+)
+
+// PodcastsGetCatalogResponse struct.
+type PodcastsGetCatalogResponse struct {
+ Items []object.PodcastsItem `json:"items"`
+}
+
+// PodcastsGetCatalog method.
+//
+// extended=0
+//
+// https://vk.com/dev/podcasts.getCatalog
+func (vk *VK) PodcastsGetCatalog(params Params) (response PodcastsGetCatalogResponse, err error) {
+ err = vk.RequestUnmarshal("podcasts.getCatalog", &response, params, Params{"extended": false})
+
+ return
+}
+
+// PodcastsGetCatalogExtendedResponse struct.
+type PodcastsGetCatalogExtendedResponse struct {
+ Items []object.PodcastsItem `json:"items"`
+ object.ExtendedResponse
+}
+
+// PodcastsGetCatalogExtended method.
+//
+// extended=1
+//
+// https://vk.com/dev/podcasts.getCatalog
+func (vk *VK) PodcastsGetCatalogExtended(params Params) (response PodcastsGetCatalogExtendedResponse, err error) {
+ err = vk.RequestUnmarshal("podcasts.getCatalog", &response, params, Params{"extended": true})
+
+ return
+}
+
+// PodcastsGetCategoriesResponse struct.
+type PodcastsGetCategoriesResponse []object.PodcastsCategory
+
+// PodcastsGetCategories method.
+//
+// https://vk.com/dev/podcasts.getCategories
+func (vk *VK) PodcastsGetCategories(params Params) (response PodcastsGetCategoriesResponse, err error) {
+ err = vk.RequestUnmarshal("podcasts.getCategories", &response, params)
+ return
+}
+
+// PodcastsGetEpisodesResponse struct.
+type PodcastsGetEpisodesResponse struct {
+ Count int `json:"count"`
+ Items []object.PodcastsEpisode `json:"items"`
+}
+
+// PodcastsGetEpisodes method.
+//
+// https://vk.com/dev/podcasts.getEpisodes
+func (vk *VK) PodcastsGetEpisodes(params Params) (response PodcastsGetEpisodesResponse, err error) {
+ err = vk.RequestUnmarshal("podcasts.getEpisodes", &response, params)
+ return
+}
+
+// PodcastsGetFeedResponse struct.
+type PodcastsGetFeedResponse struct {
+ Items []object.PodcastsEpisode `json:"items"`
+ NextFrom string `json:"next_from"`
+}
+
+// PodcastsGetFeed method.
+//
+// extended=0
+//
+// https://vk.com/dev/podcasts.getFeed
+func (vk *VK) PodcastsGetFeed(params Params) (response PodcastsGetFeedResponse, err error) {
+ err = vk.RequestUnmarshal("podcasts.getFeed", &response, params, Params{"extended": false})
+
+ return
+}
+
+// PodcastsGetFeedExtendedResponse struct.
+type PodcastsGetFeedExtendedResponse struct {
+ Items []object.PodcastsEpisode `json:"items"`
+ NextFrom string `json:"next_from"`
+ object.ExtendedResponse
+}
+
+// PodcastsGetFeedExtended method.
+//
+// extended=1
+//
+// https://vk.com/dev/podcasts.getFeed
+func (vk *VK) PodcastsGetFeedExtended(params Params) (response PodcastsGetFeedExtendedResponse, err error) {
+ err = vk.RequestUnmarshal("podcasts.getFeed", &response, params, Params{"extended": true})
+
+ return
+}
+
+// PodcastsGetStartPageResponse struct.
+type PodcastsGetStartPageResponse struct {
+ Order []string `json:"order"`
+ InProgress []object.PodcastsEpisode `json:"in_progress"`
+ Bookmarks []object.PodcastsEpisode `json:"bookmarks"`
+ Articles []object.Article `json:"articles"`
+ StaticHowTo []bool `json:"static_how_to"`
+ FriendsLiked []object.PodcastsEpisode `json:"friends_liked"`
+ Subscriptions []object.PodcastsEpisode `json:"subscriptions"`
+ CategoriesList []object.PodcastsCategory `json:"categories_list"`
+ RecommendedEpisodes []object.PodcastsEpisode `json:"recommended_episodes"`
+ Catalog []struct {
+ Category object.PodcastsCategory `json:"category"`
+ Items []object.PodcastsItem `json:"items"`
+ } `json:"catalog"`
+}
+
+// PodcastsGetStartPage method.
+//
+// extended=0
+//
+// https://vk.com/dev/podcasts.getStartPage
+func (vk *VK) PodcastsGetStartPage(params Params) (response PodcastsGetStartPageResponse, err error) {
+ err = vk.RequestUnmarshal("podcasts.getStartPage", &response, params, Params{"extended": false})
+
+ return
+}
+
+// PodcastsGetStartPageExtendedResponse struct.
+type PodcastsGetStartPageExtendedResponse struct {
+ Order []string `json:"order"`
+ InProgress []object.PodcastsEpisode `json:"in_progress"`
+ Bookmarks []object.PodcastsEpisode `json:"bookmarks"`
+ Articles []object.Article `json:"articles"`
+ StaticHowTo []bool `json:"static_how_to"`
+ FriendsLiked []object.PodcastsEpisode `json:"friends_liked"`
+ Subscriptions []object.PodcastsEpisode `json:"subscriptions"`
+ CategoriesList []object.PodcastsCategory `json:"categories_list"`
+ RecommendedEpisodes []object.PodcastsEpisode `json:"recommended_episodes"`
+ Catalog []struct {
+ Category object.PodcastsCategory `json:"category"`
+ Items []object.PodcastsItem `json:"items"`
+ } `json:"catalog"`
+ object.ExtendedResponse
+}
+
+// PodcastsGetStartPageExtended method.
+//
+// extended=1
+//
+// https://vk.com/dev/podcasts.getStartPage
+func (vk *VK) PodcastsGetStartPageExtended(params Params) (response PodcastsGetStartPageExtendedResponse, err error) {
+ err = vk.RequestUnmarshal("podcasts.getStartPage", &response, params, Params{"extended": true})
+
+ return
+}
+
+// PodcastsMarkAsListened method.
+//
+// https://vk.com/dev/podcasts.markAsListened
+func (vk *VK) PodcastsMarkAsListened(params Params) (response int, err error) {
+ err = vk.RequestUnmarshal("podcasts.markAsListened", &response, params)
+ return
+}
+
+// PodcastsSubscribe method.
+//
+// https://vk.com/dev/podcasts.subscribe
+func (vk *VK) PodcastsSubscribe(params Params) (response int, err error) {
+ err = vk.RequestUnmarshal("podcasts.subscribe", &response, params)
+ return
+}
+
+// PodcastsUnsubscribe method.
+//
+// https://vk.com/dev/podcasts.unsubscribe
+func (vk *VK) PodcastsUnsubscribe(params Params) (response int, err error) {
+ err = vk.RequestUnmarshal("podcasts.unsubscribe", &response, params)
+ return
+}