forked from Joystream/orion
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathschema.graphql
145 lines (117 loc) · 3.43 KB
/
schema.graphql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
# -----------------------------------------------
# !!! THIS FILE WAS GENERATED BY TYPE-GRAPHQL !!!
# !!! DO NOT MODIFY THIS FILE BY YOURSELF !!!
# -----------------------------------------------
type Admin {
isKilled: Boolean!
}
type CategoryFeaturedVideos {
categoryFeaturedVideos: [FeaturedVideo!]!
categoryId: ID!
}
type ChannelFollowsInfo {
follows: Int!
id: ID!
}
type ChannelReportInfo {
channelId: ID!
createdAt: DateTime!
id: ID!
rationale: String!
reporterIp: String!
}
enum ChannelReportOrderByInput {
createdAt_ASC
createdAt_DESC
}
input ChannelReportsWhereInput {
channelId: ID
createdAt_gt: DateTime
createdAt_lt: DateTime
reporterIp: String
}
"""
The javascript `Date` as string. Type represents date and time as the ISO Date string.
"""
scalar DateTime
type EntityViewsInfo {
id: ID!
views: Int!
}
type FeaturedVideo {
videoCutUrl: String
videoId: ID!
}
input FeaturedVideoInput {
videoCutUrl: String
videoId: ID!
}
type GeneratedSignature {
"""App signature converted to hexadecimal string."""
signature: String!
}
type Mutation {
"""Add a single view to the target video's count"""
addVideoView(categoryId: ID, channelId: ID!, videoId: ID!): EntityViewsInfo!
"""Add a single follow to the target channel"""
followChannel(channelId: ID!): ChannelFollowsInfo!
"""Report a channel"""
reportChannel(channelId: ID!, rationale: String!): ChannelReportInfo!
"""Report a video"""
reportVideo(rationale: String!, videoId: ID!): VideoReportInfo!
setCategoryFeaturedVideos(categoryId: ID!, videos: [FeaturedVideoInput!]!): [FeaturedVideo!]!
setKillSwitch(isKilled: Boolean!): Admin!
setVideoHero(newVideoHero: VideoHeroInput!): VideoHero!
signAppActionCommitment(assets: String!, creatorId: String!, rawAction: String!, rawAppActionMetadata: String!): GeneratedSignature!
"""Remove a single follow from the target channel"""
unfollowChannel(channelId: ID!): ChannelFollowsInfo!
}
type Query {
"""Set killed instance"""
admin: Admin!
"""Get featured videos for all categories"""
allCategoriesFeaturedVideos(videosLimit: Int!): [CategoryFeaturedVideos!]!
"""Get featured videos for a given video category"""
categoryFeaturedVideos(categoryId: ID!): [FeaturedVideo!]!
"""Get list of most viewed categories in a given time period"""
mostViewedCategories(
limit: Int
"""timePeriodDays must take one of the following values: 7, 30"""
timePeriodDays: Int!
): [EntityViewsInfo!]
"""Get list of most viewed categories of all time"""
mostViewedCategoriesAllTime(limit: Int!): [EntityViewsInfo!]
reportedChannels(limit: Int = 30, orderBy: ChannelReportOrderByInput = createdAt_DESC, skip: Int, where: ChannelReportsWhereInput): [ChannelReportInfo!]!
reportedVideos(limit: Int = 30, orderBy: VideoReportOrderByInput = createdAt_DESC, skip: Int, where: VideoReportsWhereInput): [VideoReportInfo!]!
"""Get current video hero"""
videoHero: VideoHero!
}
type VideoHero {
heroPosterUrl: String!
heroTitle: String!
heroVideoCutUrl: String!
videoId: ID!
}
input VideoHeroInput {
heroPosterUrl: String!
heroTitle: String!
heroVideoCutUrl: String!
videoId: ID!
}
type VideoReportInfo {
createdAt: DateTime!
id: ID!
rationale: String!
reporterIp: String!
videoId: ID!
}
enum VideoReportOrderByInput {
createdAt_ASC
createdAt_DESC
}
input VideoReportsWhereInput {
createdAt_gt: DateTime
createdAt_lt: DateTime
reporterIp: String
videoId: ID
}