games.versions.validateGameVersion


Description

Validates information used to create a new game version.


Code Examples

Request

POST
https://api.rivet.gg/cloud/games/{game_id}/versions/validate
# Write the request body to body.json before running
curl -X POST -d '@body.json' 'https://api.rivet.gg/cloud/games/{game_id}/versions/validate'

Request Parameters

game_id

Path parameter, required


Request Body

config

object (required)

Cloud configuration for a given version.

config.cdn

object

CDN configuration for a given version.

config.cdn.build_command

string

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

config.cdn.build_env

map<string, string>

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

config.cdn.build_output

string

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

config.cdn.routes

array<object>

Multiple CDN version routes.

config.cdn.routes[*].glob

string (required)

config.cdn.routes[*].middlewares

array<object> (required)

Multiple CDN version middleware.

config.cdn.routes[*].middlewares[*].kind

object (required)

config.cdn.routes[*].middlewares[*].kind.custom_headers

object

config.cdn.routes[*].middlewares[*].kind.custom_headers.headers

array<object> (required)

config.cdn.routes[*].middlewares[*].kind.custom_headers.headers[*].name

string (required)

config.cdn.routes[*].middlewares[*].kind.custom_headers.headers[*].value

string (required)

config.cdn.routes[*].priority

integer (required)

Unsigned 32 bit integer.

config.cdn.site_id

string

config.engine

object

config.engine.custom

object

config.engine.godot

object

config.engine.html5

object

config.engine.unity

object

config.engine.unreal

object

config.engine.unreal.game_module

string (required)

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.

config.kv

object

KV configuration for a given version.

config.matchmaker

object

Matchmaker configuration for a given version.

config.matchmaker.captcha

object

Matchmaker captcha configuration.

config.matchmaker.captcha.hcaptcha

object

hCpatcha configuration.

config.matchmaker.captcha.hcaptcha.secret_key

string

Secret key for your hCaptcha application. Must be set.

config.matchmaker.captcha.hcaptcha.site_key

string

Site key for your hCaptcha application. Must be set.

config.matchmaker.captcha.requests_before_reverify

integer (required)

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

config.matchmaker.captcha.turnstile

object

Turnstile captcha configuration.

config.matchmaker.captcha.turnstile.secret_key

string (required)

config.matchmaker.captcha.turnstile.site_key

string (required)

config.matchmaker.captcha.verification_ttl

integer (required)

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

config.matchmaker.dev_hostname

string

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

config.matchmaker.docker

object

A game mode runtime running through Docker.

config.matchmaker.docker.args

array<string>

config.matchmaker.docker.build_args

map<string, string>

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

config.matchmaker.docker.dockerfile

string

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

config.matchmaker.docker.env

map<string, string>

config.matchmaker.docker.image

string

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

config.matchmaker.docker.image_id

string

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.

config.matchmaker.docker.ports

map<string, object>

config.matchmaker.docker.ports.<port>.dev_port

integer

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

config.matchmaker.docker.ports.<port>.dev_port_range

object

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

config.matchmaker.docker.ports.<port>.dev_port_range.max

integer (required)

Unsigned 32 bit integer.

config.matchmaker.docker.ports.<port>.dev_port_range.min

integer (required)

Unsigned 32 bit integer.

config.matchmaker.docker.ports.<port>.dev_protocol

string

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

config.matchmaker.docker.ports.<port>.port

integer

The port number to connect to.

config.matchmaker.docker.ports.<port>.port_range

object

Range of ports that can be connected to. Note that the port range values returned by /find

  • cloud.version.matchmaker.PortProtocol
  • cloud.version.matchmaker.ProxyKind

config.matchmaker.docker.ports.<port>.port_range.max

integer (required)

Unsigned 32 bit integer.

config.matchmaker.docker.ports.<port>.port_range.min

integer (required)

Unsigned 32 bit integer.

config.matchmaker.docker.ports.<port>.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.

config.matchmaker.docker.ports.<port>.proxy

string

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

config.matchmaker.game_modes

map<string, object>

A list of game modes.

config.matchmaker.game_modes.<game_mode>.actions

object

Configuration for the connection types allowed for a game mode.

config.matchmaker.game_modes.<game_mode>.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.

config.matchmaker.game_modes.<game_mode>.actions.create.enable_private

boolean

Defaults to true when unset.

config.matchmaker.game_modes.<game_mode>.actions.create.enable_public

boolean

Defaults to false when unset.

config.matchmaker.game_modes.<game_mode>.actions.create.enabled

boolean (required)

Sets whether or not the /create endpoint is enabled.

config.matchmaker.game_modes.<game_mode>.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.

config.matchmaker.game_modes.<game_mode>.actions.create.verification.headers

map<string, string> (required)

config.matchmaker.game_modes.<game_mode>.actions.create.verification.url

string (required)

config.matchmaker.game_modes.<game_mode>.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.

config.matchmaker.game_modes.<game_mode>.actions.find.enabled

boolean (required)

Sets whether or not the /find endpoint is enabled.

config.matchmaker.game_modes.<game_mode>.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.

config.matchmaker.game_modes.<game_mode>.actions.find.verification.headers

map<string, string> (required)

config.matchmaker.game_modes.<game_mode>.actions.find.verification.url

string (required)

config.matchmaker.game_modes.<game_mode>.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.

config.matchmaker.game_modes.<game_mode>.actions.join.enabled

boolean (required)

Sets whether or not the /join endpoint is enabled.

config.matchmaker.game_modes.<game_mode>.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.

config.matchmaker.game_modes.<game_mode>.actions.join.verification.headers

map<string, string> (required)

config.matchmaker.game_modes.<game_mode>.actions.join.verification.url

string (required)

config.matchmaker.game_modes.<game_mode>.allow_dynamic_max_players

boolean

config.matchmaker.game_modes.<game_mode>.docker

object

A game mode runtime running through Docker.

config.matchmaker.game_modes.<game_mode>.docker.args

array<string>

config.matchmaker.game_modes.<game_mode>.docker.build_args

map<string, string>

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

config.matchmaker.game_modes.<game_mode>.docker.dockerfile

string

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

config.matchmaker.game_modes.<game_mode>.docker.env

map<string, string>

config.matchmaker.game_modes.<game_mode>.docker.image

string

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

config.matchmaker.game_modes.<game_mode>.docker.image_id

string

config.matchmaker.game_modes.<game_mode>.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.

config.matchmaker.game_modes.<game_mode>.docker.ports

map<string, object>

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.dev_port

integer

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

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.dev_port_range

object

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

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.dev_port_range.max

integer (required)

Unsigned 32 bit integer.

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.dev_port_range.min

integer (required)

Unsigned 32 bit integer.

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.dev_protocol

string

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

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.port

integer

The port number to connect to.

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.port_range

object

Range of ports that can be connected to. Note that the port range values returned by /find

  • cloud.version.matchmaker.PortProtocol
  • cloud.version.matchmaker.ProxyKind

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.port_range.max

integer (required)

Unsigned 32 bit integer.

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.port_range.min

integer (required)

Unsigned 32 bit integer.

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.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.

config.matchmaker.game_modes.<game_mode>.docker.ports.<port>.proxy

string

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

config.matchmaker.game_modes.<game_mode>.idle_lobbies

object

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

config.matchmaker.game_modes.<game_mode>.idle_lobbies.max

integer (required)

config.matchmaker.game_modes.<game_mode>.idle_lobbies.min

integer (required)

config.matchmaker.game_modes.<game_mode>.listable

boolean

config.matchmaker.game_modes.<game_mode>.max_players

integer

config.matchmaker.game_modes.<game_mode>.max_players_direct

integer

config.matchmaker.game_modes.<game_mode>.max_players_party

integer

config.matchmaker.game_modes.<game_mode>.regions

map<string, object>

config.matchmaker.game_modes.<game_mode>.regions.<region>.idle_lobbies

object

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

config.matchmaker.game_modes.<game_mode>.regions.<region>.idle_lobbies.max

integer (required)

config.matchmaker.game_modes.<game_mode>.regions.<region>.idle_lobbies.min

integer (required)

config.matchmaker.game_modes.<game_mode>.regions.<region>.tier

string

config.matchmaker.game_modes.<game_mode>.taggable

boolean

config.matchmaker.game_modes.<game_mode>.tier

string

config.matchmaker.idle_lobbies

object

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

config.matchmaker.idle_lobbies.max

integer (required)

config.matchmaker.idle_lobbies.min

integer (required)

config.matchmaker.max_players

integer

config.matchmaker.max_players_direct

integer

config.matchmaker.max_players_party

integer

config.matchmaker.regions

map<string, object>

config.matchmaker.regions.<region>.idle_lobbies

object

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

config.matchmaker.regions.<region>.idle_lobbies.max

integer (required)

config.matchmaker.regions.<region>.idle_lobbies.min

integer (required)

config.matchmaker.regions.<region>.tier

string

config.matchmaker.tier

string

config.scripts

map<string, string>

display_name

string (required)

Represent a resource's readable display name.


Response Body

errors

array<object> (required)

A list of validation errors.

errors[*].path

array<string> (required)

A list of strings denoting the origin of a validation error.

On this page


Rivet

Open-source multiplayer infrastructure. Easy, flexible, and affordable.

This website is not sponsored by or affiliated with Unity Technologies or its affiliates. Unity Trademark(s) are trademark(s) or registered trademark(s) of Unity Technologies or its affiliates in the U.S. and elsewhere. | This website is not sponsored by, affiliated with, or endorsed by Epic Games, Inc. or its affiliates. 'Unreal Engine' is a trademark or registered trademark of Epic Games, Inc. in the U.S. and elsewhere. | The HTML5 Logo by the World Wide Web Consortium (W3C), used under a Creative Commons Attribution 3.0 License. Source | The Godot Engine Logo by the Andrea Calabró, used under a Creative Commons Attribution 4.0 International License. Source | Docker and the Docker logo are trademarks or registered trademarks of Docker, Inc. in the United States and/or other countries. Docker, Inc. and other parties may also have trademark rights in other terms used herein.

© 2024 Rivet Gaming, Inc. All rights reserved.