validateMatchmakingRuleSet method
Future<ValidateMatchmakingRuleSetOutput>
validateMatchmakingRuleSet({
- required String ruleSetBody,
Validates the syntax of a matchmaking rule or rule set. This operation checks that the rule set is using syntactically correct JSON and that it conforms to allowed property expressions. To validate syntax, provide a rule set JSON string.
Learn more
Related operations- CreateMatchmakingConfiguration
- DescribeMatchmakingConfigurations
- UpdateMatchmakingConfiguration
- DeleteMatchmakingConfiguration
- CreateMatchmakingRuleSet
- DescribeMatchmakingRuleSets
- ValidateMatchmakingRuleSet
- DeleteMatchmakingRuleSet
May throw InternalServiceException. May throw UnsupportedRegionException. May throw InvalidRequestException.
Parameter ruleSetBody
:
A collection of matchmaking rules to validate, formatted as a JSON string.
Implementation
Future<ValidateMatchmakingRuleSetOutput> validateMatchmakingRuleSet({
required String ruleSetBody,
}) async {
ArgumentError.checkNotNull(ruleSetBody, 'ruleSetBody');
_s.validateStringLength(
'ruleSetBody',
ruleSetBody,
1,
65535,
isRequired: true,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'GameLift.ValidateMatchmakingRuleSet'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'RuleSetBody': ruleSetBody,
},
);
return ValidateMatchmakingRuleSetOutput.fromJson(jsonResponse.body);
}