createModelManifest method

Future<CreateModelManifestResponse> createModelManifest({
  1. required String name,
  2. required List<String> nodes,
  3. required String signalCatalogArn,
  4. String? description,
  5. List<Tag>? tags,
})

Creates a vehicle model (model manifest) that specifies signals (attributes, branches, sensors, and actuators).

For more information, see Vehicle models in the Amazon Web Services IoT FleetWise Developer Guide.

May throw AccessDeniedException. May throw ConflictException. May throw InvalidSignalsException. May throw LimitExceededException. May throw ResourceNotFoundException. May throw ThrottlingException. May throw ValidationException.

Parameter name : The name of the vehicle model to create.

Parameter nodes : A list of nodes, which are a general abstraction of signals.

Parameter signalCatalogArn : The Amazon Resource Name (ARN) of a signal catalog.

Parameter description : A brief description of the vehicle model.

Parameter tags : Metadata that can be used to manage the vehicle model.

Implementation

Future<CreateModelManifestResponse> createModelManifest({
  required String name,
  required List<String> nodes,
  required String signalCatalogArn,
  String? description,
  List<Tag>? tags,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.0',
    'X-Amz-Target': 'IoTAutobahnControlPlane.CreateModelManifest'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'name': name,
      'nodes': nodes,
      'signalCatalogArn': signalCatalogArn,
      if (description != null) 'description': description,
      if (tags != null) 'tags': tags,
    },
  );

  return CreateModelManifestResponse.fromJson(jsonResponse.body);
}