Skip to content

GameLiftClient#

Index > GameLift > GameLiftClient

Auto-generated documentation for GameLift type annotations stubs module mypy-boto3-gamelift.

GameLiftClient#

Type annotations and code completion for boto3.client("gamelift"). boto3 documentation

# GameLiftClient usage example

from boto3.session import Session
from mypy_boto3_gamelift.client import GameLiftClient

def get_gamelift_client() -> GameLiftClient:
    return Session().client("gamelift")

Exceptions#

boto3 client exceptions are generated in runtime. This class provides code completion for boto3.client("gamelift").exceptions structure.

# Exceptions.exceptions usage example

client = boto3.client("gamelift")

try:
    do_something(client)
except (
    client.exceptions.ClientError,
    client.exceptions.ConflictException,
    client.exceptions.FleetCapacityExceededException,
    client.exceptions.GameSessionFullException,
    client.exceptions.IdempotentParameterMismatchException,
    client.exceptions.InternalServiceException,
    client.exceptions.InvalidFleetStatusException,
    client.exceptions.InvalidGameSessionStatusException,
    client.exceptions.InvalidRequestException,
    client.exceptions.LimitExceededException,
    client.exceptions.NotFoundException,
    client.exceptions.NotReadyException,
    client.exceptions.OutOfCapacityException,
    client.exceptions.TaggingFailedException,
    client.exceptions.TerminalRoutingStrategyException,
    client.exceptions.UnauthorizedException,
    client.exceptions.UnsupportedRegionException,
) as e:
    print(e)
# Exceptions.exceptions type checking example

from mypy_boto3_gamelift.client import Exceptions

def handle_error(exc: Exceptions.ClientError) -> None:
    ...

Methods#

accept_match#

Registers a player's acceptance or rejection of a proposed FlexMatch match.

Type annotations and code completion for boto3.client("gamelift").accept_match method. boto3 documentation

# accept_match method definition

def accept_match(
    self,
    *,
    TicketId: str,
    PlayerIds: Sequence[str],
    AcceptanceType: AcceptanceTypeType,  # (1)
) -> Dict[str, Any]:
    ...
  1. See AcceptanceTypeType
# accept_match method usage example with argument unpacking

kwargs: AcceptMatchInputRequestTypeDef = {  # (1)
    "TicketId": ...,
    "PlayerIds": ...,
    "AcceptanceType": ...,
}

parent.accept_match(**kwargs)
  1. See AcceptMatchInputRequestTypeDef

can_paginate#

Check if an operation can be paginated.

Type annotations and code completion for boto3.client("gamelift").can_paginate method. boto3 documentation

# can_paginate method definition

def can_paginate(
    self,
    operation_name: str,
) -> bool:
    ...

claim_game_server#

This operation is used with the Amazon GameLift FleetIQ solution and game server groups. Locates an available game server and temporarily reserves it to host gameplay and players.

Type annotations and code completion for boto3.client("gamelift").claim_game_server method. boto3 documentation

# claim_game_server method definition

def claim_game_server(
    self,
    *,
    GameServerGroupName: str,
    GameServerId: str = ...,
    GameServerData: str = ...,
    FilterOption: ClaimFilterOptionTypeDef = ...,  # (1)
) -> ClaimGameServerOutputTypeDef:  # (2)
    ...
  1. See ClaimFilterOptionTypeDef
  2. See ClaimGameServerOutputTypeDef
# claim_game_server method usage example with argument unpacking

kwargs: ClaimGameServerInputRequestTypeDef = {  # (1)
    "GameServerGroupName": ...,
}

parent.claim_game_server(**kwargs)
  1. See ClaimGameServerInputRequestTypeDef

close#

Closes underlying endpoint connections.

Type annotations and code completion for boto3.client("gamelift").close method. boto3 documentation

# close method definition

def close(
    self,
) -> None:
    ...

create_alias#

Creates an alias for a fleet.

Type annotations and code completion for boto3.client("gamelift").create_alias method. boto3 documentation

# create_alias method definition

def create_alias(
    self,
    *,
    Name: str,
    RoutingStrategy: RoutingStrategyTypeDef,  # (1)
    Description: str = ...,
    Tags: Sequence[TagTypeDef] = ...,  # (2)
) -> CreateAliasOutputTypeDef:  # (3)
    ...
  1. See RoutingStrategyTypeDef
  2. See TagTypeDef
  3. See CreateAliasOutputTypeDef
# create_alias method usage example with argument unpacking

kwargs: CreateAliasInputRequestTypeDef = {  # (1)
    "Name": ...,
    "RoutingStrategy": ...,
}

parent.create_alias(**kwargs)
  1. See