OBJECT
Query
Root fields to access the Twitch API.
link GraphQL Schema definition
1 type Query { 2 3 # Get the context that corresponds to an upcoming ad request made client side. 4 AdRequestContext!): AdContext ( : 5 6 # Get a single AdCreative. 7 String!, : ID!): AdCreative ( : 8 9 # Get all tags. 10 Int, : Cursor, : TagScope): TagConnection ( : 11 12 # Get AutoMod evaluation of text using AutoMod rule. 13 AutoModContentInput!): AutoModContent ( : 14 15 # A list of global chat badges. 16 Badge] : [ 17 18 # Gets a list of Bits offers for a logged out user, for use on the Bits landing 19 # page. 20 BitsOffer!] : [ 21 22 # Returns a challenge by its ID. 23 ID!): ChannelChallenge ( : 24 25 # Get a list of the most recent changelog items. 26 Int): [ChangelogEntry!] ( : 27 28 # Get a channel by ID or name. 29 ID, : String): Channel ( : 30 31 # Get a channel/viewer pair by login. 32 String!, : String!): ChannelViewer ( : 33 34 # Get a list of channels, either by IDs or by their names. 35 ID!], : [String!]): [Channel] ( : [ 36 37 # Get the ban status of a usser with respect to a channel's chat room. 38 ID!, : ID!): ChatRoomBanStatus ( : 39 40 # GlobalCheerConfig contains information about (1) How to display Cheers and (2) 41 # What Cheermotes are globally available. 42 GlobalCheerConfig! : 43 44 # Get the logged-in user's authorizations for a client ID. 45 ID!): ClientAuthorization ( : 46 47 # Get a clip by slug. 48 ID!): Clip ( : 49 50 # Get the state of a cloud broadcast for the given broadcastID. 51 ID!): CloudBroadcast ( : 52 53 # Get the capabilities of a single cloud broadcast provider. 54 ID!): CloudBroadcastProvider ( : 55 56 # Get a single collection (playlist) item by its ID. 57 ID!, : CollectionOptions): Collection ( : 58 59 # Gets competition by ID. 60 ID!): Competition ( : 61 62 # The features the user has access to when organizing competitions with the Versus 63 # product. 64 CompetitionOrganizerCapability : 65 66 # Gets a paginated list of competitions, commonly by its state. If state is 67 # UNKNOWN, the query will default to LIVE competitions. 68 Int, : Cursor, : CompetitionState): CompetitionConnection ( : 69 70 # Get a privacy consent status from a user, e.g. GDPR or CCPA. 71 ID!): Consent ( : 72 73 # Get a content tag by tag ID. 74 ID!): Tag ( : 75 76 # Get content tags by tag IDs. 77 ID!]): [Tag!] ( : [ 78 79 # Get a Creator Camp article. 80 ID!, : String!): CreatorCampArticle ( : 81 82 # Get a Creator Camp category. 83 ID!): CreatorCampCategory ( : 84 85 # Get information populated in the Creator Dashboard. 86 ( 87 Time!, : 88 Time!, : 89 TimeSeriesPeriod! : 90 ): CreatorDashboard 91 92 # Get information for the Creator Home page. 93 CreatorHome : 94 95 # Get the chanel/viewer pair with the current user and the channelID. 96 ID!): ChannelViewer ( : 97 98 # The currently authenticated user. 99 # Returns null if the user is not authenticated. 100 User : 101 102 # Fetch a single directory by name and type. 103 String!, : DirectoryType!): Directory ( : 104 105 # Fetch a single drop by ID. This could be either an event or time based drop. 106 ID!): DropType ( : 107 108 # Fetch a single drop benefit by ID. 109 ID!, : ID!): DropBenefit ( : 110 111 # Fetch a single drop campaign by ID. 112 ID!): DropCampaign ( : 113 114 # Determine the currently logged in users eligibility for the specified drop. 115 ID!): DropEligibility ( : 116 117 # Get an emote by ID. 118 ID!): Emote ( : 119 120 # Get the current set of emote modifiers. 121 CommunityPointsEmoteModifier!] : [ 122 123 # Get an emote set by ID. 124 ID!): EmoteSet ( : 125 126 # Experiment properties for temporary use. 127 Experiment : 128 129 # Get an Extension by ID. Optionally, provide a specific version. If no version is 130 # provided, 131 # the released version of that extension is returned. 132 ID!, : String): Extension ( : 133 134 # Get an ExtensionCarousel by ID. The default carousel can be loaded by providing 135 # the ID: "default". 136 ID!): ExtensionCarousel ( : 137 138 # Fetch a paginated list of Extension Categories. Each Category will provide the 139 # first ten 140 # extensions sorted by popularity in that category. 141 Int, : Cursor): ExtensionCategoryConnection ( : 142 143 # Fetch a single category. Both slugs and ids are valid inputs for getting a 144 # category. 145 ID!): ExtensionCategory ( : 146 147 # Fetch a single Extension Client by ID. 148 # An ExtensionClient is the authorization component of an extension. 149 # Returns Null if the current user doesn't have access to the extension. 150 ID!): ExtensionClient ( : 151 152 # Fetch a paginated list of Extension Clients. 153 ID, : Cursor): ExtensionClientConnection ( : 154 155 # Fetch an ExtensionManifest by ID and version. 156 ID!, : String!): ExtensionManifest ( : 157 158 # Fetch a paginated list of ExtensionManifests. 159 ID!, : Cursor): ExtensionManifestConnection ( : 160 161 # Fetch a Summary of the state of an extension. The Cursor is used to page 162 # extension manifests. 163 ID!, : Cursor): ExtensionManifestsSummary ( : 164 165 # extensionRatingsCSVReportPresignedURL asks the ExtensionRatings backend if the 166 # given report is completed, and if 167 # so, to generate and return a presigned S3 URL that the devsite can use to allow 168 # the user to download it. 169 # If the URL is not ready yet, the response will be an empty string. 170 ( 171 String! : 172 ): ExtensionRatingsCSVReportPresignedURL 173 174 # Fetch the authentication settings for a particular extension. 175 ID!): ExtensionSecretsInfo ( : 176 177 # Fetch an ExtensionVersionDiscoveryManifest by ID and version. 178 ( 179 ID!, : 180 String! : 181 ): ExtensionVersionDiscoveryManifest 182 183 # Search extensions by text found in the Extension name, description or summary. 184 # The results are 185 # always returned in order of popularity. By default, all RELEASED and IN_TEST 186 # extensions are returned. 187 # Pass RELEASED as the value of 'state' to only return extensions in the RELEASED 188 # state. 189 ( 190 Int, : 191 Cursor, : 192 String, : 193 ExtensionStateFilter : 194 ): ExtensionConnection 195 196 # Fetch the sections & content that should be featured on mobile 197 # `language` is a letter code for the language the requesting user speaks (e.g. 198 # "en"). 199 String!): [FeaturedContentSection!] ( : 200 201 # Fetch streams that are featured on the front page, ordered by featurePriority 202 # ascending. 203 # DEPRECATED: `geolocation` is computed based on GeoIP with a fallback value of 204 # "US" and should be omitted 205 # `language` is a letter code for the language the requesting user speaks (ex. 206 # "en") 207 # By default returns 6 streams. 208 ( 209 Int, : 210 String, : 211 String, : 212 Boolean : 213 ): [FeaturedStream] 214 215 # Fetch VODs that should be featured on the homepage 216 # `language` is a letter code for the language the requesting user speaks (e.g. 217 # "en"). 218 ( 219 Int, : 220 String! : 221 ): [FeaturedVideo] @deprecated( reason: "Subject to change" ) 222 223 # Get a Feed by ID. 224 ID!): Feed @deprecated( reason: "No longer supported" ) ( : 225 226 # Convert a URL to an object that can be embedded into Twitch feeds. 227 String!): FeedEmbed @deprecated( reason: "No longer supported" ) ( : 228 229 # Get a feed item by ID. 230 ( 231 ID! : 232 ): FeedItemContent @deprecated( reason: "No longer supported" ) 233 234 # Get a single game as identified by its name or ID. At least one parameter must 235 # be provided. 236 String, : ID): Game ( : 237 238 # Fetch games based on a variety of sorting options. 239 # By default returns 10 games, sorted by highest ccu. 240 # DEPRECATED field arguments: locale, tags 241 # Use GameOptions instead. 242 ( 243 Int, : 244 Cursor, : 245 GameOptions, : 246 String, : 247 String!] : [ 248 ): GameConnection 249 250 # Get whether a username is available for registration. 251 String!): Boolean ( : 252 253 # Get key code information given a key code. 254 String!, : String): Claimable ( : 255 256 # Get a chat message by its id. 257 ID!): Message ( : 258 259 # Get a list of the most recent Mod View Newsfeed items. 260 Int): [ModViewNewsfeedEntry!] ( : 261 262 # Returns a developer organization by ID. 263 # User must be apart of the organization. 264 ID!): Organization ( : 265 266 # Gets a pending Twitch Developer Organization application of the currently 267 # authenticated user. 268 # This is deprecated due to multi-org and ability to have multiple applications. 269 OrganizationApplication @deprecated( reason: "Use pendingOrganizationApplications instead." ) : 270 271 # Gets a pending Twitch Developer Organization applications of the currently 272 # authenticated user. 273 OrganizationApplication!] : [ 274 275 # Get a list of sections(follows, recommendation) for the current user 276 # may not return all the requested section e.g requesting following section for 277 # logged out user. 278 PersonalSectionInput!): [PersonalSection!] ( : 279 280 # Returns a poll by its ID. 281 ID!): Poll ( : 282 283 # Returns a Prediction Event by its ID. 284 ID!): PredictionEvent ( : 285 286 # Get Current PrimeOffers for a given region based on country code (request info 287 # or query param) 288 # optional dateOverride to provide offers that would be displayed on that date 289 # optional countryCode to provide offers that are displayed for that country 290 # optional locale to provide offers displayed for the supplied locale. 291 Time, : String, : String): [PrimeOffer!]! ( : 292 293 # Retrieve currently live Prime Gaming offers for a given region using the new 294 # eligibility architecture. 295 # If provided, dateOverride is used to specify offers that would be live on the 296 # given date. 297 # If provided, countryCode is used to specify offers that would be live in the 298 # given region. 299 # If provided, locale is used to specify the offer content language for the given 300 # locale. 301 ( 302 Time, : 303 String, : 304 String : 305 ): [PrimeOfferWithEligibility!]! 306 307 # Retrieve currently live Prime Gaming offers for a given region. 308 # This query retrieves offer data without eligibility or entitlement information. 309 # If provided, dateOverride is used to specify offers that would be live on the 310 # given date. 311 # If provided, countryCode is used to specify offers that would be live in the 312 # given region. 313 # If provided, locale is used to specify the offer content language for the given 314 # locale. 315 ( 316 Time, : 317 String, : 318 String : 319 ): [PrimeOffer!]! 320 321 # PrimePromotions data - query supports optional identifiers for promotion strings 322 # but default behavior will use 323 # countryCode and userID to find available marketing promotions. For whitelisted 324 # QA users dateOverride can be provided. 325 ID!], : Time): [PrimePromotion]! ( : [ 326 327 # PrimeVideoBenefit returns a user's prime video benefits from Amazon. Requires an 328 # LWA token. 329 String!): PrimeVideoBenefit ( : 330 331 # Get details about a purchasable offer for the current logged in user. 332 # This field can only be requested if an OAuth token is supplied with the request. 333 # If the OAuth token is not supplied or if the offer does not exist, this will 334 # return null. 335 PurchasableOfferParams!): Offer ( : 336 337 # Fetch radio content based on the content type, optionally filtered by an Amazon 338 # Standard Identification Number. 339 ( 340 RadioContentType!, : 341 ID : 342 ): RadioContent @deprecated( reason: "Use specific user.radio queries instead." ) 343 344 # Fetch a group of recommended games. 345 # `recRequestID` is a tracking id created by the caller. This should be unique per 346 # request. 347 # `location` defines the source location of the recommended streams request (e.g. 348 # "TV_APPS"). 349 # `context` contains parameters that are used to personalize recommendations (e.g. 350 # "Platform"). 351 ( 352 Int, : 353 ID!, : 354 String!, : 355 RecommendationsContext! : 356 ): RecommendedGamesConnection 357 358 # Fetch a group of recommended streams. 359 # `recRequestID` is a tracking id created by the caller. This should be unique per 360 # request. 361 # `location` defines the source location of the recommended streams request (e.g. 362 # "LEFT_NAV"). 363 # `context` contains parameters that are used to personalize recommendations (e.g. 364 # "Platform"). 365 # `filters` is an optional parameter that can be used to filter recommendation 366 # results. 367 ( 368 Int, : 369 ID!, : 370 String!, : 371 RecommendationsContext!, : 372 StreamRecommendationsFilters : 373 ): RecommendedStreamsConnection 374 375 # Holds configuration necessary for calling Recurly. 376 PaymentSession): RecurlyConfigs ( : 377 378 # Get a message rejected by chat. 379 ID!): RejectedChatMessage ( : 380 381 # Get a list of valid reasons for a content type. 382 ReportContentType!): [ReportReason!] ( : 383 384 # Get a list of valid country and ToS reasons for a content types. 385 ( 386 ReportContentType! : 387 ): ReportToSAndCountryReasons 388 389 # Metadata about the request to the API. 390 RequestInfo! : 391 392 # Get a room by its ID. 393 ID!): Room ( : 394 395 # Get a schedule segment by ID. Additional options can be provided to get the 396 # segment relative to a 397 # different time or timezone. 398 ID!, : ScheduleSegmentOptions): ScheduleSegment ( : 399 400 # Get search results for a user's query. 401 ( 402 String!, : 403 String!, : 404 SearchOptions : 405 ): SearchResult @deprecated( reason: "Use the 'searchFor' query instead." ) 406 407 # Search for tags to apply to a channel. 408 String!, : Int): [Tag!] ( : 409 410 # Get search results for categories/games. 411 String!, : Int, : Cursor): SearchCategoriesConnection ( : 412 413 # Search for category tags to filter categories in Browse. 414 String!, : Int): [Tag!] ( : 415 416 # Get gql search results for a user's query. 417 ( 418 String!, : 419 String!, : 420 SearchForOptions, : 421 SearchForTarget, : 422 ID : 423 ): SearchFor 424 425 # Search for tags to filter live channels in Browse. 426 String!, : ID, : Int): [Tag!] ( : 427 428 # Get Live Streams in search by user query. 429 String!, : Int, : Cursor): SearchStreamConnection ( : 430 431 # Get search suggestions for a user's query. 432 String!, : ID): SearchSuggestionConnection ( : 433 434 # Get users by query in search. for search page product use searchFor instead. 435 String!, : Int, : Cursor): SearchUserConnection ( : 436 437 # Fetch shelves to display on the homepage. 438 # DEPRECATED field arguments: platform (use context.platform), langWeightedCCU. 439 ( 440 String!, : 441 String!, : 442 Boolean, : 443 Int, : 444 Int, : 445 RecommendationsContext : 446 ): ShelfConnection 447 448 # Get paginated short video feed. 449 ( 450 Int, : 451 Cursor, : 452 ShortVideoFeedOptions : 453 ): ShortVideoFeedConnection @deprecated( reason: "No longer supported" ) 454 455 # Whether or not the Twitch Developers CSAT callout should appear for the 456 # currently authenticated user. 457 Boolean : 458 459 # Get a squad stream by ID. 460 ID!): SquadStream ( : 461 462 # The playback access token that determines whether the user can watch the live 463 # stream 464 # Fetched for both authed and unauthed users. 465 ( 466 String!, : 467 PlaybackAccessTokenParams! : 468 ): PlaybackAccessToken 469 470 # Fetch live streams, ordered by the number of viewers descending. 471 # languages can be empty or null, which will imply all the languages are included 472 # on the results. 473 # tags are an array of tag ID as optional filters for streams. 474 # DEPRECATED field arguments: platformType, languageTags, tags 475 # Use StreamOptions instead. 476 ( 477 Int, : 478 Cursor, : 479 StreamOptions, : 480 PlatformType, : 481 Language!], : [ 482 StreamMetadataFilterInput, : 483 String!] : [ 484 ): StreamConnection 485 486 # Get a subscription product by its name. See product name examples below. The 487 # productName uniquely identifies a product. 488 # 489 # e.g. "meclipse", "meclipse_2000", "meclipse_3000", these are respectively, the 490 # tier 1, 2, and 3 subscription product 491 # names for the user with login "shroud". 492 String!): SubscriptionProduct ( : 493 494 # Get all avaialble token bundle products available for the user. 495 # CountryCode will need to be in ISO 3166 Alpha-2 format(e.g. "US", "BR", "HK"). 496 ( 497 String, : 498 ID : 499 ): [SubscriptionTokenBundleProduct!] 500 501 # Gets the Token Product Config. 502 SubscriptionTokenProductConfig : 503 504 # Gets a list of cloud broadcast providers that can be used by clients to start a 505 # broadcast via the provider. 506 CloudBroadcastProviderKey!] : [ 507 508 # Get the logged in user's available hero assets. 509 HeroAsset!]! : [ 510 511 # Get the verticals available for a particular user. 512 ( 513 RecommendationsContext! : 514 ): [VerticalDirectory!] 515 516 # Gets a team by its Twitch name. 517 String!): Team ( : 518 519 # Gets a list of sorted top tags aggregated from all tags applied to current live 520 # channels. 521 Int): [Tag!] ( : 522 523 # Get localized metadata for any twitch's website url. 524 String!): URLMetadata ( : 525 526 # Get a user by their ID or login. 527 # If no ID or login is provided, null is returned. 528 # Lookup type can tell the resolver to include all users (inclusing deleted and 529 # suspended accounts) on the lookup, defaults to only retrieve active users. 530 ID, : String, : UserLookupType): User ( : 531 532 # Fetch the user by a specific attribute. 533 UserByAttribute!): User ( : 534 535 # Fetch a user by their ID, or receive a reason indicating 536 # why the user could not be retrieved. 537 ID!): UserResult ( : 538 539 # Fetch a user by their login, or receive a reason indicating 540 # why the user could not be retrieved. 541 String!): UserResult ( : 542 543 # Get a list of users, either by their logins or by their IDs. 544 ID!], : [String!]): [User] ( : [ 545 546 # Get a verification request given an opaqueID. 547 # These are generally email verification requests, but could be phone-numbers in 548 # the future. 549 ID!): VerificationRequest ( : 550 551 # Get content for a vertical directory by its ID. 552 ( 553 ID!, : 554 RecommendationsContext!, : 555 Int!, : 556 Int! : 557 ): VerticalDirectory 558 559 # Get content for a vertical subdirectory filtered by one or more context IDs (ex: 560 # category ID, tag ID). 561 ( 562 ID!, : 563 VerticalSubDirectoryContentContext, : 564 RecommendationsContext!, : 565 Int!, : 566 Int! : 567 ): VerticalSubDirectory 568 569 # Get a video by its ID. 570 # By default, Video queries only return public videos. 571 # If the owner should also see their own private videos, set includePrivate flag 572 # in the `options` input. 573 # This flag does not include other people's private videos. 574 ID, : VideoOptions): Video ( : 575 576 # A paginated list of comments against id, videoID, or channelID. 577 ( 578 Int, : 579 Cursor, : 580 Int, : 581 Cursor, : 582 String, : 583 String, : 584 String : 585 ): VideoCommentConnection 586 587 # Get the current or past video ingest metadata such as bitrates and codecs by its 588 # ID and channelID. 589 # Optional customerID for staffs. 590 ID!, : ID!, : ID): VideoIngestSession ( : 591 592 # Get the current video ingest metadata such as bitrates and codecs starting a 593 # specified number of seconds ago by channelID. Optional customerID for staffs. 594 ( 595 ID!, : 596 ID, : 597 Int! : 598 ): VideoIngestSession 599 600 # Get the current or past video ingest metadata such as bitrates and codecs by 601 # time range and channelID. Optional customerID for staffs. 602 ( 603 ID!, : 604 ID, : 605 Time!, : 606 Time! : 607 ): [VideoIngestSession!] 608 609 # The playback access token that determines whether the user can watch the video. 610 # Fetched for both authed and unauthed users. 611 ( 612 ID!, : 613 PlaybackAccessTokenParams! : 614 ): PlaybackAccessToken 615 616 # Get a list of videos in order of descending popularity. 617 ( 618 Int, : 619 Cursor, : 620 BroadcastType, : 621 Language : 622 ): VideoConnection 623 624 # Get a list of Prime Video items for Watch Parties. 625 ( 626 Int, : 627 Cursor, : 628 String, : 629 WatchPartyItemSearchOptions : 630 ): WatchPartyItemConnection 631 632 # Get a whisper thread by ID. 633 ID): WhisperThread ( : 634 635 }
link Required by
This element is not required by anyone