Side note: REST APIs

If your friend was going to the store and you needed something, you might ask them to "get" something for you. After they get back, they might "put" that item away for you. These are the constructs we use in everyday life, and REST APIs attempt to build on those, but, rather than operating on physical items, you're dealing with objects on the computer.

When you send HTTP requests to webpages, each request contains a verb. Most browsing you do involves your web browser making GET requests—asking for this page, for instance! But there are several other verbs your browser uses:

  • GET looks something up, as we've said
  • POST creates something
  • PUT updates something
  • DELETE destroys something

On our RESTful API, you make requests by calling VERB https://mixer.com/api/v1/resources. We'll abbreviate this as VERB /resources from now on. For instance, to create a new user, you would call POST /users (the endpoints are always plural). If you want to operate on a particular user object, you would append their ID to that URL, such as GET /users/344 to return information about user ID 344.

You can also run actions on a particular user by chaining on "actions", such as PUT /users/344/confirm, which is used to verify an account. Here's a full blueprint with some examples:

Endpoint Description Example
GET /resources Returns a list of 'resource' objects. GET /users
POST /resources Creates a new 'resource' object. POST /users
GET /resources/{id} Returns information about the 'resource' with the provided ID. GET /users/314
PUT /resources/{id} Updates a resource with the provided ID. PUT /users/314
POST /resources/{id}/action Runs some action on a 'resource'. PUT /users/314/confirm
GET /resources/{id}/data Gets some nested information about a 'resource'. GET /users/314/avatar
DELETE /resources/{id} Delete a resource from the server. DELETE /channels/314/streamKey

If you want some more information about talking to our REST API, check out our REST Tutorial.

Rate Limiting

In order to guarantee API stability there are a few rate limits in place, all endpoints that are rate limited have their bucket noted below.

Here is a list of all rate limiting buckets and their attributes.

Each endpoint can be called Request Count times per Time Interval.
Name Request Count Time Interval (in Seconds)
channel-follow 100 60
channel-read 1000 300
channel-search 20 5
channel-write 250 300
chats 500 60
contact 3 60
global 1000 60
ingest 5 60
mail-subscribe 3 60
notification-read 100 60
report 10 60
upload 5 600
user-email 2 86400
user-login 50 60
user-login-failed 8 900
user-read 500 60
user-register 2 60
user-write 100 60

CSRF Tokens

Mixer's REST API requires the use of CSRF Tokens when using cookie-base authentication.

CSRF tokens are alphanumeric strings issued by the server and are included in the X-CSRF-Token header in responses. They are used to authorize requests and are bound a specific session cookie. They are invalidated after the session expires and may be invalidated at any point prior to the session expiration.

CSRF tokens must be passed to the server in the X-CSRF-Token header when making requests which use cookie-based authentication. Failing to pass a valid CSRF token will cause the request to return in a 461 CSRF Token Invalid response. The server will include an X-CSRF-Token header in the response, which contains a CSRF token that the client can use to retry the request.

Example
$ # Without passing a CSRF token:
$ http get https://mixer.com/api/v1/chats/129

HTTP/1.1 461 CSRF token invalid
Content-Type: application/json
X-CSRF-Token: dca5130a5a6390bd83c077a902e1edf8d052bcc8

{
    "error": "Invalid CSRF header",
    "statusCode": 461
}

$ # Now we have a CSRF token to use:
$ http get https://mixer.com/api/v1/chats/129 X-CSRF-Token:dca5130a5a6390bd83c077a902e1edf8d052bcc8

HTTP/1.1 200 OK
...

Need more help?

If you're still not sure, or would like some help, hit us up on Gitter!

Endpoints

/achievements

get /achievements

/announcements

post /announcements

/channels

get /channels
get /channels/{channelIdOrToken}
get /channels/{channelIdOrToken}/details
put /channels/{channelId}
patch /channels/{channelId}
get /channels/{channelId}/analytics/viewers
get /channels/{channelId}/analytics/tsdb/viewers
get /channels/{channelId}/analytics/tsdb/viewersMetrics
get /channels/{channelId}/analytics/tsdb/ingestStream
get /channels/{channelId}/analytics/tsdb/streamSessions
get /channels/{channelId}/analytics/tsdb/streamHosts
get /channels/{channelId}/analytics/tsdb/subscriptions
get /channels/{channelId}/analytics/tsdb/followers
get /channels/{channelId}/analytics/tsdb/sparkSpent
get /channels/{channelId}/analytics/tsdb/emojiUsageRanks
get /channels/{channelId}/analytics/tsdb/emojiUsage
get /channels/{channelId}/analytics/tsdb/gameRanks
get /channels/{channelId}/analytics/tsdb/gameRanksGlobal
get /channels/{channelId}/analytics/tsdb/subRevenue
get /channels/{channelId}/analytics/tsdb/cpm
post /channels/{channelId}/badge
get /channels/{channelId}/follow
put /channels/{channelId}/follow
post /channels/{channelId}/follow
delete /channels/{channelId}/follow
get /channels/{channelId}/emoticons
patch /channels/{channelId}/emoticons
get /channels/{channelId}/hostee
put /channels/{channelId}/hostee
delete /channels/{channelId}/hostee
get /channels/{channelId}/hosters
get /channels/{channelId}/manifest.light2
get /channels/{channelId}/manifest.m3u8
get /channels/{channelId}/manifest.ftl
get /channels/{channelId}/partnership/app
post /channels/{channelId}/partnership/app
post /channels/{channelId}/partnership/app/deny
post /channels/{channelId}/partnership/app/accept
get /channels/{channelId}/partnership/codes
get /channels/{channelId}/partnership/verify
get /channels/{channelId}/preferences
post /channels/{channelId}/preferences
get /channels/{channelId}/related
delete /channels/{channelId}/streamKey
get /channels/{channelId}/relationship
post /channels/{channelId}/suspend
delete /channels/{channelId}/suspend
post /channels/{channelId}/thumbnail
get /channels/{channelId}/users
get /channels/{channelId}/users/{role}
patch /channels/{channelId}/users/{userId}
get /channels/{channelId}/discord
put /channels/{channelId}/discord
get /channels/{channelId}/discord/channels
get /channels/{channelId}/discord/roles
get /channels/{channelId}/discord/invite
post /channels/{channelId}/discord/invite
get /channels/{channelId}/recordings
post /channels/{channelId}/transcodes/unlock
get /channels/{channelId}/confetti
get /channels/{channelId}/banner
post /channels/{channelId}/banner
delete /channels/{channelId}/banner

/chats

get /chats/endpoints
get /chats/{channelId}
get /chats/{channelId}/friends
get /chats/{channelId}/users
get /chats/{channelId}/users/{user}
get /chats/{channelId}/users/search

/confetti

put /confetti
get /confetti/{confettiId}
patch /confetti/{confettiId}
delete /confetti/{confettiId}

/costreams

get /costreams/{costreamId}
patch /costreams/{costreamId}
delete /costreams/{costreamId}/channels/{channelId}
post /costreams/invite
get /costreams/current
delete /costreams/current

/frontendVersions

get /frontendVersions

/ingests

get /ingests
get /ingests/best

/interactive

get /interactive/{channel}
get /interactive/{channel}/robot
get /interactive/hosts
get /interactive/games
post /interactive/games
get /interactive/games/{game}
put /interactive/games/{game}
delete /interactive/games/{game}
get /interactive/games/{game}/versions
post /interactive/games/{game}/cover
post /interactive/games/{game}/editors
get /interactive/games/{game}/editors
delete /interactive/games/{game}/editors/{user}
get /interactive/games/owned
get /interactive/games/shared
get /interactive/games/reviewing
get /interactive/games/editor
post /interactive/versions
get /interactive/versions/{version}
put /interactive/versions/{version}
delete /interactive/versions/{version}

/invoices

get /invoices/{invoice}
post /invoices/{invoice}/capture

/jwt

post /jwt/authorize

/language

get /language/channels
get /language/channels/active
get /language/channels/available

/notifications

get /notifications/{notificationId}
post /notifications/{notificationId}/shareSub
delete /notifications/{notificationId}/shareSub
post /notifications/{notificationId}/costream/{state}
post /notifications/emailUnsubscribe

/oauth

delete /oauth/authorized/{client}
post /oauth/clients
get /oauth/clients/{client}
put /oauth/clients/{client}
delete /oauth/clients/{client}
post /oauth/clients/{client}/logo
post /oauth/token
post /oauth/shortcode
get /oauth/shortcode/check/{handle}
get /oauth/twitter/check
post /oauth/twitter/check
post /oauth/twitter/link
delete /oauth/twitter/link
post /oauth/twitter/login
get /oauth/twitter/profile
post /oauth/twitter/register
get /oauth/discord/check
post /oauth/discord/check
post /oauth/discord/link
delete /oauth/discord/link
post /oauth/discord/login
get /oauth/discord/profile
post /oauth/discord/register

/recordings

get /recordings
get /recordings/{recording}
patch /recordings/{recording}
delete /recordings/{recording}
post /recordings/{recording}/seen
patch /recordings/{recording}/chat

/redeemables

post /redeemables
get /redeemables/{redeemable}
post /redeemables/redeem

/resources

get /resources/{resource}
delete /resources/{resource}

/seen

get /seen/{bucket}/{thing}
put /seen/{bucket}/{thing}

/shares

get /shares/{type}
post /shares/{type}
delete /shares/{type}
delete /shares/{type}/{share}

/subscriptions

post /subscriptions
get /subscriptions/{subscription}
patch /subscriptions/{subscription}
delete /subscriptions/{subscription}

/teams

get /teams
post /teams
get /teams/{teamIdOrToken}
put /teams/{team}
delete /teams/{team}
post /teams/{team}/background
post /teams/{team}/logo
put /teams/{team}/owner
get /teams/{team}/users
post /teams/{team}/users
delete /teams/{team}/users/{user}
put /teams/{team}/users/{user}

/transcodes

get /transcodes

/types

get /types
get /types/lookup
get /types/{type}/channels

/users

post /users
get /users/current
delete /users/current
post /users/current/refresh
get /users/current/sudo
post /users/current/sudo
delete /users/current/sudo
get /users/search
get /users/{user}
put /users/{user}
patch /users/{user}
delete /users/{user}
get /users/{user}/achievements
get /users/{user}/avatar
post /users/{user}/avatar
delete /users/{user}/avatar
post /users/{user}/changeAvatar
get /users/{user}/follows
patch /users/{user}/frontendVersion
get /users/{user}/invoices
get /users/{user}/links
get /users/{user}/log
get /users/{user}/notifications
get /users/{user}/notifications/preferences
patch /users/{user}/notifications/preferences
get /users/{user}/oauth/authorized
get /users/{user}/oauth/clients
get /users/{user}/preferences
post /users/{user}/preferences
get /users/{user}/recurringPayments
get /users/{user}/redeemables
get /users/{user}/resources
get /users/{user}/sessions
get /users/{user}/subscriptions
get /users/{user}/teams
get /users/{user}/teams/limit
put /users/{user}/teams/primary

Models & Types

Achievement

  • slug:  string
    • maxLength: 100
  • name:  string
  • description:  string
  • sparks:  uint

AchievementEarning extends TimeStamped

  • id:  uint

    The unique ID of the earning.

  • earned:  boolean

    Indicates whether the achievement was earned.

  • progress:  number≤1

    Unit interval indicating the progress.

  • achievement:  string

    The name of the achievement.

  • user:  uint

    The ID of the user this earning belongs to.

  • Achievement:  Achievement

Announcement

  • text:  string

    The text of the announcement.

  • script:  string

    A java-script to be executed on the browsers.

  • scope:  object

    Unknown.

CPMAnalytic

  • channel:  uint
  • impressions:  uint

    The number of unique ad impressions.

  • payout:  number

    The amount of money awarded from the impressions, in cents.

Channel extends TimeStamped

  • id:  uint

    The unique ID of the channel.

  • userId:  uint

    The ID of the user owning the channel.

  • token:  string

    The name and url of the channel.

  • online:  boolean

    Indicates if the channel is active.

  • featured:  boolean

    True if featureLevel is > 0.

  • featureLevel:  integer

    Featuring level.

  • partnered:  boolean

    Indicates if the channel is partnered.

  • transcodingProfileId:  uint?

    The id of the transcoding profile.

  • suspended:  boolean

    Indicates if the channel is suspended.

  • name:  string

    The title of the channel.

  • audience:  string (family,teen,18+)

    The target audience of the channel.

  • viewersTotal:  uint

    Amount of unique viewers that ever viewed this channel.

  • viewersCurrent:  uint

    Amount of current viewers.

  • numFollowers:  uint

    Amount of followers.

  • description:  string

    The description of the channel, can contain HTML.

  • typeId:  uint?

    The ID of the game type.

  • interactive:  boolean

    Indicates if that channel is interactive.

  • interactiveGameId:  uint?

    The ID of the interactive game used.

  • ftl:  uint

    The ftl stream id.

  • hasVod:  boolean

    Indicates if the channel has vod saved.

  • languageId:  string?

    ISO 639 language id.

  • coverId:  uint?

    The ID of the cover resource.

  • thumbnailId:  uint?

    The resource ID of the thumbnail.

  • vodsEnabled:  boolean

    Indicates if the channel has vod recording enabled.

  • costreamId:  UUID?

    The costream that the channel is in, if any.

ChannelAdvanced extends Channel

ChannelPreferences

  • sharetext:  string?

    The text used when sharing the stream. The template parameter %URL% will be replaced with the channel's URL. The template parameter %USER% will be replaced with the channel's name.

  • channel:links:allowed:  boolean?

    Specifies whether links are allowed in the chat.

  • channel:links:clickable:  boolean?

    Specifies whether links are clickable in the chat.

  • channel:slowchat:  number?

    Interval required between each chat message.

  • channel:notify:subscribemessage:  string?

    The message to be sent when a user subscribes to the channel. The template parameter %USER% will be replaced with the subscriber's name.

  • channel:notify:subscribe:  boolean?

    Indicates whether a notification should be shown upon subscription.

  • channel:notify:followmessage:  string?

    The message to be sent when a user follows the channel. The template parameter "%USER%" will be replaced with the follower's name.

  • channel:notify:follow:  boolean?

    Indicates whether a notification should be shown upon follow.

  • channel:notify:hostedBy:  string?

    The message to be sent when a user hosts the channel. The template parameter "%USER%" will be replaced with the hoster's name.

  • channel:notify:hosting:  string?

    The message to be sent when the channel hosts another. The template parameter "%USER%" will be replaced with the hostee's name.

  • channel:partner:submail:  string?

    The text to be added to the subscription email.

  • channel:player:muteOwn:  boolean?

    Indicates whether to mute when the streamer opens his own stream.

  • channel:tweet:enabled:  boolean?

    Indicates whether the tweet button should be shown.

  • channel:tweet:body:  string?

    The message to be used when a user tweets about the channel. The template parameter %URL% will be replaced with the share url.

  • costream:allow:  boolean

    Allows other streamers to join you in a costream.

ChatUser

  • userId:  uint

    The user ID that this chat user belongs to.

  • userName:  string

    The username.

  • userRoles:  Array<string>

    The roles the user has in this chat.

  • lurking:  boolean?

    Indicates that the user is lurking, requires the chat:view_lurkers permission.

CheckoutItem

  • id:  uint

    The ID of the item to be purchased.

  • quantity:  uint

    The amount of items to be purchased.

Confetti

  • id:  uint

    The Confetti's ID.

  • channelId:  uint?

    The owner of the Confetti; this channel can edit it.

  • settings:  object

    The settings configure the confetti. Most options are customizable math expressions parsed with expr-eval.

    • count:  string

      Expression to be evaluated to determine the number of generated confetti particles. The window height and width will be passed into the expression. The number of confetti particles will be capped based on the device profile, however. For example: "count": "35 * width / 100".

    • particles:  Array<object>
      • Item properties:
        • probability:  number

          Weighted probability that a generated confetti particle will be this particle. Weighting is done based on the sum all probabilities.

        • velocity:  string

          Expression to be evaluated to determine the vertical velocity, in pixels per millisecond, of the particle. It's called with the window width and height. For example: "velocity": "height / 1000 / 4".

        • zdepth:  string

          Expression to be evaluated to determine the "depth" of the particle, which will be used to scale its size and velocity to achieve a pseudo-3d effect. It's called with the window width and height. For example: "zdepth": "1 + random(3)".

        • wiggleMagnitude:  string

          Expression to determine the magnitude of the wave, in pixels, that each particle follows on its horizontal axis as it floats down. It's called with the window width and height. For example: "wiggleMagnitude": "15 + random(10)".

        • wigglePeriod:  string

          Expression to determine the period of the wave, in milliseconds, that each particle follows on its horizontal axis as it floats down. It's called with the window width and height. For example: "wigglePeriod": "1000 + random(500)".

        • lifetime:  string

          Expression to determine how long each particle lives for, in milliseconds, before being destroyed. It's called with the window width and height. For example: "lifetime": "1200 + random(2000)".

        • fader:  string

          Expression called continuously to determine the opacity. It's called a lifetime values, which starts at zero and goes to one as the time passes, and should return an opacity value in the range from zero to one. For example: "fader": "1 - lifetime^3".

        • draw:  ConfettiCircleConfettiRectangleConfettiImage

          Describes the confetti graphic to be drawn.

ConfettiCircle

  • shape:  string

    Must be set to circle.

  • size:  string

    Expression to determine the diameter of the confetti circle in pixels. For example: "size": "4 + random(2)"

  • flipPeriod:  string

    Expression to determine the length of time the circle takes to do a vertical, pseudo-3d spin around the x axis. For example: "flipPeriod": "500 + random(1000)"

  • colors:  Array<object>
    • Item properties:
      • probability:  number

        Weighted probability that a generated confetti particle will be this color. Weighting is done based on the sum all probabilities.

      • r:  string

        Expression used to generate the red color component, should return a value between 0 and 255 inclusive.

      • g:  string

        Expression used to generate the red color component, should return a value between 0 and 255 inclusive.

      • b:  string

        Expression used to generate the red color component, should return a value between 0 and 255 inclusive.

ConfettiImage

  • shape:  string

    Must be set to image.

  • scale:  string

    Expression to determine the scale of the image. For example: "scale": "0.5 + random(1)"

  • spinPeriod:  string

    Expression to determine the length of time the images takes to do a full spin around the z axis. For example: "spinPeriod": "1000 + random(1000)"

  • data:  string

    Base-64 encoded image data. This will usually be a long string that starts with data:image/png;base64,. Make sure to minify the image before inserting it here to prevent exceeding size limits.

ConfettiRectangle

  • shape:  string

    Must be set to rectangle.

  • width:  string

    Expression to determine the width of the confetti circle in pixels. For example: "size": "8 + random(2)"

  • height:  string

    Expression to determine the height of the confetti circle in pixels. For example: "size": "4 + random(1)"

  • flipPeriod:  string

    Expression to determine the length of time the circle takes to do a vertical, pseudo-3d spin around the x axis. For example: "flipPeriod": "500 + random(1000)"

  • colors:  Array<object>
    • Item properties:
      • probability:  number

        Weighted probability that a generated confetti particle will be this color. Weighting is done based on the sum all probabilities.

      • r:  string

        Expression used to generate the red color component, should return a value between 0 and 255 inclusive.

      • g:  string

        Expression used to generate the red color component, should return a value between 0 and 255 inclusive.

      • b:  string

        Expression used to generate the red color component, should return a value between 0 and 255 inclusive.

Costream

  • channels:  Array<object>

    The members of the costream. The first member in this array is the "host" and has some special permissions regarding kicking other members and changing layout.

    • Item properties:
      • id:  uint

        The unique ID of the channel.

      • userId:  uint

        The ID of the user owning the channel.

      • token:  string

        The name and url of the channel.

  • startedAt:  IsoDate

    The time the costream started.

  • capacity:  uint

    The total number of people who may join this costream.

  • layout:  CostreamLayout

    The layout of a costream, configurable by the host or inviter.

CostreamLayout

The CostreamLayout configures the arrangement and positioning of the channels within the costream. Internally, the name is used to select the layout engine used to render the costream, and order tweaks the order in which channels are fed to the engine.

  • name:  string

    General name of the layout to use, such as "mobile" or "grid".

  • order:  Array<number>

    Placements list of channel IDs in the order in which they're added to areas in the costream layout. Not all channels in the costream may be listed in the layout; subsequent channels are appended by the layout engine in the Mixer frontend.

DiscordBot

  • id:  uint

    The unique ID of the Discord bot.

  • channelId:  uint

    The channel ID linked to this Discord integration.

  • guildId:  string

    The server ID that this bot belongs to.

  • inviteSetting:  string (EVERYONE,FOLLOWERS,SUBS,NOONE)

    Determines which users can get invites to the Discord channel. It can be set to "everyone", "followers", "subs", or "noone" to disable invites. Defaults to "noone".

  • inviteChannel:  string

    The ID of the server channel that new users are invited to.

  • liveUpdateState:  boolean

    Whether the user state should be changed to "Playing GAME on Mixer" when the user goes live.

  • liveChatChannel:  string

    Channel ID that chat messages will be mirrored to by the bot. If this is null, chat messages will not be mirrored.

  • liveAnnounceChannel:  string

    Channel ID that chat announcements will be mirrored to by the bot. If this is null, chat messages will not be mirrored.

  • syncEmoteRoles:  Array<uint>

    A list of Discord roles who will be able to use subscriber emotes. (This only has an effect for partnered channels.)

  • roles:  Array<object>
    • Item properties:
      • id:  uint
      • type:  string (SUBS,FOLLOWERS)

        Describes what group of people are given this role.

      • roleId:  string
      • gracePeriod:  uint

        Number of days subscribers have until they're kicked from the server if their subscription expires. It defaults to 14 days and may be set to null to disable kicking. Violence is never the answer.

DiscordChannel

  • id:  string

    The unique ID of the Discord channel.

  • name:  string

    The human name of the channel.

  • type:  string

    Either "voice" or "text".

  • private:  boolean

    Whether the channel is private or not.

DiscordRole

  • id:  string

    The unique ID of the Discord role.

  • name:  string

    The human name of the role.

  • color:  string

    Hex color code for the channel, starting with a pound # symbol

EmojiRankAnalytic

  • channel:  uint
  • emoji:  string
  • count:  uint

    The number of times this emoji was used in the queried time period.

  • time:  IsoDate

EmoticonGroup

  • Keys matching the RegEx /^:\w+$/:  object
    • x:  uint

      X coordinate of the emote.

    • y:  uint

      Y coordinate of the emote.

EmoticonPack

  • url:  string

    The url to the sprite sheet.

  • emoticons:  EmoticonGroup

    An emoticon group.

  • channelId:  uint

    The ID of the channel that owns this EmoticonPack

ExpandedChannel extends ChannelAdvanced

  • thumbnail:  Resource?

    A resource object representing the thumbnail.

  • cover:  Resource?

    A resource object representing the cover.

  • badge:  Resource?

    A resource object representing the badge.

  • cache:  Array<object>

    Unused, deprecated.

  • preferences:  ChannelPreferences

    The channel preferences.

ExpandedRedeemable extends Redeemable

  • owner:  User

    Embedded owner.

  • redeemedBy:  User

    Embedded redeemer.

ExpandedShare extends Share

  • user:  User?

    The embedded user the share targets.

ExpandedTranscodingProfile extends TranscodingProfile

FTLVideoManifest

  • resolutions:  Array<VideoManifestResolution>
    • Item properties:
      • iceServers:  Array<object>
        • Item properties:
          • url:  string

            The url of the ice server, can be stun or turn.

          • username:  string?

            Only set when url protocol is turn.

          • credentials:  string?

            Only set when url protocol is turn.

      • rtcId:  uint

        The ID of the channel.

  • since:  IsoDate

    Time the stream started.

FeatureSchedule extends TimeStamped

  • id:  uint

    The feature id.

  • startedAt:  IsoDate

    Start time of the featuring.

  • endedAt:  IsoDate

    End time of the featuring

  • type:  string (auto,manual)

    auto means it was created by the featuring service.

  • userId:  uint?

    The user that scheduled the feature.

  • channelId:  uint

    The channel to be featured.

Follow extends TimeStamped

  • user:  uint

    The follower user id.

  • channel:  uint

    The followee channel id.

FollowersAnalytic

  • channel:  uint
  • total:  uint

    The total number of followers the channel now has.

  • delta:  number

    Increment that the total changed as a result of this event.

  • user:  number

    The ID of the user who followed, may not be present in aggregations.

  • time:  IsoDate

FrontendVersion

  • version:  string

    The version name.

  • displayName:  string

    The version's display name for the frontend.

GameRankAnalytic

  • channel:  uint
  • streams:  uint

    The number of streams playing this game in the time period. Note that this is recorded once per unique stream when it ends.

  • views:  uint

    The number of views the game received in the time period

  • shared:  uint

    The number of times the game was shared in the time period

  • time:  IsoDate

GameType extends GameTypeSimple

  • parent:  string

    The name of the parent type.

  • description:  string

    The description of the type.

  • source:  string

    The source where the type has been imported from.

  • viewersCurrent:  uint

    Total amount of users watching this type of stream.

  • online:  uint

    Amount of streams online with this type.

GameTypeLookup extends GameTypeSimple

  • exact:  boolean

    Whether this game type is an exact match to the query.

GameTypeSimple

Base game type.

  • id:  uint

    The unique ID of the game type.

  • name:  string

    The name of the type.

  • coverUrl:  string?

    The url to the type's cover.

  • backgroundUrl:  string?

    The url to the type's background.

Ingest

An ingest definition.

Example:

{
   "name": "US: Dallas, TX",
   "host": "ingest-dal.mixer.com",
   "pingTest": "ingest-dal.mixer.com",
   "protocols": [
      {
         "type": "ftl"
      },
      {
         "type": "rtmp"
      }
   ]
}
  • name:  string

    The name and location of the ingest.

  • host:  string

    Url of the host.

  • pingTest:  string

    A websocket address that is used for ping tests.

  • protocols:  Array<object>

    List of supported protocols

    • Item properties:
      • type:  string (ftl,rtmp)

        The protocol name.

IngestStreamAnalytic

  • ingest_id:  uint

    A unique id per ingest

  • channel_id:  uint

    The channel ID of the streamer

  • subscribed_dist_nodes:  uint

    How many dist nodes are watching

  • video_packet_loss:  number

    The packet loss percent for the last 5 seconds

  • video_packet_recovered:  number

    The percentage of packets recovered in the last 5 seconds

  • video_avg_recovery_delay:  uint

    The delay to recover a packet

  • video_avg_nack_delay:  uint

    The delay in the nack

  • video_bitrate:  uint

    The video bitrate for the last 5 seconds

  • video_jitter_buffer_size:  uint

    The jitter buffer size

  • audiovo_packet_loss:  number

    The packet loss percent for the last 5 seconds

  • audiov_packet_recovered:  number

    The percentage of packets recovered in the last 5 seconds

  • audiov_avg_recovery_delay:  uint

    The delay to recover a packet

  • audio_avg_nack_delay:  uint

    The delay in the nack.

  • audiov_bitrate:  uint

    The audio bitrate for the last 5 seconds

  • audioo_jitter_buffer_size:  uint

    The jitter buffer size

InteractiveConnectionInfo

  • address:  string

    Websocket url to connect to.

  • key:  string

    The connection key required for connecting to interactive.

  • influence:  number

    Influence multiplier

  • version:  InteractiveVersion

    The interactive game the channel is using.

InteractiveControls

  • reportInterval:  50≤integer≤10000
  • joysticks:  Array<object>?
    • Maximum length: 100
    • Item properties:
      • id:  uint

        The unique ID of the control.

      • blueprint:  Array<object>
        • Minimum length: 1
        • Item properties:
          • state:  string

            The state the button belongs to.

            • maxLength: 100
          • grid:  string
            • maxLength: 100
          • x:  uint

            X coordinate of the joystick.

          • y:  uint

            Y coordinate of the joystick.

          • width:  3≤integer≤3

            Width of the joystick.

          • height:  3≤integer≤3

            Height of the joystick.

      • analysis:  InteractiveJoyStickAnalysis

        The analysis types enabled on this joystick.

  • screens:  Array<object>?
    • Maximum length: 100
    • Item properties:
      • id:  uint

        The unique ID of the control.

      • blueprint:  Array<object>
        • Item properties:
          • state:  string

            The state the button belongs to.

            • maxLength: 100
      • analysis:  InteractiveScreenAnalysis

        The analysis types enabled on this screen control.

  • tactiles:  Array<object>?
    • Maximum length: 100
    • Item properties:
      • id:  uint

        The unique ID of the control.

      • blueprint:  Array<object>
        • Item properties:
          • state:  string

            The state the button belongs to.

            • maxLength: 100
          • grid:  string
            • maxLength: 100
          • x:  uint

            X coordinate of the tactile.

          • y:  uint

            Y coordinate of the tactile.

          • width:  1≤integer≤4

            Width of the tactile.

          • height:  1≤integer≤2

            Height of the tactile.

      • key:  uint

        The key to be bound to the tactile.

      • text:  string?

        The text to show on the tactile.

      • cost:  object
        • press:  object
          • cost:  uint

            Cost, in sparks, for a tactile press.

      • cooldown:  object
        • press:  integer?

          Length of cooldown started when a user pushes this tactile. In milliseconds.

      • analysis:  InteractiveTactileAnalysis

        The analysis types enabled on this tactile.

InteractiveGame extends TimeStamped

  • id:  uint

    The unique ID of the game.

  • ownerId:  uint

    The user ID of the creator.

  • name:  string

    The name of the game.

  • coverUrl:  string?

    The url to the cover image.

  • description:  string

    The description of the game, may contain HTML.

  • hasPublishedVersions:  boolean

    Indicates whether the game has any public published versions.

  • installation:  string

    Installation instructions, may contain HTML.

InteractiveGameListing extends InteractiveGame

  • versions:  Array<object>
    • Item properties:
      • id:  uint

        The ID of the version.

      • version:  string

        The semantic version string.

      • state:  string (draft,pending,published)

        The current state of the version. draft: Not in review, not published. pending: In review. published: Published and available to the public.

      • versionOrder:  uint

        Value used to help ordering versions.

  • owner:  User

    The creator of the game.

InteractiveJoyStickAnalysis

  • coords:  object
    • mean:  boolean

      Enable joystick mean analysis on this joystick.

    • stdDev:  boolean

      Enable standard deviation analysis on this joystick.

InteractiveScreenAnalysis

  • position:  object
    • mean:  boolean

      Enable mean analysis for this screen control.

    • stdDev:  boolean

      Enable standard deviation analysis for this screen control.

  • clicks:  boolean

    Enable click event for analysis for this screen control.

InteractiveTactileAnalysis

  • holding:  boolean

    Enable holding analysis for the tactile.

  • frequency:  boolean

    Enable frequency analysis for the tactile.

InteractiveVersion extends TimeStamped

  • id:  uint

    The unique ID of the version.

  • gameId:  uint

    The game ID this version belongs to.

  • version:  string

    The semver of the game.

  • versionOrder:  uint

    Value used to help ordering versions.

  • changelog:  string

    The changelog of version.

  • state:  string (draft,pending,published)

    The current state of the version. draft: Not in review, not published. pending: In review. published: Published and available to the public.

  • installation:  string

    Installation instructions, may contain HTML.

  • download:  string

    Download instructions, usually a url.

  • controls:  InteractiveControls

    The controls for the game.

  • controlVersion:  string (1.0,2.0)

    Indicates which version of the Interactive Controls this Interactive Version uses.

Invoice

A user invoice.

  • id:  uint

    The ID of the invoice.

  • currency:  string

    ISO 4217 currency code

  • status:  string (paid,unpaid,errored,cancelled)

    The invoice status

  • user:  uint

    The owner of the invoice.

  • createdAt:  IsoDate

    Creation date

  • amount:  number

    The total invoice amount.

  • items:  Array<InvoiceItem>

    List of invoice items

InvoiceItem extends TimeStamped

A user invoice.

  • id:  uint

    The ID of the invoice item.

  • type:  string (subscription,redeemable)

    The purchase type

  • relid:  uint?

    The channel id

  • description:  string

    A brief summary of what has been purchased.

  • amount:  number

    The cost of the item.

  • quantity:  uint

    Item quantity.

  • status:  string (paid,unpaid,errored,cancelled)

    The invoice status

  • user:  uint

    The user ID of the invoice owner.

  • invoice:  uint

    The invoice ID the item belongs to.

IsoDate

An ISO8601 date string.

Example:

2016-06-28T04:25:45.110Z

Language

An object representing a language.

  • id:  string

    A rfc5646 language code.

  • name:  string

    The full language name.

LanguageCount

An object describing a count for a language.

  • id:  string

    A rfc5646 language code.

  • count:  uint

    The count.

LightVideoManifest

  • resolutions:  Array<VideoManifestResolution>
    • Item properties:
      • url:  string

        The source url for the stream.

  • since:  IsoDate

    Time the stream started.

Notification

  • userId:  uint

    The user ID that this chat user belongs to.

  • sentAt:  IsoDate

    The time at which the notification was sent.

  • trigger:  string

    The event that triggered the notification.

  • payload:  object

    An generally unstructured object containing information about the event. Events of the same type will share the same structure.

NotificationPreference

  • id:  string
  • alllowsEmailMarketing:  boolean

    Whether the user allows general marketing/promotional email.

  • notifyFollower:  Array<string>

    A list of transports follower notifications will be sent over.

  • notifySubscriber:  Array<string>

    A list of transports subscriber notifications will be sent over.

  • liveOnByDefault:  Array<string>

    A list of notification transport wentlive notifications are sent on by default.

  • lastRead:  IsoDate

    The time the user last read their notifications.

  • health:  object
    • eat:  number≤72

      Interval, in hours, to show eating notifications.

    • stretch:  number≤72

      Interval, in hours, to show eating notifications.

  • liveNotifications:  Array<object>

    A list of channels and transports registered on which we'll sent wentlive emails.

    • Item properties:
      • channelId:  uint ∪ string

        May be "*", which will toggle on the associated transport for all channels the user follows.

      • kind:  Array<string>
  • transports:  Array<object>
    • Item type: object

OAuthAuthorization

  • permissions:  Array<string>

    List of permissions the authorization has.

  • userId:  uint

    The ID of the other the authorization is for.

  • client:  OAuthClient

    The OAuth client linked to this authorization.

OAuthClient

  • id:  uint

    Internal client id.

  • clientId:  string

    The unique ID of the client.

    • pattern:
      ^[a-f0-9]{48}$
  • name:  string

    The name of the client.

  • website:  string?

    The url of the website using this client.

  • logo:  string?

    The url to the logo of the website.

  • hosts:  Array<string>

    List of wildcard hosts allowed to use the client.

OAuthLink

  • service:  string

    The service this link is to, such as twitter or discord.

  • serviceId:  string

    The user's ID on the external service.

  • userId:  number

    The associated Mixer user ID.

PartnershipApp extends TimeStamped

  • status:  string (applied,accepted,denied)
  • reapplies:  IsoDate?

    The date of the next possible application, only set if status is denied. If the value is null while status is denied, the channel is banned from re-applying.

  • reason:  string?

    The reason of the denial, only set if status is denied.

PrivatePopulatedUser extends PrivateUser

A fully populater user with channel, preferences, groups and private details.

  • channel:  Channel

    The users channel.

  • groups:  Array<UserGroup>

    The global user groups.

  • preferences:  UserPreferences

    The preferences the user has.

  • twoFactor:  object

    Two factor related data.

    • enabled:  boolean

      Indicates whether two factor is enabled.

PrivateUser extends User

A fully populater user with channel, preferences, groups and private details.

  • email:  string

    The users email address.

  • password:  string

    The users password.

    • minLength: 4
  • twoFactor:  object
    • enabled:  boolean

      Indicates whether 2fa is enabled.

    • codesViewed:  boolean

      Indicates whether recovery codes have been viewed.

Rating

  • id:  string

    Rating system and id. E.g. ESRB:M.

  • name:  string

    Localized name for the rating.

  • logoUrl:  string

    Url for the rating logo.

Recording extends TimeStamped

  • id:  uint

    The unique ID of the recording.

  • channelId:  uint

    The channel ID this recording is a video of.

  • state:  string (PROCESSING,AVAILABLE,DELETED)
  • viewsTotal:  uint

    The number of users who have viewed this recording.

  • expiresAt:  IsoDate

    The date this recording will be deleted at.

  • vods:  Array<VOD>

    The video formats available for this recording.

  • viewed:  boolean?

    Whether the current user has viewed the recording. This will generally only appear when the recording is looked up from an endpoint with user in the query string.

  • name:  string?

    Name of the Recording, usually the title of the channel at the time of the recording unless the creator changed it.

  • typeId:  uint

    Type id of the recording, usually the type id of the channel at the time of the recording, unless the creator changed it.

  • duration:  number

    Duration of the recording in seconds.

  • seen:  boolean?

    Defines if the video was seen by the user. Only present when the user context was given.

RecurringPayment extends TimeStamped

  • id:  uint

    The unique ID of the payment.

  • type:  string (subscription)

    The type of the product the payment is for.

  • relid:  uint

    The ID of the target the payment is for, can be a channe or a user.

  • status:  string (active,cancelled,failed,before_gateway)

    The status of the payment.

  • cancelled:  boolean

    Indicates whether the payment has been cancelled. This is not the same as status being set to cancelled, this property indicates that the user cancelled a running payment.

  • gateway:  string (braintree,stripe)

    The internal name of the payment processsor.

  • timesPaid:  uint

    Counts the amount of times this recurring payment has recurred.

  • user:  uint

    The ID of the user the payment is for.

RecurringPaymentExpanded extends RecurringPayment

  • subscription:  Subscription

    The subscription belonging to this payment.

    • user:  User

      The user of the payment.

    • group:  UserGroup

      The group obtained through this payment.

Redeemable extends TimeStamped

  • id:  uint

    The unique ID of the redeemable.

  • ownerId:  uint

    The ID of the owning user.

  • state:  string (unpaid,paid,redeemed)
  • type:  string (pro)
  • code:  string?

    The redeem code.

  • redeemedById:  uint?

    The ID of the user that used the code.

  • redeemedAt:  IsoDate?

    The time the item was redeemed.

  • meta:  object

    An object containing meta information about a redeemable.

RedeemablePartner extends TimeStamped

  • id:  uint

    The unique ID of the channel.

  • redeemableId:  uint

    The id of the related redeemable.

  • partnerId:  uint

    The id of the related partner.

Resource

  • id:  uint

    The unique ID of the resource.

  • type:  string

    The type of the resource.

  • relid:  uint

    Id linking to the parent object.

  • url:  string

    The url of the resource.

  • store:  string (s3)

    The storage type of the resource.

  • remotePath:  string

    Relative url to the resource.

  • meta:  object?

    Additional resource information.

Session

  • expires:  UnixTimestampMillis

    The when the session expires.

  • meta:  object

    Session meta data.

    • device:  string

      The device type.

    • client:  string

      The client name. "Other" is web.

    • cversion:  string

      Semantic version of the client.

    • os:  string

      The operating system name of the client.

  • ip:  string

    Last if used for that session, can be v4 and v6.

  • id:  string

    The session ID as a UUID.

Share extends TimeStamped

  • id:  uint

    The unique ID of the share.

  • type:  string (interactiveGameDraft)

    The type of the share.

  • relid:  string

    The

  • code:  string?

    Share code.

  • userId:  uint?

    The user ID of the target, can be unset if code is set.

SocialInfo

  • twitter:  string

    Twitter profile URL.

  • facebook:  string

    Facebook profile URL.

  • youtube:  string

    Youtube profile URL.

  • player:  string

    Player.me profile URL.

  • discord:  string

    Discord username and tag.

  • verified:  Array<string>

    A list of social keys which have been verified via linking the Mixer account with the account on the corresponding external service.

    • Item type: string

SparkSpendingAnalytic

  • channel:  uint
  • sparks:  number

    The number of sparks spent in this event (always a positive number).

  • user:  uint

    The ID of the user who followed, may not be present in aggregations.

  • time:  IsoDate

StreamHostsAnalytic

  • channel:  uint
  • hoster:  uint?

    The channel doing the hoster, may be omitted if the channel is the hoster.

  • hostee:  uint?

    The channel being hosted, may be omitted if the channel is the hostee.

  • time:  IsoDate

StreamSessionsAnalytic

  • channel:  uint
  • online:  boolean

    Whether this event is the channel going online, or offline.

  • duration:  uint?

    The length of the last stream, only included in offline events.

  • typeID:  uint?

    The ID of the game the stream was playing, only included in offline events.

  • time:  IsoDate

SubRevenueAnalytic

  • channel:  uint
  • gateway:  string (redeemable,stripe,braintree)

    The gateway that the subscription was made with.

  • total:  number

    The amount of revenue gained through this gateway.

  • gross:  number

    The amount of money prior to transaction fees being applied.

  • count:  uint

    The number of subscriptions made through this gateway.

Subscription extends TimeStamped

  • id:  uint

    The unique ID of the subscription.

  • resourceId:  uint?

    Id of the resource type this payment is for, only channel ID at the moment.

  • resourceType:  string?

    The resource type the resourceId points to, only channel at the moment.

  • status:  string (active,expired,pending)

    The status of the subscription.

  • cancelled:  boolean

    Indicates whether the payment has been cancelled after completion.

  • expiresAt:  IsoDate

    The time when the subscription expires.

SubscriptionWithGroup extends Subscription

  • group:  uint

    The group ID of the group the subscription grants the user access to.

  • Group:  UserGroup

    The embedded group assigned to the user.

SubscriptionsAnalytic

  • channel:  uint
  • total:  uint

    The total number of subscribers the channel now has.

  • delta:  number

    Increment that the total changed as a result of this event.

  • user:  uint

    The ID of the user who subscribed, may not be present in aggregations.

  • time:  IsoDate

Team extends TimeStamped

  • id:  uint

    The unique ID of the team.

  • ownerId:  uint

    The ID of the owner user.

  • token:  string

    The internal name of the team.

    • minLength: 4
    • maxLength: 20
  • name:  string

    The display name of the team.

    • minLength: 4
    • maxLength: 36
  • description:  string?

    The description of the team.

  • logoUrl:  string?

    The url pointing to a logo image.

  • backgroundUrl:  string?

    The url pointing to a background image.

  • social:  SocialInfo?

    Social info of the team.

TeamMembership extends TimeStamped

  • id:  uint

    The unique ID of the team membership.

  • teamId:  uint

    The team ID of this membership.

  • userId:  uint

    The user ID of this membership.

  • accepted:  boolean

    If false, the user has just been invited. If true, the user has joined the team.

TeamMembershipExpanded extends TeamMembership

  • isPrimary:  boolean

    Indicates that this team is the users primary.

  • owner:  User

    Embedded user object.

  • teamMembership:  TeamMembership

    The membership object linking team and user.

TestStreamSetting

  • id:  uint

    The ID of the channel the settings are for.

  • isActive:  boolean

    Whether the next channel broadcast will be in test stream mode.

  • hoursQuota:  number

    How many test stream hours the channel gets at every internal.

  • hoursRemaining:  number

    The number of test stream hours left this period.

  • hoursResetIntervalInDays:  uint

    The interval, in days, at which hoursRemaining is set to the hoursQuota.

  • hoursLastReset:  IsoDate?

    The last date at which the user's hours were reset.

TimeStamped

A type that contains information about creation, update and deletion dates.

  • createdAt:  IsoDate

    The creation date of the channel.

  • updatedAt:  IsoDate

    The update date of the channel.

  • deletedAt:  IsoDate?

    The deletion date of the channel.

TranscodingProfile

  • id:  uint

    The unique id of the transcoding profile.

  • name:  string

    The name of the transcoding profile.

TranscodingProfileTranscode

  • id:  uint

    The unique id of the transcode.

  • name:  string

    The name of the transcode.

  • title:  string

    The display title of the transcode.

  • width:  uint

    The width (in pixels) of the transcode.

  • height:  uint

    The height (in pixels) of the transcode.

  • bitrate:  uint

    The bitrate of the transcode.

  • fps:  uint

    The FPS of the transcode.

  • requiresPartner:  boolean

    If this transcode requires to be partnered.

UUID

A universally unique identifier (UUID).

Example:

4825bcf1-9640-4d91-bf66-426731cfa717

UnixTimestampMillis extends uint

A unix timestamp with milliseconds.

UpsellInformation

  • productId:  string

    Windows Store product id (aka big id).

  • title:  string

    Localized title of product.

  • boxArtUrl:  string

    Box art url.

  • description:  string

    Localized product description.

  • price:  string

    Price and currency.

  • ratings:  Array<string>

    List of rating ids for product.

  • link:  string

    Link to store.

User extends TimeStamped

  • id:  uint

    The unique ID of the user.

  • level:  uint

    The users experience level, related to experience.

  • social:  SocialInfo?

    Social links.

  • username:  string
    • minLength: 4
    • maxLength: 20
    • pattern:
      ^[A-Za-z_][\w-]+$
  • email:  string
    • maxLength: 190
  • verified:  boolean

    Indicates whether the user has verified their e-mail.

  • experience:  uint

    The users experience points.

  • sparks:  uint

    The amount of sparks the user has.

  • avatarUrl:  string?

    The users profile URL.

  • bio:  string?

    The users biography, may contain HTML.

  • primaryTeam:  uint?

    The ID of users main team.

  • transcodingProfileId:  uint?

    The ID of the transcoding profile currently active.

  • hasTranscodes:  boolean

    Indicates whether the user can choose a transcode profile or not.

UserGroup

  • id:  uint

    The unique ID of the group.

  • type:  string

    The name of the group.

UserLog

  • id:  uint

    The unique ID of the log entry.

  • userId:  uint

    User ID of the log entry.

  • event:  string

    A unique identifier for the log entry.

  • eventData:  object?

    Unstructured data describing the event.

  • source:  string (GUEST,SELF,APP,INTERNAL,ADMIN)

    Source data for the event action. This may be one of:

    • GUEST: a change by an unauthenticated user
    • SELF: a change by the user themselves
    • APP: a change by an external OAuth app
    • INTERNAL: a change by some internal Mixer system
    • ADMIN: a change by a user who was permitted to administer the user's account
  • sourceData:  object?

    Unstructured data containing more information about the event's source.

    • SELF and GUEST sources will include an ip address
    • APP sources will contain the OAuth app ID
    • INTERNAL and ADMIN sources will omit this attribute
  • createdAt:  IsoDate

    The date the log entry occurred at.

UserPreferences

Object containing user preferences.

  • chat:sounds:html5:  boolean?

    Use html5 to play chat sounds.

  • chat:sounds:play:  boolean?

    Play sounds in chat.

  • chat:whispers:  boolean?

    Allow receiving whispers.

  • chat:timestamps:  boolean?

    Show timestamps in chat.

  • chat:chromakey:  boolean?

    Set the chat color to a certain color so it can be easily replaced.

  • chat:tagging:  boolean?

    Enable chat tagging via @username.

  • chat:sounds:volume:  number≤1?

    Chat sound volume as unit interval.

  • chat:colors:  boolean?

    Use colors in chat.

  • chat:lurkmode:  boolean?

    Hide while in chats.

  • channel:notifications:  object?

    Notification settings.

    • ids:  Array<string>

      List of sources notifications are allowed from.

    • transports:  Array<string>

      Allowed notification transports.

      • Item type: string (notify,email)
  • channel:mature:allowed:  boolean?

    Confirmed mature channels.

  • channel:player:forceflash:  boolean?

    Force the player to the flash version.

UserWithChannel extends User

  • channel:  Channel

    The users channel.

UserWithGroups extends User

  • groups:  Array<UserGroup>

    The groups of the user.

VOD extends TimeStamped

  • id:  uint

    The unique ID of the VOD.

  • baseUrl:  string

    The base URL of a VOD

  • format:  string (hls,raw,dash,thumbnail,chat)

    The format of the recording. It can be in:

  • data:  object?

    Format-specific information about the VOD. Is null when type is chat.

    • Width:  uint

      Present for hls, raw, dash and thumbnail.

    • Height:  uint

      Present for hls, raw, dash and thumbnail.

    • Fps:  number?

      Present for hls, raw and dash.

    • Bitrate:  uint?

      Present for hls, raw and dash.

  • recordingId:  uint

    Id of the parent recording.

VideoManifestResolution

  • name:  string

    The name of the resolution.

  • slug:  string

    The slug of the resolution.

  • width:  uint?

    The width of the stream, only set if hasVideo is true.

  • height:  uint?

    The height of the stream, only set if hasVideo is true.

  • hasVideo:  boolean

    Indicates whether the manifest includes video.

  • bitrate:  uint

    The total bitrate.

ViewerAnalytic

  • channel:  uint
  • anon:  uint

    Number of anonymous viewers watching the channel at a point in time.

  • authed:  uint

    Number of authenticated viewers, including lurkers, watching the channel at a point in time.

  • time:  IsoDate

ViewerCount

  • time:  IsoDate

    The time of the sample.

  • anon:  uint

    Amount of anonymous viewers.

  • authed:  uint

    Amount registered viewers.

ViewerMetricAnalytic

  • channel:  uint
  • country:  string?

    The viewer's two character country code, if it can be determined..

  • browser:  string (chr,ff,ie,ios,sf,an)?

    The viewer's browser, if it can be determined.

  • platform:  string (desktop,tablet,mobile)?

    The viewer's playform, if it can be determined.

  • time:  IsoDate

uint

Unsigned integer.