11type Query {
2+ articles (sportsType : String ): [ArticleType ]
3+
24 youtubeVideos : [YoutubeVideoType ]
35
46 youtubeVideo (id : String ! ): YoutubeVideoType
57
6- games : [GameType ]
8+ games ( "Number of games to return" limit : Int = 100 , "Number of games to skip" offset : Int = 0 ) : [GameType ]
79
810 game (id : String ! ): GameType
911
10- gameByData (city : String ! , date : String ! , gender : String ! , location : String , opponentId : String ! , sport : String ! , state : String ! , time : String ! ): GameType
12+ gameByData (city : String ! , date : String ! , gender : String ! , location : String , opponentId : String ! , sport : String ! , state : String ! , time : String ! , ticketLink : String ): GameType
1113
1214 gamesBySport (sport : String ! ): [GameType ]
1315
@@ -22,6 +24,30 @@ type Query {
2224 teamByName (name : String ! ): TeamType
2325}
2426
27+ """
28+ A GraphQL type representing a news article.
29+
30+ Attributes:
31+ - title: The title of the article
32+ - image: The filename of the article's main image
33+ - sports_type: The specific sport category
34+ - published_at: The publication date
35+ - url: The URL to the full article
36+ """
37+ type ArticleType {
38+ id : String
39+
40+ title : String !
41+
42+ image : String
43+
44+ sportsType : String !
45+
46+ publishedAt : String !
47+
48+ url : String !
49+ }
50+
2551"""
2652A GraphQL type representing a YouTube video.
2753
@@ -42,6 +68,8 @@ type YoutubeVideoType {
4268
4369 thumbnail : String !
4470
71+ b64Thumbnail : String !
72+
4573 url : String !
4674
4775 publishedAt : String !
@@ -63,6 +91,7 @@ Attributes:
6391 - `time`: The time of the game. (optional)
6492 - `box_score`: The box score of the game.
6593 - `score_breakdown`: The score breakdown of the game.
94+ - `ticket_link`: The ticket link of the game. (optional)
6695"""
6796type GameType {
6897 id : String
@@ -90,6 +119,10 @@ type GameType {
90119 scoreBreakdown : [[String ]]
91120
92121 team : TeamType
122+
123+ utcDate : String
124+
125+ ticketLink : String
93126}
94127
95128"""
@@ -133,6 +166,7 @@ Attributes:
133166 - `id`: The ID of the team (optional).
134167 - `color`: The color of the team.
135168 - `image`: The image of the team (optional).
169+ - `b64_image`: The base64 encoded image of the team (optional).
136170 - `name`: The name of the team.
137171"""
138172type TeamType {
@@ -142,24 +176,31 @@ type TeamType {
142176
143177 image : String
144178
179+ b64Image : String
180+
145181 name : String !
146182}
147183
148184type Mutation {
149185 """
150186 Creates a new game.
151187 """
152- createGame (boxScore : String , city : String ! , date : String ! , gender : String ! , location : String , opponentId : String ! , result : String , scoreBreakdown : String , sport : String ! , state : String ! , time : String ! ): CreateGame
188+ createGame (boxScore : String , city : String ! , date : String ! , gender : String ! , location : String , opponentId : String ! , result : String , scoreBreakdown : String , sport : String ! , state : String ! , ticketLink : String , time : String ! , utcDate : String ): CreateGame
153189
154190 """
155191 Creates a new team.
156192 """
157- createTeam (color : String ! , image : String , name : String ! ): CreateTeam
193+ createTeam (b64Image : String , color : String ! , image : String , name : String ! ): CreateTeam
158194
159195 """
160196 Creates a new youtube video.
161197 """
162- createYoutubeVideo (description : String ! , id : String ! , publishedAt : String ! , thumbnail : String ! , title : String ! , url : String ! ): CreateYoutubeVideo
198+ createYoutubeVideo (b64Thumbnail : String ! , description : String ! , id : String ! , publishedAt : String ! , thumbnail : String ! , title : String ! , url : String ! ): CreateYoutubeVideo
199+
200+ """
201+ Creates a new article.
202+ """
203+ createArticle (image : String , publishedAt : String ! , slug : String ! , sportsType : String ! , title : String ! , url : String ! ): CreateArticle
163204}
164205
165206type CreateGame {
@@ -174,6 +215,10 @@ type CreateYoutubeVideo {
174215 youtubeVideo : YoutubeVideoType
175216}
176217
218+ type CreateArticle {
219+ article : ArticleType
220+ }
221+
177222"""
178223A GraphQL Schema defines the capabilities of a GraphQL server. It exposes all available types and directives on the server, as well as the entry points for query, mutation and subscription operations.
179224"""
0 commit comments