GameLift service API reference (AWS SDK) - Amazon GameLift

GameLift service API reference (AWS SDK)

This topic provides a task-based list of API operations for use with GameLift managed hosting solutions, including hosting for custom game servers and Realtime Servers. These operations are packaged into the AWS SDK in the aws.gamelift namespace. Download the AWS SDK or view the Amazon GameLift API reference documentation.

The API includes two sets of operations for managed game hosting:

The GameLift Service API also contains operations for use with other GameLift tools and solutions. For a list of FleetIQ APIs, see FleetIQ API actions. For a list of FlexMatch APIs for matchmaking, see FlexMatch API actions.

Set up and manage GameLift hosting resources

Call these operations to configure hosting resources for your game servers, scale capacity to meet player demand, access performance and utilization metrics, and more. These API operations are used with game servers that are hosted on GameLift, including Realtime Servers. You can use the GameLift Console for most resource management tasks, or you can make calls to the service using the AWS Command Line Interface (AWS CLI) tool or the AWS SDK.

Prepare game servers for deployment

Upload and configure your game's game server code in preparation for deployment and launching on hosting resources.

Manage custom game server builds

  • upload-build – Upload build files from a local path and create a new GameLift build resource. This operation, available only as an AWS CLI command, is the most common method for uploading game server builds.

  • CreateBuild – Create a new build using files stored in an Amazon S3 bucket.

  • ListBuilds – Get a list of all builds uploaded to a GameLift region.

  • DescribeBuild – Retrieve information associated with a build.

  • UpdateBuild – Change build metadata, including build name and version.

  • DeleteBuild – Remove a build from GameLift.

Manage Realtime Servers configuration scripts

  • CreateScript – Upload JavaScript files and create a new GameLift script resource.

  • ListScripts – Get a list of all Realtime scripts uploaded to a GameLift region.

  • DescribeScript – Retrieve information associated with a Realtime script.

  • UpdateScript – Change script metadata and upload revised script content.

  • DeleteScript – Remove a Realtime script from GameLift.

Set up computing resources for hosting

Configure hosting resources and deploy them with your game server build or Realtime configuration script.

Create and manage fleets

Manage fleet capacity

Monitor fleet activity.

  • DescribeFleetUtilization – Retrieve statistics on the number of server processes, game sessions, and players that are currently active on a fleet.

  • DescribeFleetEvents – View logged events for a fleet during a specified time span.

  • DescribeGameSessions – Retrieve game session metadata, including a game's running time and current player count.

Set up queues for optimal game session placement

Set up multi-fleet, multi-region queues to place game sessions with the best available hosting resources for cost, latency, and resiliency.

Manage aliases

Use aliases to represent your fleets or create a terminal alternative destination. Aliases are useful when transitioning game activity from one fleet to another, such as during game server build updates.

  • CreateAlias – Define a new alias and optionally assign it to a fleet.

  • ListAliases – Get all fleet aliases defined in a GameLift region.

  • DescribeAlias – Retrieve information on an existing alias.

  • UpdateAlias – Change settings for an alias, such as redirecting it from one fleet to another.

  • DeleteAlias – Remove an alias from the region.

  • ResolveAlias – Get the fleet ID that a specified alias points to.

Access hosting instances

View information on individual instances in a fleet, or request remote access to a specified fleet instance for troubleshooting.

  • DescribeInstances – Get information on each instance in a fleet, including instance ID, IP address, and status.

  • GetInstanceAccess – Request access credentials needed to remotely connect to a specified instance in a fleet.

Set up VPC peering

Create and manage VPC peering connections between your GameLift hosting resources and other AWS resources.

Start game sessions and join players

Call these operations from your game client service to start new game sessions, get information on existing game sessions, and join players to game ssessions. These operations are for use with custom game servers that are hosted on GameLift. If you're using Realtime Servers, manage game sessions using the Realtime Servers Client API (C#) Reference.

  • Start new game sessions for one or more players.

    • StartGameSessionPlacement – Ask GameLift to find the best available hosting resources and start a new game session. This is the preferred method for creating new game sessions, because it relies on queues to track hosting availability across multiple regions, and uses FleetIQ optimizations to find the lowest cost resources and try to minimize player latency.

    • DescribeGameSessionPlacement – Get details and status on a placement request.

    • StopGameSessionPlacement – Cancel a placement request.

    • CreateGameSession – Start a new, empty game session on a specific fleet. This operation gives you greater control over where to start the game session, instead of relying on FleetIQ to evaluate placement options. In addition, you must add players to the new game session in a separate step. Available in GameLift Local.

  • Get players into existing game sessionss. Find running game sessions with available player slots and reserve them for new players.

    • CreatePlayerSession – Reserve an open slot for a player to join a game session. Available in GameLift Local.

    • CreatePlayerSessions – Reserve open slots for multiple players to join a game session. Available in GameLift Local.

  • Work with game session and player session data. Manage information on game sessions and player sessions.

    • SearchGameSessions – Request a list of active game sessions based on a set of search criteria.

    • DescribeGameSessions – Retrieve metadata for specific game sessions, including length of time active and current player count. Available in GameLift Local.

    • DescribeGameSessionDetails – Retrieve metadata, including the game session protection setting, for one or more game sessions.

    • DescribePlayerSessions – Get details on player activity, including status, playing time, and player data. Available in GameLift Local.

    • UpdateGameSession – Change game session settings, such as maximum player count and join policy.

    • GetGameSessionLogUrl – Get the location of saved logs for a game session.

Available programming languages

The AWS SDK with Amazon GameLift is available in the following languages. See documentation for each language for details on support for development environments.