setSessionState method
Future<DynamiteResponse<RoomSetSessionStateResponseApplicationJson, void> >
setSessionState({
- required RoomSetSessionStateState state,
- required String token,
- RoomSetSessionStateApiVersion? apiVersion,
- bool? oCSAPIRequest,
Set active state for a session.
Returns a Future containing a DynamiteResponse
with the status code, deserialized body and headers.
Throws a DynamiteApiException
if the API call does not return an expected status code.
Parameters:
state
of the room.apiVersion
Defaults tov4
.token
oCSAPIRequest
Required to be true for the API request to pass. Defaults totrue
.
Status codes:
- 200: Session state set successfully
- 400: The provided new state was invalid
- 404: The participant did not have a session
See:
- setSessionStateRaw for an experimental operation that returns a
DynamiteRawResponse
that can be serialized.
Implementation
Future<_i1.DynamiteResponse<RoomSetSessionStateResponseApplicationJson, void>> setSessionState({
required RoomSetSessionStateState state,
required String token,
RoomSetSessionStateApiVersion? apiVersion,
bool? oCSAPIRequest,
}) async {
final rawResponse = setSessionStateRaw(
state: state,
token: token,
apiVersion: apiVersion,
oCSAPIRequest: oCSAPIRequest,
);
return rawResponse.future;
}