content.graphql 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197
  1. "Category of media channel"
  2. type ChannelCategory @entity {
  3. id: ID!
  4. "The name of the category"
  5. name: String @fulltext(query: "channelCategoriesByName")
  6. channels: [Channel!]! @derivedFrom(field: "category")
  7. createdInBlock: Int!
  8. }
  9. type Language @entity {
  10. "Runtime entity identifier (EntityId)"
  11. id: ID!
  12. "Language identifier ISO 639-1"
  13. iso: String!
  14. createdInBlock: Int!
  15. }
  16. type Channel @entity {
  17. "Runtime entity identifier (EntityId)"
  18. id: ID!
  19. "Member owning the channel (if any)"
  20. ownerMember: Membership
  21. "Curator group owning the channel (if any)"
  22. ownerCuratorGroup: CuratorGroup
  23. category: ChannelCategory
  24. "Reward account where revenue is sent if set."
  25. rewardAccount: String
  26. "Destination account for the prize associated with channel deletion"
  27. deletionPrizeDestAccount: String!
  28. "The title of the Channel"
  29. title: String @fulltext(query: "search")
  30. "The description of a Channel"
  31. description: String
  32. "Channel's cover (background) photo asset. Recommended ratio: 16:9."
  33. coverPhoto: StorageDataObject
  34. "Channel's avatar photo asset."
  35. avatarPhoto: StorageDataObject
  36. ##########################
  37. "Flag signaling whether a channel is public."
  38. isPublic: Boolean
  39. "Flag signaling whether a channel is censored."
  40. isCensored: Boolean!
  41. "The primary langauge of the channel's content"
  42. language: Language
  43. videos: [Video!]! @derivedFrom(field: "channel")
  44. createdInBlock: Int!
  45. }
  46. type CuratorGroup @entity {
  47. "Runtime identifier"
  48. id: ID!
  49. "Curators belonging to this group"
  50. curatorIds: [Int!]!
  51. "Is group active or not"
  52. isActive: Boolean!
  53. channels: [Channel!]! @derivedFrom(field: "ownerCuratorGroup")
  54. }
  55. type VideoCategory @entity {
  56. "Runtime identifier"
  57. id: ID!
  58. "The name of the category"
  59. name: String @fulltext(query: "videoCategoriesByName")
  60. videos: [Video!]! @derivedFrom(field: "category")
  61. createdInBlock: Int!
  62. }
  63. type Video @entity {
  64. "Runtime identifier"
  65. id: ID!
  66. "Reference to member's channel"
  67. channel: Channel!
  68. "Reference to a video category"
  69. category: VideoCategory
  70. "The title of the video"
  71. title: String @fulltext(query: "search")
  72. "The description of the Video"
  73. description: String
  74. "Video duration in seconds"
  75. duration: Int
  76. "Video thumbnail asset (recommended ratio: 16:9)"
  77. thumbnailPhoto: StorageDataObject
  78. ##########################
  79. "Video's main langauge"
  80. language: Language
  81. "Whether or not Video contains marketing"
  82. hasMarketing: Boolean
  83. "If the Video was published on other platform before beeing published on Joystream - the original publication date"
  84. publishedBeforeJoystream: DateTime
  85. "Whether the Video is supposed to be publically displayed"
  86. isPublic: Boolean
  87. "Flag signaling whether a video is censored."
  88. isCensored: Boolean!
  89. "Whether the Video contains explicit material."
  90. isExplicit: Boolean
  91. "License under the video is published"
  92. license: License
  93. "Video media asset"
  94. media: StorageDataObject
  95. ##########################
  96. "Video file metadata"
  97. mediaMetadata: VideoMediaMetadata
  98. createdInBlock: Int!
  99. "Is video featured or not"
  100. isFeatured: Boolean!
  101. }
  102. type VideoMediaMetadata @entity {
  103. "Unique identifier"
  104. id: ID!
  105. "Encoding of the video media object"
  106. encoding: VideoMediaEncoding
  107. "Video media width in pixels"
  108. pixelWidth: Int
  109. "Video media height in pixels"
  110. pixelHeight: Int
  111. "Video media size in bytes"
  112. size: BigInt
  113. video: Video @derivedFrom(field: "mediaMetadata")
  114. createdInBlock: Int!
  115. }
  116. type VideoMediaEncoding @entity {
  117. "Encoding of the video media object"
  118. codecName: String
  119. "Media container format"
  120. container: String
  121. "Content MIME type"
  122. mimeMediaType: String
  123. }
  124. type License @entity {
  125. "Unique identifier"
  126. id: ID!
  127. "License code defined by Joystream"
  128. code: Int
  129. "Attribution (if required by the license)"
  130. attribution: String
  131. "Custom license content"
  132. custom_text: String
  133. }