getSchemaAsJson method

Future<GetSchemaAsJsonResponse> getSchemaAsJson({
  1. required String schemaArn,
})

Retrieves a JSON representation of the schema. See JSON Schema Format for more information.

May throw InternalServiceException. May throw InvalidArnException. May throw RetryableConflictException. May throw ValidationException. May throw LimitExceededException. May throw AccessDeniedException. May throw ResourceNotFoundException. May throw ValidationException.

Parameter schemaArn : The ARN of the schema to retrieve.

Implementation

Future<GetSchemaAsJsonResponse> getSchemaAsJson({
  required String schemaArn,
}) async {
  ArgumentError.checkNotNull(schemaArn, 'schemaArn');
  final headers = <String, String>{
    'x-amz-data-partition': schemaArn.toString(),
  };
  final response = await _protocol.send(
    payload: null,
    method: 'POST',
    requestUri: '/amazonclouddirectory/2017-01-11/schema/json',
    headers: headers,
    exceptionFnMap: _exceptionFns,
  );
  return GetSchemaAsJsonResponse.fromJson(response);
}