libZSservicesZSamazonka-gameliftZSamazonka-gamelift
Copyright(c) 2013-2021 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone

Amazonka.GameLift.AcceptMatch

Description

Registers a player's acceptance or rejection of a proposed FlexMatch match. A matchmaking configuration may require player acceptance; if so, then matches built with that configuration cannot be completed unless all players accept the proposed match within a specified time limit.

When FlexMatch builds a match, all the matchmaking tickets involved in the proposed match are placed into status REQUIRES_ACCEPTANCE. This is a trigger for your game to get acceptance from all players in the ticket. Acceptances are only valid for tickets when they are in this status; all other acceptances result in an error.

To register acceptance, specify the ticket ID, a response, and one or more players. Once all players have registered acceptance, the matchmaking tickets advance to status PLACING, where a new game session is created for the match.

If any player rejects the match, or if acceptances are not received before a specified timeout, the proposed match is dropped. The matchmaking tickets are then handled in one of two ways: For tickets where one or more players rejected the match, the ticket status is returned to SEARCHING to find a new match. For tickets where one or more players failed to respond, the ticket status is set to CANCELLED, and processing is terminated. A new matchmaking request for these players can be submitted as needed.

Learn more

Add FlexMatch to a game client

FlexMatch events (reference)

Related actions

StartMatchmaking | DescribeMatchmaking | StopMatchmaking | AcceptMatch | StartMatchBackfill | All APIs by task

Synopsis

Creating a Request

data AcceptMatch Source #

Represents the input for a request operation.

See: newAcceptMatch smart constructor.

Constructors

AcceptMatch' 

Fields

  • ticketId :: Text

    A unique identifier for a matchmaking ticket. The ticket must be in status REQUIRES_ACCEPTANCE; otherwise this request will fail.

  • playerIds :: [Text]

    A unique identifier for a player delivering the response. This parameter can include one or multiple player IDs.

  • acceptanceType :: AcceptanceType

    Player response to the proposed match.

Instances

Instances details
Eq AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Read AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Show AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Generic AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Associated Types

type Rep AcceptMatch :: Type -> Type #

NFData AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Methods

rnf :: AcceptMatch -> () #

Hashable AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

ToJSON AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

AWSRequest AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Associated Types

type AWSResponse AcceptMatch #

ToHeaders AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Methods

toHeaders :: AcceptMatch -> [Header] #

ToPath AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

ToQuery AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

type Rep AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

type Rep AcceptMatch = D1 ('MetaData "AcceptMatch" "Amazonka.GameLift.AcceptMatch" "libZSservicesZSamazonka-gameliftZSamazonka-gamelift" 'False) (C1 ('MetaCons "AcceptMatch'" 'PrefixI 'True) (S1 ('MetaSel ('Just "ticketId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: (S1 ('MetaSel ('Just "playerIds") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 [Text]) :*: S1 ('MetaSel ('Just "acceptanceType") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 AcceptanceType))))
type AWSResponse AcceptMatch Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

newAcceptMatch Source #

Create a value of AcceptMatch with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:ticketId:AcceptMatch', acceptMatch_ticketId - A unique identifier for a matchmaking ticket. The ticket must be in status REQUIRES_ACCEPTANCE; otherwise this request will fail.

$sel:playerIds:AcceptMatch', acceptMatch_playerIds - A unique identifier for a player delivering the response. This parameter can include one or multiple player IDs.

$sel:acceptanceType:AcceptMatch', acceptMatch_acceptanceType - Player response to the proposed match.

Request Lenses

acceptMatch_ticketId :: Lens' AcceptMatch Text Source #

A unique identifier for a matchmaking ticket. The ticket must be in status REQUIRES_ACCEPTANCE; otherwise this request will fail.

acceptMatch_playerIds :: Lens' AcceptMatch [Text] Source #

A unique identifier for a player delivering the response. This parameter can include one or multiple player IDs.

acceptMatch_acceptanceType :: Lens' AcceptMatch AcceptanceType Source #

Player response to the proposed match.

Destructuring the Response

data AcceptMatchResponse Source #

See: newAcceptMatchResponse smart constructor.

Constructors

AcceptMatchResponse' 

Fields

Instances

Instances details
Eq AcceptMatchResponse Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Read AcceptMatchResponse Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Show AcceptMatchResponse Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Generic AcceptMatchResponse Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Associated Types

type Rep AcceptMatchResponse :: Type -> Type #

NFData AcceptMatchResponse Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

Methods

rnf :: AcceptMatchResponse -> () #

type Rep AcceptMatchResponse Source # 
Instance details

Defined in Amazonka.GameLift.AcceptMatch

type Rep AcceptMatchResponse = D1 ('MetaData "AcceptMatchResponse" "Amazonka.GameLift.AcceptMatch" "libZSservicesZSamazonka-gameliftZSamazonka-gamelift" 'False) (C1 ('MetaCons "AcceptMatchResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int)))

newAcceptMatchResponse Source #

Create a value of AcceptMatchResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:httpStatus:AcceptMatchResponse', acceptMatchResponse_httpStatus - The response's http status code.

Response Lenses