amazonka-gamelift-1.5.0: Amazon GameLift SDK.

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

Network.AWS.GameLift.CreatePlayerSessions

Contents

Description

Adds a group of players to a game session. This action is useful with a team matching feature. Before players can be added, a game session must have an ACTIVE status, have a creation policy of ALLOW_ALL , and have an open player slot. To add a single player to a game session, use CreatePlayerSession .

To create player sessions, specify a game session ID, a list of player IDs, and optionally a set of player data strings. If successful, the players are added to the game session and a set of new PlayerSession objects is returned. Player sessions cannot be updated.

Available in Amazon GameLift Local.

Player-session-related operations include:

  • CreatePlayerSession
  • CreatePlayerSessions
  • DescribePlayerSessions
  • Game session placements
  • StartGameSessionPlacement
  • DescribeGameSessionPlacement
  • StopGameSessionPlacement

Synopsis

Creating a Request

createPlayerSessions Source #

Creates a value of CreatePlayerSessions with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

  • cpsPlayerDataMap - Map of string pairs, each specifying a player ID and a set of developer-defined information related to the player. Amazon GameLift does not use this data, so it can be formatted as needed for use in the game. Player data strings for player IDs not included in the PlayerIds parameter are ignored.
  • cpsGameSessionId - Unique identifier for the game session to add players to.
  • cpsPlayerIds - List of unique identifiers for the players to be added.

data CreatePlayerSessions Source #

Represents the input for a request action.

See: createPlayerSessions smart constructor.

Instances

Eq CreatePlayerSessions Source # 
Data CreatePlayerSessions Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> CreatePlayerSessions -> c CreatePlayerSessions #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c CreatePlayerSessions #

toConstr :: CreatePlayerSessions -> Constr #

dataTypeOf :: CreatePlayerSessions -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c CreatePlayerSessions) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c CreatePlayerSessions) #

gmapT :: (forall b. Data b => b -> b) -> CreatePlayerSessions -> CreatePlayerSessions #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> CreatePlayerSessions -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> CreatePlayerSessions -> r #

gmapQ :: (forall d. Data d => d -> u) -> CreatePlayerSessions -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> CreatePlayerSessions -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> CreatePlayerSessions -> m CreatePlayerSessions #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> CreatePlayerSessions -> m CreatePlayerSessions #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> CreatePlayerSessions -> m CreatePlayerSessions #

Read CreatePlayerSessions Source # 
Show CreatePlayerSessions Source # 
Generic CreatePlayerSessions Source # 
Hashable CreatePlayerSessions Source # 
ToJSON CreatePlayerSessions Source # 
NFData CreatePlayerSessions Source # 

Methods

rnf :: CreatePlayerSessions -> () #

AWSRequest CreatePlayerSessions Source # 
ToQuery CreatePlayerSessions Source # 
ToPath CreatePlayerSessions Source # 
ToHeaders CreatePlayerSessions Source # 
type Rep CreatePlayerSessions Source # 
type Rep CreatePlayerSessions = D1 (MetaData "CreatePlayerSessions" "Network.AWS.GameLift.CreatePlayerSessions" "amazonka-gamelift-1.5.0-LWFsf2alHztGD91U7ab8u0" False) (C1 (MetaCons "CreatePlayerSessions'" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "_cpsPlayerDataMap") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe (Map Text Text)))) ((:*:) (S1 (MetaSel (Just Symbol "_cpsGameSessionId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)) (S1 (MetaSel (Just Symbol "_cpsPlayerIds") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (List1 Text))))))
type Rs CreatePlayerSessions Source # 

Request Lenses

cpsPlayerDataMap :: Lens' CreatePlayerSessions (HashMap Text Text) Source #

Map of string pairs, each specifying a player ID and a set of developer-defined information related to the player. Amazon GameLift does not use this data, so it can be formatted as needed for use in the game. Player data strings for player IDs not included in the PlayerIds parameter are ignored.

cpsGameSessionId :: Lens' CreatePlayerSessions Text Source #

Unique identifier for the game session to add players to.

cpsPlayerIds :: Lens' CreatePlayerSessions (NonEmpty Text) Source #

List of unique identifiers for the players to be added.

Destructuring the Response

createPlayerSessionsResponse Source #

Creates a value of CreatePlayerSessionsResponse with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

data CreatePlayerSessionsResponse Source #

Represents the returned data in response to a request action.

See: createPlayerSessionsResponse smart constructor.

Instances

Eq CreatePlayerSessionsResponse Source # 
Data CreatePlayerSessionsResponse Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> CreatePlayerSessionsResponse -> c CreatePlayerSessionsResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c CreatePlayerSessionsResponse #

toConstr :: CreatePlayerSessionsResponse -> Constr #

dataTypeOf :: CreatePlayerSessionsResponse -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c CreatePlayerSessionsResponse) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c CreatePlayerSessionsResponse) #

gmapT :: (forall b. Data b => b -> b) -> CreatePlayerSessionsResponse -> CreatePlayerSessionsResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> CreatePlayerSessionsResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> CreatePlayerSessionsResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> CreatePlayerSessionsResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> CreatePlayerSessionsResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> CreatePlayerSessionsResponse -> m CreatePlayerSessionsResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> CreatePlayerSessionsResponse -> m CreatePlayerSessionsResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> CreatePlayerSessionsResponse -> m CreatePlayerSessionsResponse #

Read CreatePlayerSessionsResponse Source # 
Show CreatePlayerSessionsResponse Source # 
Generic CreatePlayerSessionsResponse Source # 
NFData CreatePlayerSessionsResponse Source # 
type Rep CreatePlayerSessionsResponse Source # 
type Rep CreatePlayerSessionsResponse = D1 (MetaData "CreatePlayerSessionsResponse" "Network.AWS.GameLift.CreatePlayerSessions" "amazonka-gamelift-1.5.0-LWFsf2alHztGD91U7ab8u0" False) (C1 (MetaCons "CreatePlayerSessionsResponse'" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "_crsPlayerSessions") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe [PlayerSession]))) (S1 (MetaSel (Just Symbol "_crsResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int))))

Response Lenses

crsPlayerSessions :: Lens' CreatePlayerSessionsResponse [PlayerSession] Source #

Collection of player session objects created for the added players.