describeEvents method

Future<EventDescriptionsMessage> describeEvents({
  1. String? applicationName,
  2. DateTime? endTime,
  3. String? environmentId,
  4. String? environmentName,
  5. int? maxRecords,
  6. String? nextToken,
  7. String? platformArn,
  8. String? requestId,
  9. EventSeverity? severity,
  10. DateTime? startTime,
  11. String? templateName,
  12. String? versionLabel,
})

Returns list of event descriptions matching criteria up to the last 6 weeks.

Parameter applicationName : If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.

Parameter endTime : If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the EndTime.

Parameter environmentId : If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.

Parameter environmentName : If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.

Parameter maxRecords : Specifies the maximum number of events that can be returned, beginning with the most recent event.

Parameter nextToken : Pagination token. If specified, the events return the next batch of results.

Parameter platformArn : The ARN of a custom platform version. If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this custom platform version.

Parameter requestId : If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.

Parameter severity : If specified, limits the events returned from this call to include only those with the specified severity or higher.

Parameter startTime : If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.

Parameter templateName : If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.

Parameter versionLabel : If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.

Implementation

Future<EventDescriptionsMessage> describeEvents({
  String? applicationName,
  DateTime? endTime,
  String? environmentId,
  String? environmentName,
  int? maxRecords,
  String? nextToken,
  String? platformArn,
  String? requestId,
  EventSeverity? severity,
  DateTime? startTime,
  String? templateName,
  String? versionLabel,
}) async {
  _s.validateStringLength(
    'applicationName',
    applicationName,
    1,
    100,
  );
  _s.validateStringLength(
    'environmentName',
    environmentName,
    4,
    40,
  );
  _s.validateNumRange(
    'maxRecords',
    maxRecords,
    1,
    1000,
  );
  _s.validateStringLength(
    'templateName',
    templateName,
    1,
    100,
  );
  _s.validateStringLength(
    'versionLabel',
    versionLabel,
    1,
    100,
  );
  final $request = <String, dynamic>{};
  applicationName?.also((arg) => $request['ApplicationName'] = arg);
  endTime?.also((arg) => $request['EndTime'] = _s.iso8601ToJson(arg));
  environmentId?.also((arg) => $request['EnvironmentId'] = arg);
  environmentName?.also((arg) => $request['EnvironmentName'] = arg);
  maxRecords?.also((arg) => $request['MaxRecords'] = arg);
  nextToken?.also((arg) => $request['NextToken'] = arg);
  platformArn?.also((arg) => $request['PlatformArn'] = arg);
  requestId?.also((arg) => $request['RequestId'] = arg);
  severity?.also((arg) => $request['Severity'] = arg.toValue());
  startTime?.also((arg) => $request['StartTime'] = _s.iso8601ToJson(arg));
  templateName?.also((arg) => $request['TemplateName'] = arg);
  versionLabel?.also((arg) => $request['VersionLabel'] = arg);
  final $result = await _protocol.send(
    $request,
    action: 'DescribeEvents',
    version: '2010-12-01',
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    shape: shapes['DescribeEventsMessage'],
    shapes: shapes,
    resultWrapper: 'DescribeEventsResult',
  );
  return EventDescriptionsMessage.fromXml($result);
}