schema.graphql 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. # -----------------------------------------------
  2. # !!! THIS FILE WAS GENERATED BY TYPE-GRAPHQL !!!
  3. # !!! DO NOT MODIFY THIS FILE BY YOURSELF !!!
  4. # -----------------------------------------------
  5. type ChannelFollowsInfo {
  6. follows: Int!
  7. id: ID!
  8. }
  9. type EntityViewsInfo {
  10. id: ID!
  11. views: Int!
  12. }
  13. type Mutation {
  14. """Add a single view to the target video's count"""
  15. addVideoView(categoryId: ID, channelId: ID!, videoId: ID!): EntityViewsInfo!
  16. """Add a single follow to the target channel"""
  17. followChannel(channelId: ID!): ChannelFollowsInfo!
  18. """Remove a single follow from the target channel"""
  19. unfollowChannel(channelId: ID!): ChannelFollowsInfo!
  20. }
  21. type Query {
  22. """Get follows counts for a list of channels"""
  23. batchedChannelFollows(channelIdList: [ID!]!): [ChannelFollowsInfo]!
  24. """Get views counts for a list of channels"""
  25. batchedChannelsViews(channelIdList: [ID!]!): [EntityViewsInfo]!
  26. """Get views counts for a list of videos"""
  27. batchedVideoViews(videoIdList: [ID!]!): [EntityViewsInfo]!
  28. """Get follows count for a single channel"""
  29. channelFollows(channelId: ID!): ChannelFollowsInfo
  30. """Get views count for a single channel"""
  31. channelViews(channelId: ID!): EntityViewsInfo
  32. """Get most viewed list of categories"""
  33. mostViewedCategories(limit: Int, period: Int!): [EntityViewsInfo!]
  34. """Get most viewed list of categories of all time"""
  35. mostViewedCategoriesAllTime(limit: Int!): [EntityViewsInfo!]
  36. """Get most viewed list of channels"""
  37. mostViewedChannels(limit: Int, period: Int!): [EntityViewsInfo!]
  38. """Get most viewed list of channels of all time"""
  39. mostViewedChannelsAllTime(limit: Int!): [EntityViewsInfo!]
  40. """Get most viewed list of videos"""
  41. mostViewedVideos(limit: Int, period: Int!): [EntityViewsInfo!]
  42. """Get most viewed list of videos of all time"""
  43. mostViewedVideosAllTime(limit: Int!): [EntityViewsInfo!]
  44. """Get views count for a single video"""
  45. videoViews(videoId: ID!): EntityViewsInfo
  46. }