-
Notifications
You must be signed in to change notification settings - Fork 1
/
schema.graphql
283 lines (217 loc) · 6.95 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
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
scalar JSON
scalar Cursor
enum Directory {
ITUNES
FYYD
PANOPTIKUM
PODCASTINDEXORG
INTERNETARCHIVE
PODCHASER
LISTENNOTES
ARDAUDIOTHEK
SPOTIFY
}
type ImageType implements Image {
url: URL!
description: String
attribution: String
}
type ShowType implements Node & Collection & Podcast {
"A globally unique identifier. Can be used in various places throughout the system to identify this single value."
nodeId: ID!
externalIds(system: Directory): [String!]
title: String!
subtitle: String
summary: String!
description: HTML
image(aspect: AspectRatio): Image
imageUrl: URL @deprecated(reason: "try to use image.url if possible")
link: URL
type: PodcastVariant
episodes: ItemsConnection
feedUrls: [URL!]
language: String
meta: JSON
_raw: JSON @deprecated(reason: "only for debugging")
}
type ItemType implements Node & Item {
"A globally unique identifier. Can be used in various places throughout the system to identify this single value."
nodeId: ID!
guid: ID!
externalIds(system: Directory): [String!]
title(variant: TitleVariant): String!
subtitle: String
summary: String
description: HTML
publicationDate: Datetime!
depublicationDate: Datetime
duration: Duration!
durationSeconds: Int!
link: URL
image(aspect: AspectRatio): Image
imageUrl: URL @deprecated(reason: "try to use image.url if possible")
tags: JSON
subjects: JSON
episodeNumber: Int
groupingId: ID
isPublished: Boolean!
audios: [Asset!]!
files: [Asset!]
contributors: [Contributor!]
chapters: [Chapter!],
#transcripts: [Transcript!]
show: Collection
nextEpisode: Item
_raw: JSON @deprecated(reason: "only for debugging")
}
type AssetType implements Asset {
"absolute path to media asset"
url: URL!
"file size in byte"
size: Int!
"title to be displayed in download tab e.g. `MPEG-4 AAC Audio (m4a)`"
title: String
"media asset mimeType e.g. `audio/mp4`"
mimeType: String!
}
type ContributorType implements Contributor {
"used as a reference e.g. in transcripts"
id: ID!
uri: URL!
"name of the contributor e.g. `Hans Meier`"
name: String!
"avatar e.g. profile photo of the contributor"
avatar: Image
avatarUrl: URL @deprecated(reason: "try to use avatar.url if possible")
#"""contributors group e.g. { id: "1", slug: "onair", title: "On Air" }"""
#group: ContributorGroup
wikidataId: String
}
"A filter to be used against `Item` object types. All fields are combined with a logical ‘and.’"
input ItemFilter {
"Filter by the object’s `id` field."
id: StringFilter
#"Filter by the object’s `publishDate` field."
#publicationDate: DatetimeFilter
"Filter by the object’s `title` field."
title: StringFilter
"Filter by the object’s `groupId` field."
groupingId: StringFilter
"Filter by the object’s `episodeNumber` field."
episodeNumber: IntFilter
"Checks for all expressions in this list."
and: [ItemFilter!]
"Checks for any expressions in this list."
or: [ItemFilter!]
"Negates the expression."
not: ItemFilter
}
# Methods to use when ordering `Item`.
enum ItemsOrderBy {
NATURAL
ID_ASC
ID_DESC
PUBLICATION_DATE_ASC
PUBLICATION_DATE_DESC
TITLE_ASC
TITLE_DESC
GROUP_ID_ASC
GROUP_ID_DESC
GROUP_NUMBER_ASC
GROUP_NUMBER_DESC
}
type OrganizationType implements Node & Organization {
"A globally unique identifier. Can be used in various places throughout the system to identify this single value."
nodeId: ID!
name: String!
uri: URL
wikidataId: String
image(aspect: AspectRatio): Image
}
# Methods to use when ordering `Organization`.
enum OrganizationsOrderBy {
NATURAL
ID_ASC
ID_DESC
NAME_ASC
NAME_DESC
}
type ShowsConnection implements CollectionConnection {
nodes: [ShowType!]!
pageInfo: PageInfo!
totalCount: Int!
}
# The root query type which gives access points into the data universe.
type Query implements Node & AudioQuery {
"Exposes the root query type nested one level down. This is helpful for Relay 1 which can only query top level fields if they are in a particular form."
query: Query!
"version, for backwards compability with other JSON formats"
version: Int
"The root query type must be a `Node` to work well with Relay 1 mutations. This just resolves to `query`."
nodeId: ID!
"Fetches an object given its globally unique `ID`."
node(
"The globally unique `ID`."
nodeId: ID!
): Node
item(guid: ID!, source: Directory): Item
show(id: ID!, source: Directory): ShowType
contributor(uri: URL!, source: Directory): Contributor
contributorById(id: ID!, source: Directory): Contributor
organization(name: String!, source: Directory): Organization
#publicationService(id: ID!): PublicationService
"Reads and enables pagination through a set of `Item`."
items(
"Only read the first `n` values of the set."
first: Int
"Only read the last `n` values of the set."
last: Int
"Skip the first `n` values from our `after` cursor, an alternative to cursor based pagination. May not be used with `last`."
offset: Int
"Read all values in the set before (above) this cursor."
before: Cursor
"Read all values in the set after (below) this cursor."
after: Cursor
"The method to use when ordering `Item`."
orderBy: [ItemsOrderBy!] = [PRIMARY_KEY_ASC]
#"A filter to be used in determining which values should be returned by the collection."
#filter: ItemFilter
source: Directory
): ItemsConnection
"Reads and enables pagination through a set of `Show`."
shows(
"Only read the first `n` values of the set."
first: Int
"Only read the last `n` values of the set."
last: Int
"Skip the first `n` values from our `after` cursor, an alternative to cursor based pagination. May not be used with `last`."
offset: Int
"Read all values in the set before (above) this cursor."
before: Cursor
"Read all values in the set after (below) this cursor."
after: Cursor
#"The method to use when ordering `Show`."
#orderBy: [ShowsOrderBy!] = [PRIMARY_KEY_ASC]
#"A filter to be used in determining which values should be returned by the collection."
#filter: ShowFilter
source: Directory
): ShowsConnection
"Reads and enables pagination through a set of `Organization`."
organizations(
"Only read the first `n` values of the set."
first: Int
"Only read the last `n` values of the set."
last: Int
"Skip the first `n` values from our `after` cursor, an alternative to cursor based pagination. May not be used with `last`."
offset: Int
"Read all values in the set before (above) this cursor."
before: Cursor
"Read all values in the set after (below) this cursor."
after: Cursor
"The method to use when ordering `Organization`."
orderBy: [OrganizationsOrderBy!] = [PRIMARY_KEY_ASC]
#"A filter to be used in determining which values should be returned by the collection."
#filter: OrganizationFilter
source: Directory
): OrganizationsConnection
}