describe_player_sessions
async
¶
describe_player_sessions(
*,
config_overrides: Optional[AsyncGameLiftClientConfig] = None,
game_session_id: Optional[ArnStringModel] = None,
player_id: Optional[PlayerId] = None,
player_session_id: Optional[PlayerSessionId] = None,
player_session_status_filter: Optional[NonZeroAndMaxString] = None,
limit: Optional[PositiveInteger] = None,
next_token: Optional[NonZeroAndMaxString] = None,
) -> DescribePlayerSessionsOutput
This API works with the following fleet types: EC2, Anywhere, Container
Retrieves properties for one or more player sessions.
This action can be used in the following ways:
-
To retrieve a specific player session, provide the player session ID only.
-
To retrieve all player sessions in a game session, provide the game session ID only.
-
To retrieve all player sessions for a specific player, provide a player ID only.
To request player sessions, specify either a player session ID, game session ID, or player ID. You can filter this request by player session status. If you provide a specific PlayerSessionId or PlayerId, Amazon GameLift Servers ignores the filter criteria. Use the pagination parameters to retrieve results as a set of sequential pages.
If successful, a PlayerSession object is returned for each session that matches the request.
Related actions
Parameters:
-
game_session_id(Optional[ArnStringModel], default:None) –An identifier for the game session that is unique across all regions to retrieve player sessions for. The value is always a full ARN in the following format: For Home Region game session -
arn:aws:gamelift:. For Remote Location game session -::gamesession/ / arn:aws:gamelift:.::gamesession/ / / -
player_id(Optional[PlayerId], default:None) –A unique identifier for a player to retrieve player sessions for.
-
player_session_id(Optional[PlayerSessionId], default:None) –A unique identifier for a player session to retrieve.
-
player_session_status_filter(Optional[NonZeroAndMaxString], default:None) –Player session status to filter results on. Note that when a PlayerSessionId or PlayerId is provided in a DescribePlayerSessions request, then the PlayerSessionStatusFilter has no effect on the response.
Possible player session statuses include the following:
-
RESERVED -- The player session request has been received, but the player has not yet connected to the server process and/or been validated.
-
ACTIVE -- The player has been validated by the server process and is currently connected.
-
COMPLETED -- The player connection has been dropped.
-
TIMEDOUT -- A player session request was received, but the player did not connect and/or was not validated within the timeout limit (60 seconds).
-
-
limit(Optional[PositiveInteger], default:None) –The maximum number of results to return. Use this parameter with
NextTokento get results as a set of sequential pages. If a player session ID is specified, this parameter is ignored. -
next_token(Optional[NonZeroAndMaxString], default:None) –A token that indicates the start of the next sequential page of results. Use the token that is returned with a previous call to this operation. To start at the beginning of the result set, do not specify a value. If a player session ID is specified, this parameter is ignored.
Raises:
-
InternalServiceException–The service encountered an unrecoverable internal failure while processing the request. Clients can retry such requests immediately or after a waiting period.
-
InvalidRequestException–One or more parameter values in the request are invalid. Correct the invalid parameter values before retrying.
-
NotFoundException–The requested resource was not found. The resource was either not created yet or deleted.
-
UnauthorizedException–The client failed authentication. Clients should not retry such requests.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_gamelift/_services/async_game_lift.py
5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 | |