getRoomSkillParameter method

Future<GetRoomSkillParameterResponse> getRoomSkillParameter({
  1. required String parameterKey,
  2. required String skillId,
  3. String? roomArn,
})

Gets room skill parameter details by room, skill, and parameter key ARN.

May throw NotFoundException.

Parameter parameterKey : The room skill parameter key for which to get details. Required.

Parameter skillId : The ARN of the skill from which to get the room skill parameter details. Required.

Parameter roomArn : The ARN of the room from which to get the room skill parameter details.

Implementation

Future<GetRoomSkillParameterResponse> getRoomSkillParameter({
  required String parameterKey,
  required String skillId,
  String? roomArn,
}) async {
  ArgumentError.checkNotNull(parameterKey, 'parameterKey');
  _s.validateStringLength(
    'parameterKey',
    parameterKey,
    1,
    256,
    isRequired: true,
  );
  ArgumentError.checkNotNull(skillId, 'skillId');
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AlexaForBusiness.GetRoomSkillParameter'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'ParameterKey': parameterKey,
      'SkillId': skillId,
      if (roomArn != null) 'RoomArn': roomArn,
    },
  );

  return GetRoomSkillParameterResponse.fromJson(jsonResponse.body);
}