games.versions.getGameVersionById


Description

Returns a game version by its version ID.


Code Examples

curl -X GET 'https://api.rivet.gg/cloud/games/{game_id}/versions/{version_id}'

Request Parameters

game_id

required path parameter

version_id

required path parameter

Response Body

  • version
    object

    A full version.

    • version.version_id
      string
    • version.create_ts
      string

      RFC3339 timestamp

    • version.display_name
      string

      Represent a resource's readable display name.

    • version.config
      object

      Cloud configuration for a given version.

      • version.config.scripts
        union of empty object and string
      • version.config.engine
        object
        • version.config.engine.unity
          empty object
        • version.config.engine.unreal
          object
          • version.config.engine.unreal.game_module
            string

            Name of the Unreal module that holds the game code. This is usually the value of $.Modules[0].Name in the file MyProject.unproject. Configures Rivet CLI behavior. Has no effect on server behavior.

        • version.config.engine.godot
          empty object
        • version.config.engine.html5
          empty object
        • version.config.engine.custom
          empty object
      • version.config.cdn
        object

        CDN configuration for a given version.

        • version.config.cdn.build_command
          string

          Configures Rivet CLI behavior. Has no effect on server behavior.

        • version.config.cdn.build_output
          string

          Configures Rivet CLI behavior. Has no effect on server behavior.

        • version.config.cdn.build_env
          union of empty object and string

          Configures Rivet CLI behavior. Has no effect on server behavior.

        • version.config.cdn.site_id
          string
        • version.config.cdn.routes
          array of objects

          Multiple CDN version routes.

          • version.config.cdn.routes.glob
            string
          • version.config.cdn.routes.priority
            number

            Unsigned 32 bit integer.

          • version.config.cdn.routes.middlewares
            array of objects

            Multiple CDN version middleware.

            • version.config.cdn.routes.middlewares.kind
              object
              • version.config.cdn.routes.middlewares.kind.custom_headers
                object
                • version.config.cdn.routes.middlewares.kind.custom_headers.headers
                  array of objects
                  • version.config.cdn.routes.middlewares.kind.custom_headers.headers.name
                    string
                  • version.config.cdn.routes.middlewares.kind.custom_headers.headers.value
                    string
      • version.config.matchmaker
        object

        Matchmaker configuration for a given version.

        • version.config.matchmaker.game_modes
          union of empty object and object

          A list of game modes.

            • version.config.matchmaker.game_modes.regions
              union of empty object and object
                • version.config.matchmaker.game_modes.regions.tier
                  string
                • version.config.matchmaker.game_modes.regions.idle_lobbies
                  object

                  Configuration for how many idle lobbies a game version should have.

                  • version.config.matchmaker.game_modes.regions.idle_lobbies.min
                    number
                  • version.config.matchmaker.game_modes.regions.idle_lobbies.max
                    number
            • version.config.matchmaker.game_modes.max_players
              number
            • version.config.matchmaker.game_modes.max_players_direct
              number
            • version.config.matchmaker.game_modes.max_players_party
              number
            • version.config.matchmaker.game_modes.docker
              object

              A game mode runtime running through Docker.

              • version.config.matchmaker.game_modes.docker.dockerfile
                string

                Configures Rivet CLI behavior. Has no effect on server behavior.

              • version.config.matchmaker.game_modes.docker.build_args
                union of empty object and string

                Configures Rivet CLI behavior. Has no effect on server behavior.

              • version.config.matchmaker.game_modes.docker.image
                string

                Configures Rivet CLI behavior. Has no effect on server behavior.

              • version.config.matchmaker.game_modes.docker.image_id
                string
              • version.config.matchmaker.game_modes.docker.args
                array of strings
              • version.config.matchmaker.game_modes.docker.env
                union of empty object and string
              • version.config.matchmaker.game_modes.docker.network_mode
                string

                Configures how the container's network is isolated from the host. bridge (default) networking isolates the container's network from the host & other containers. host networking removes isolation between the container and the host. Only available in Rivet Open Source & Enterprise. Read more about bridge vs host networking here.

              • version.config.matchmaker.game_modes.docker.ports
                union of empty object and object
                  • version.config.matchmaker.game_modes.docker.ports.port
                    number
                  • version.config.matchmaker.game_modes.docker.ports.port_range
                    object

                    Range of ports that can be connected to. If configured, network_mode must equal host. Port ranges may overlap between containers, it is the responsibility of the developer to ensure ports are available before using. Read more about host networking here. Only available on Rivet Open Source & Enterprise.

                    Related

                    • cloud.version.matchmaker.PortProtocol
                    • cloud.version.matchmaker.ProxyKind
                    • version.config.matchmaker.game_modes.docker.ports.port_range.min
                      number

                      Unsigned 32 bit integer.

                    • version.config.matchmaker.game_modes.docker.ports.port_range.max
                      number

                      Unsigned 32 bit integer.

                  • version.config.matchmaker.game_modes.docker.ports.protocol
                    string

                    Signifies the protocol of the port. Note that when proxying through GameGuard (via ProxyKind), the port number returned by /find, /join, and /create will not be the same as the port number configured in the config:

                    • With HTTP, the port will always be 80. The hostname of the port correctly routes the incoming connection to the correct port being used by the game server.
                    • With HTTPS, the port will always be 443. The hostname of the port correctly routes the incoming connection to the correct port being used by the game server.
                    • Using TCP/UDP, the port will be a random number between 26000 and 31999. This gets automatically routed to the correct port being used by the game server.

                    Related - cloud.version.matchmaker.GameModeRuntimeDockerPort - cloud.version.matchmaker.ProxyKind - /docs/dynamic-servers/concepts/game-guard - matchmaker.lobbies.find

                  • version.config.matchmaker.game_modes.docker.ports.proxy
                    string

                    How this port should be proxied. Defaults to 'game-guard`.

                  • version.config.matchmaker.game_modes.docker.ports.dev_port
                    number

                    Configures Rivet CLI behavior. Has no effect on server behavior.

                  • version.config.matchmaker.game_modes.docker.ports.dev_port_range
                    object

                    Configures Rivet CLI behavior. Has no effect on server behavior.

                    • version.config.matchmaker.game_modes.docker.ports.dev_port_range.min
                      number

                      Unsigned 32 bit integer.

                    • version.config.matchmaker.game_modes.docker.ports.dev_port_range.max
                      number

                      Unsigned 32 bit integer.

                  • version.config.matchmaker.game_modes.docker.ports.dev_protocol
                    string

                    Configures Rivet CLI behavior. Has no effect on server behavior.

            • version.config.matchmaker.game_modes.listable
              boolean
            • version.config.matchmaker.game_modes.taggable
              boolean
            • version.config.matchmaker.game_modes.allow_dynamic_max_players
              boolean
            • version.config.matchmaker.game_modes.actions
              object

              Configuration for the connection types allowed for a game mode.

              • version.config.matchmaker.game_modes.actions.find
                object

                Configures the requirements and authentication for the /find endpoint. If this value is not set in the config, the /find endpoint is still enabled.

                • version.config.matchmaker.game_modes.actions.find.enabled
                  boolean

                  Sets whether or not the /find endpoint is enabled.

                • version.config.matchmaker.game_modes.actions.find.identity_requirement
                  any value
                • version.config.matchmaker.game_modes.actions.find.verification
                  object

                  Configuration that tells Rivet where to send validation requests and with what headers. When set, Rivet will send the verification_data property (given by the user in the find/join/create endpoint) to the given url along with the headers provided and some information about the requested lobby. The response of this request will determine if the user can join that lobby or not.

                  • version.config.matchmaker.game_modes.actions.find.verification.url
                    string
                  • version.config.matchmaker.game_modes.actions.find.verification.headers
                    union of empty object and string
              • version.config.matchmaker.game_modes.actions.join
                object

                Configures the requirements and authentication for the /join endpoint. If this value is not set in the config, the /join endpoint is still enabled.

                • version.config.matchmaker.game_modes.actions.join.enabled
                  boolean

                  Sets whether or not the /join endpoint is enabled.

                • version.config.matchmaker.game_modes.actions.join.identity_requirement
                  any value
                • version.config.matchmaker.game_modes.actions.join.verification
                  object

                  Configuration that tells Rivet where to send validation requests and with what headers. When set, Rivet will send the verification_data property (given by the user in the find/join/create endpoint) to the given url along with the headers provided and some information about the requested lobby. The response of this request will determine if the user can join that lobby or not.

                  • version.config.matchmaker.game_modes.actions.join.verification.url
                    string
                  • version.config.matchmaker.game_modes.actions.join.verification.headers
                    union of empty object and string
              • version.config.matchmaker.game_modes.actions.create
                object

                Configures the requirements and authentication for the /create endpoint. If this value is not set in the config, the /create endpoint is NOT enabled.

                • version.config.matchmaker.game_modes.actions.create.enabled
                  boolean

                  Sets whether or not the /create endpoint is enabled.

                • version.config.matchmaker.game_modes.actions.create.identity_requirement
                  any value
                • version.config.matchmaker.game_modes.actions.create.verification
                  object

                  Configuration that tells Rivet where to send validation requests and with what headers. When set, Rivet will send the verification_data property (given by the user in the find/join/create endpoint) to the given url along with the headers provided and some information about the requested lobby. The response of this request will determine if the user can join that lobby or not.

                  • version.config.matchmaker.game_modes.actions.create.verification.url
                    string
                  • version.config.matchmaker.game_modes.actions.create.verification.headers
                    union of empty object and string
                • version.config.matchmaker.game_modes.actions.create.enable_public
                  boolean

                  Defaults to false when unset.

                • version.config.matchmaker.game_modes.actions.create.enable_private
                  boolean

                  Defaults to true when unset.

                • version.config.matchmaker.game_modes.actions.create.max_lobbies_per_identity
                  any value
            • version.config.matchmaker.game_modes.tier
              string
            • version.config.matchmaker.game_modes.idle_lobbies
              object

              Configuration for how many idle lobbies a game version should have.

              • version.config.matchmaker.game_modes.idle_lobbies.min
                number
              • version.config.matchmaker.game_modes.idle_lobbies.max
                number
        • version.config.matchmaker.captcha
          object

          Matchmaker captcha configuration.

          • version.config.matchmaker.captcha.requests_before_reverify
            number

            Denotes how many requests a connection can make before it is required to reverify a captcha.

          • version.config.matchmaker.captcha.verification_ttl
            number

            Denotes how long a connection can continue to reconnect without having to reverify a captcha (in milliseconds).

          • version.config.matchmaker.captcha.hcaptcha
            object

            hCpatcha configuration.

            • version.config.matchmaker.captcha.hcaptcha.level
              any value
            • version.config.matchmaker.captcha.hcaptcha.site_key
              string

              Site key for your hCaptcha application. Must be set.

            • version.config.matchmaker.captcha.hcaptcha.secret_key
              string

              Secret key for your hCaptcha application. Must be set.

          • version.config.matchmaker.captcha.turnstile
            object

            Turnstile captcha configuration.

            • version.config.matchmaker.captcha.turnstile.site_key
              string
            • version.config.matchmaker.captcha.turnstile.secret_key
              string
        • version.config.matchmaker.dev_hostname
          string

          Configures Rivet CLI behavior. Has no effect on server behavior.

        • version.config.matchmaker.regions
          union of empty object and object
            • version.config.matchmaker.regions.tier
              string
            • version.config.matchmaker.regions.idle_lobbies
              object

              Configuration for how many idle lobbies a game version should have.

              • version.config.matchmaker.regions.idle_lobbies.min
                number
              • version.config.matchmaker.regions.idle_lobbies.max
                number
        • version.config.matchmaker.max_players
          number
        • version.config.matchmaker.max_players_direct
          number
        • version.config.matchmaker.max_players_party
          number
        • version.config.matchmaker.docker
          object

          A game mode runtime running through Docker.

          • version.config.matchmaker.docker.dockerfile
            string

            Configures Rivet CLI behavior. Has no effect on server behavior.

          • version.config.matchmaker.docker.build_args
            union of empty object and string

            Configures Rivet CLI behavior. Has no effect on server behavior.

          • version.config.matchmaker.docker.image
            string

            Configures Rivet CLI behavior. Has no effect on server behavior.

          • version.config.matchmaker.docker.image_id
            string
          • version.config.matchmaker.docker.args
            array of strings
          • version.config.matchmaker.docker.env
            union of empty object and string
          • version.config.matchmaker.docker.network_mode
            string

            Configures how the container's network is isolated from the host. bridge (default) networking isolates the container's network from the host & other containers. host networking removes isolation between the container and the host. Only available in Rivet Open Source & Enterprise. Read more about bridge vs host networking here.

          • version.config.matchmaker.docker.ports
            union of empty object and object
              • version.config.matchmaker.docker.ports.port
                number
              • version.config.matchmaker.docker.ports.port_range
                object

                Range of ports that can be connected to. If configured, network_mode must equal host. Port ranges may overlap between containers, it is the responsibility of the developer to ensure ports are available before using. Read more about host networking here. Only available on Rivet Open Source & Enterprise.

                Related

                • cloud.version.matchmaker.PortProtocol
                • cloud.version.matchmaker.ProxyKind
                • version.config.matchmaker.docker.ports.port_range.min
                  number

                  Unsigned 32 bit integer.

                • version.config.matchmaker.docker.ports.port_range.max
                  number

                  Unsigned 32 bit integer.

              • version.config.matchmaker.docker.ports.protocol
                string

                Signifies the protocol of the port. Note that when proxying through GameGuard (via ProxyKind), the port number returned by /find, /join, and /create will not be the same as the port number configured in the config:

                • With HTTP, the port will always be 80. The hostname of the port correctly routes the incoming connection to the correct port being used by the game server.
                • With HTTPS, the port will always be 443. The hostname of the port correctly routes the incoming connection to the correct port being used by the game server.
                • Using TCP/UDP, the port will be a random number between 26000 and 31999. This gets automatically routed to the correct port being used by the game server.

                Related - cloud.version.matchmaker.GameModeRuntimeDockerPort - cloud.version.matchmaker.ProxyKind - /docs/dynamic-servers/concepts/game-guard - matchmaker.lobbies.find

              • version.config.matchmaker.docker.ports.proxy
                string

                How this port should be proxied. Defaults to 'game-guard`.

              • version.config.matchmaker.docker.ports.dev_port
                number

                Configures Rivet CLI behavior. Has no effect on server behavior.

              • version.config.matchmaker.docker.ports.dev_port_range
                object

                Configures Rivet CLI behavior. Has no effect on server behavior.

                • version.config.matchmaker.docker.ports.dev_port_range.min
                  number

                  Unsigned 32 bit integer.

                • version.config.matchmaker.docker.ports.dev_port_range.max
                  number

                  Unsigned 32 bit integer.

              • version.config.matchmaker.docker.ports.dev_protocol
                string

                Configures Rivet CLI behavior. Has no effect on server behavior.

        • version.config.matchmaker.tier
          string
        • version.config.matchmaker.idle_lobbies
          object

          Configuration for how many idle lobbies a game version should have.

          • version.config.matchmaker.idle_lobbies.min
            number
          • version.config.matchmaker.idle_lobbies.max
            number
        • version.config.matchmaker.lobby_groups
          any value
      • version.config.kv
        empty object

        KV configuration for a given version.

      • version.config.identity
        any value