Create a matchmaking configuration - Amazon GameLift

Create a matchmaking configuration

To set up a FlexMatch matchmaker to process matchmaking requests, you create a matchmaking configuration. Use either the GameLift console or the AWS Command Line Interface (AWS CLI). For more detailed information on designing your matchmaker, see Design a FlexMatch matchmaker.

Create a matchmaker for GameLift hosting

Before creating a matchmaking configuration, you must create your rule set and a GameLift game session queue to use with the matchmaker.

Console
  1. Open the GameLift console at https://console.aws.amazon.com/gamelift/home.

  2. Switch to the region where you want to place your matchmaker. See Choose an AWS Region for the matchmaker for a list of regions that support FlexMatch matchmaking configurations.

  3. From the main menu, choose Create matchmaking configuration. Fill in the matchmaking configuration details.

    • Name – Create a meaningful matchmaker name so you can easily identify it in a list and in metrics. The matchmaker name must be unique within a region. Matchmaking requests identify which matchmaker to use by its name and region.

    • Description – (Optional) Add a description of the matchmaker. The description is used for identification only; it is not used in the matchmaking process.

    • Request timeout – Enter the maximum amount of time, in seconds, for the matchmaker to complete a match for each request. Matchmaking requests that exceed this time are terminated.

    • FlexMatch mode – Choose the "with queue" option. This indicates that GameLift managed hosting is being used, and prompts FlexMatch to pass successful matches to the specified game session queue.

    • Queue – Choose the game session queue to use with this matchmaker. To find the queue, first choose the region where the queue is configured. Then choose the queue you want from the list of available queues in that region.

    • Acceptance required – (Optional) Indicate whether to require each player in a proposed match to actively accept participation in the match. If you chose yes, indicate how long you want the matchmaker to wait for player acceptances before canceling the match.

    • Rule set name – Choose a rule set from the list to use with this matchmaker. The list contains all rule sets that have been created in the current region.

    • Notification target – (Optional) Enter the ARN of an SNS topic for receiving matchmaking event notifications. If you haven't set one up yet, you can add this information later by editing the matchmaking configuration. See Set up FlexMatch event notification

    • Additional players – (Optional) Specify the number of player slots to remain unfilled in each new match. These slots can be filled with players in the future.

    • Custom event data – (Optional) Specify any data you want to associate with this matchmaker in event messaging. This data is included in every event that is associated with the matchmaker.

    • Game data – (Optional) Provide additional game-related information to be delivered to every new game session that is started with matches made using this matchmaking configuration. You can provide the information as either a single string value (use the Game session data field) or as a set of key-value pairs (use the Game properties field).

  4. Once you've finished configuring a matchmaker, click Create. If the creation is successful, the matchmaker is immediately ready to accept matchmaking requests.

AWS CLI

To create a matchmaking configuration with the AWS CLI, open a command line window and use the create-matchmaking-configuration command to define a new matchmaker. See complete documentation on this command in the AWS CLI Command Reference. Get and install the AWS Command Line Interface tool.

This example creates a new matchmaking configuration that requires player acceptance and enables automatic backfill. It also reserves two player slots for additional players to be added later and provides some game session data.

$ AWS gamelift create-matchmaking-configuration --name "SampleMatchamker123" --description "The sample test matchmaker with acceptance" --flexmatch-mode "WITH_QUEUE" --game-session-queue-arns "arn:aws:gamelift:us-west-2:111122223333:gamesessionqueue/My_Game_Session_Queue_One" --rule-set-name "My_Rule_Set_One" --request-timeout-seconds "120" --acceptance-required "true" --acceptance-timeout-seconds "30" --backfill-mode "AUTOMATIC" --notification-target "arn:aws:sns:us-west-2:111122223333:My_Matchmaking_SNS_Topic" --additional-player-count "2" --game-session-data "key=map,value=winter444"

Copiable version:

AWS gamelift create-matchmaking-configuration --name "SampleMatchamker123" --description "The sample test matchmaker with acceptance" --flexmatch-mode "WITH_QUEUE" --game-session-queue-arns "arn:aws:gamelift:us-west-2:111122223333:gamesessionqueue/My_Game_Session_Queue_One" --rule-set-name "My_Rule_Set_One" --request-timeout-seconds "120" --acceptance-required "true" --acceptance-timeout-seconds "30" --backfill-mode "AUTOMATIC" --notification-target "arn:aws:sns:us-west-2:111122223333:My_Matchmaking_SNS_Topic" --additional-player-count "2" --game-session-data "key=map,value=winter444"

If the matchmaking configuration creation request is successful, GameLift returns a MatchmakingConfiguration object with the settings that you requested for the matchmaker. The new matchmaker is immediately ready to accept matchmaking requests.

Create a matchmaker for standalone FlexMatch

Before creating a matchmaking configuration, you must create a rule set to use with the matchmaker.

Console
  1. Open the GameLift console at https://console.aws.amazon.com/gamelift/home.

  2. Switch to the region where you want to place your matchmaker. See Choose an AWS Region for the matchmaker for a list of regions that support FlexMatch matchmaking configurations.

  3. From the main menu, choose Create matchmaking configuration. Fill in the matchmaking configuration details.

    • Name – Create a meaningful matchmaker name so you can easily identify it in a list and in metrics. The matchmaker name must be unique within a region. Matchmaking requests identify which matchmaker to use by its name and region.

    • Description – (Optional) Add a description of the matchmaker. The description is used for identification only; it is not used in the matchmaking process.

    • Request timeout – Type the maximum amount of time, in seconds, for the matchmaker to complete a match for each request. Matchmaking requests that exceed this time are terminated.

    • FlexMatch mode – Choose the "standalone" option. This indicates that the game has a custom mechanism for starting new game sessions on a non-GameLift hosting solution.

    • Acceptance required – (Optional) Indicate whether to require each player in a proposed match to actively accept participation in the match. If you choose yes, indicate how long you want the matchmaker to wait for player acceptances before canceling the match.

    • Rule set name – Choose the rule set to use with this matchmaker. The list contains all rule sets that have been created in the current region.

    • Notification target – (Optional) Type the ARN of an SNS topic for receiving matchmaking event notifications. If you haven't set one up yet, you can add this information later by editing the matchmaking configuration. See Set up FlexMatch event notification.

    • Custom event data – (Optional) Specify any data you want to associate with this matchmaker in event messaging. This data is included in every event that is associated with the matchmaker.

  4. Once you've finished configuring a matchmaker, click Create. If the creation is successful, the matchmaker is immediately ready to accept matchmaking requests.

AWS CLI

To create a matchmaking configuration with the AWS CLI, open a command line window and use the create-matchmaking-configuration command to define a new matchmaker. See complete documentation on this command in the AWS CLI Command Reference. Get and install the AWS Command Line Interface tool.

This example creates a new matchmaking configuration for a standalone matchmaker that requires player acceptance.

$ AWS gamelift create-matchmaking-configuration --name "SampleMatchamker123" --description "The sample test matchmaker with acceptance" --flexmatch-mode "STANDALONE" --rule-set-name "My_Rule_Set_One" --request-timeout-seconds "120" --acceptance-required "true" --acceptance-timeout-seconds "30" --backfill-mode "MANUAL" --notification-target "arn:aws:sns:us-west-2:111122223333:My_Matchmaking_SNS_Topic"

Copiable version:

AWS gamelift create-matchmaking-configuration --name "SampleMatchamker123" --description "The sample test matchmaker with acceptance" --flexmatch-mode "STANDALONE" --rule-set-name "My_Rule_Set_One" --request-timeout-seconds "120" --acceptance-required "true" --acceptance-timeout-seconds "30" --backfill-mode "MANUAL" --notification-target "arn:aws:sns:us-west-2:111122223333:My_Matchmaking_SNS_Topic"

If the matchmaking configuration creation request is successful, GameLift returns a MatchmakingConfiguration object with the settings that you requested for the matchmaker. The new matchmaker is immediately ready to accept matchmaking requests.