createDatasetContent method
Creates the content of a data set by applying a queryAction
(a SQL query) or a containerAction
(executing a containerized
application).
May throw InvalidRequestException. May throw ResourceNotFoundException. May throw InternalFailureException. May throw ServiceUnavailableException. May throw ThrottlingException.
Parameter datasetName
:
The name of the dataset.
Parameter versionId
:
The version ID of the dataset content. To specify versionId
for a dataset content, the dataset must use a DeltaTimer
filter.
Implementation
Future<CreateDatasetContentResponse> createDatasetContent({
required String datasetName,
String? versionId,
}) async {
ArgumentError.checkNotNull(datasetName, 'datasetName');
_s.validateStringLength(
'datasetName',
datasetName,
1,
128,
isRequired: true,
);
_s.validateStringLength(
'versionId',
versionId,
7,
36,
);
final $payload = <String, dynamic>{
if (versionId != null) 'versionId': versionId,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/datasets/${Uri.encodeComponent(datasetName)}/content',
exceptionFnMap: _exceptionFns,
);
return CreateDatasetContentResponse.fromJson(response);
}