UpdateDestination unicodeCpp Example
#include <CkRestW.h>
#include <CkAuthAwsW.h>
#include <CkJsonObjectW.h>
#include <CkStringBuilderW.h>
void ChilkatSample(void)
{
// This example requires the Chilkat API to have been previously unlocked.
// See Global Unlock Sample for sample code.
CkRestW rest;
bool success;
CkAuthAwsW authAws;
authAws.put_AccessKey(L"AWS_ACCESS_KEY");
authAws.put_SecretKey(L"AWS_SECRET_KEY");
// Don't forget to change the region to your particular region. (Also make the same change in the call to Connect below.)
authAws.put_Region(L"us-west-2");
authAws.put_ServiceName(L"firehose");
// SetAuthAws causes Chilkat to automatically add the following headers: Authorization, X-Amz-Date
rest.SetAuthAws(authAws);
// URL: https://firehose.us-west-2.amazonaws.com/
// Use the same region as specified above.
success = rest.Connect(L"firehose.us-west-2.amazonaws.com",443,true,true);
if (success != true) {
wprintf(L"ConnectFailReason: %d\n",rest.get_ConnectFailReason());
wprintf(L"%s\n",rest.lastErrorText());
return;
}
// The following code creates the JSON request body.
// The JSON created by this code is shown below.
// Use this online tool to generate code from sample JSON:
// Generate Code to Create JSON
CkJsonObjectW json;
json.UpdateInt(L"AmazonopensearchserviceDestinationUpdate.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"AmazonopensearchserviceDestinationUpdate.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"AmazonopensearchserviceDestinationUpdate.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.ClusterEndpoint",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.DomainARN",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.IndexName",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.IndexRotationPeriod",L"string");
json.UpdateInt(L"AmazonopensearchserviceDestinationUpdate.ProcessingConfiguration.Enabled",123);
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterName",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterValue",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.ProcessingConfiguration.Processors[0].Type",L"string");
json.UpdateInt(L"AmazonopensearchserviceDestinationUpdate.RetryOptions.DurationInSeconds",123);
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.RoleARN",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.S3Update.BucketARN",L"string");
json.UpdateInt(L"AmazonopensearchserviceDestinationUpdate.S3Update.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"AmazonopensearchserviceDestinationUpdate.S3Update.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"AmazonopensearchserviceDestinationUpdate.S3Update.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.S3Update.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.S3Update.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.S3Update.CompressionFormat",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.S3Update.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.S3Update.EncryptionConfiguration.NoEncryptionConfig",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.S3Update.ErrorOutputPrefix",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.S3Update.Prefix",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.S3Update.RoleARN",L"string");
json.UpdateString(L"AmazonopensearchserviceDestinationUpdate.TypeName",L"string");
json.UpdateString(L"CurrentDeliveryStreamVersionId",L"string");
json.UpdateString(L"DeliveryStreamName",L"string");
json.UpdateString(L"DestinationId",L"string");
json.UpdateInt(L"ElasticsearchDestinationUpdate.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"ElasticsearchDestinationUpdate.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"ElasticsearchDestinationUpdate.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"ElasticsearchDestinationUpdate.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.ClusterEndpoint",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.DomainARN",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.IndexName",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.IndexRotationPeriod",L"string");
json.UpdateInt(L"ElasticsearchDestinationUpdate.ProcessingConfiguration.Enabled",123);
json.UpdateString(L"ElasticsearchDestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterName",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterValue",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.ProcessingConfiguration.Processors[0].Type",L"string");
json.UpdateInt(L"ElasticsearchDestinationUpdate.RetryOptions.DurationInSeconds",123);
json.UpdateString(L"ElasticsearchDestinationUpdate.RoleARN",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.S3Update.BucketARN",L"string");
json.UpdateInt(L"ElasticsearchDestinationUpdate.S3Update.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"ElasticsearchDestinationUpdate.S3Update.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"ElasticsearchDestinationUpdate.S3Update.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"ElasticsearchDestinationUpdate.S3Update.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.S3Update.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.S3Update.CompressionFormat",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.S3Update.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.S3Update.EncryptionConfiguration.NoEncryptionConfig",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.S3Update.ErrorOutputPrefix",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.S3Update.Prefix",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.S3Update.RoleARN",L"string");
json.UpdateString(L"ElasticsearchDestinationUpdate.TypeName",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.BucketARN",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.CompressionFormat",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.Enabled",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.InputFormatConfiguration.Deserializer.HiveJsonSerDe.TimestampFormats[0]",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.InputFormatConfiguration.Deserializer.OpenXJsonSerDe.CaseInsensitive",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.InputFormatConfiguration.Deserializer.OpenXJsonSerDe.ColumnToJsonKeyMappings.string",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.InputFormatConfiguration.Deserializer.OpenXJsonSerDe.ConvertDotsInJsonKeysToUnderscores",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.OrcSerDe.BlockSizeBytes",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.OrcSerDe.BloomFilterColumns[0]",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.OrcSerDe.BloomFilterFalsePositiveProbability",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.OrcSerDe.Compression",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.OrcSerDe.DictionaryKeyThreshold",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.OrcSerDe.EnablePadding",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.OrcSerDe.FormatVersion",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.OrcSerDe.PaddingTolerance",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.OrcSerDe.RowIndexStride",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.OrcSerDe.StripeSizeBytes",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.ParquetSerDe.BlockSizeBytes",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.ParquetSerDe.Compression",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.ParquetSerDe.EnableDictionaryCompression",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.ParquetSerDe.MaxPaddingBytes",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.ParquetSerDe.PageSizeBytes",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.OutputFormatConfiguration.Serializer.ParquetSerDe.WriterVersion",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.SchemaConfiguration.CatalogId",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.SchemaConfiguration.DatabaseName",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.SchemaConfiguration.Region",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.SchemaConfiguration.RoleARN",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.SchemaConfiguration.TableName",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.DataFormatConversionConfiguration.SchemaConfiguration.VersionId",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.DynamicPartitioningConfiguration.Enabled",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.DynamicPartitioningConfiguration.RetryOptions.DurationInSeconds",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.EncryptionConfiguration.NoEncryptionConfig",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.ErrorOutputPrefix",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.Prefix",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.ProcessingConfiguration.Enabled",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterName",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterValue",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.ProcessingConfiguration.Processors[0].Type",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.RoleARN",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.S3BackupMode",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.S3BackupUpdate.BucketARN",L"string");
json.UpdateInt(L"ExtendedS3DestinationUpdate.S3BackupUpdate.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.S3BackupUpdate.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"ExtendedS3DestinationUpdate.S3BackupUpdate.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"ExtendedS3DestinationUpdate.S3BackupUpdate.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.S3BackupUpdate.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.S3BackupUpdate.CompressionFormat",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.S3BackupUpdate.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.S3BackupUpdate.EncryptionConfiguration.NoEncryptionConfig",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.S3BackupUpdate.ErrorOutputPrefix",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.S3BackupUpdate.Prefix",L"string");
json.UpdateString(L"ExtendedS3DestinationUpdate.S3BackupUpdate.RoleARN",L"string");
json.UpdateInt(L"HttpEndpointDestinationUpdate.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"HttpEndpointDestinationUpdate.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"HttpEndpointDestinationUpdate.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"HttpEndpointDestinationUpdate.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.EndpointConfiguration.AccessKey",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.EndpointConfiguration.Name",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.EndpointConfiguration.Url",L"string");
json.UpdateInt(L"HttpEndpointDestinationUpdate.ProcessingConfiguration.Enabled",123);
json.UpdateString(L"HttpEndpointDestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterName",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterValue",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.ProcessingConfiguration.Processors[0].Type",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.RequestConfiguration.CommonAttributes[0].AttributeName",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.RequestConfiguration.CommonAttributes[0].AttributeValue",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.RequestConfiguration.ContentEncoding",L"string");
json.UpdateInt(L"HttpEndpointDestinationUpdate.RetryOptions.DurationInSeconds",123);
json.UpdateString(L"HttpEndpointDestinationUpdate.RoleARN",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.S3BackupMode",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.S3Update.BucketARN",L"string");
json.UpdateInt(L"HttpEndpointDestinationUpdate.S3Update.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"HttpEndpointDestinationUpdate.S3Update.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"HttpEndpointDestinationUpdate.S3Update.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"HttpEndpointDestinationUpdate.S3Update.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.S3Update.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.S3Update.CompressionFormat",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.S3Update.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.S3Update.EncryptionConfiguration.NoEncryptionConfig",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.S3Update.ErrorOutputPrefix",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.S3Update.Prefix",L"string");
json.UpdateString(L"HttpEndpointDestinationUpdate.S3Update.RoleARN",L"string");
json.UpdateInt(L"RedshiftDestinationUpdate.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"RedshiftDestinationUpdate.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.ClusterJDBCURL",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.CopyCommand.CopyOptions",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.CopyCommand.DataTableColumns",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.CopyCommand.DataTableName",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.Password",L"string");
json.UpdateInt(L"RedshiftDestinationUpdate.ProcessingConfiguration.Enabled",123);
json.UpdateString(L"RedshiftDestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterName",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterValue",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.ProcessingConfiguration.Processors[0].Type",L"string");
json.UpdateInt(L"RedshiftDestinationUpdate.RetryOptions.DurationInSeconds",123);
json.UpdateString(L"RedshiftDestinationUpdate.RoleARN",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3BackupMode",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3BackupUpdate.BucketARN",L"string");
json.UpdateInt(L"RedshiftDestinationUpdate.S3BackupUpdate.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"RedshiftDestinationUpdate.S3BackupUpdate.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"RedshiftDestinationUpdate.S3BackupUpdate.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"RedshiftDestinationUpdate.S3BackupUpdate.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3BackupUpdate.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3BackupUpdate.CompressionFormat",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3BackupUpdate.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3BackupUpdate.EncryptionConfiguration.NoEncryptionConfig",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3BackupUpdate.ErrorOutputPrefix",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3BackupUpdate.Prefix",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3BackupUpdate.RoleARN",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3Update.BucketARN",L"string");
json.UpdateInt(L"RedshiftDestinationUpdate.S3Update.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"RedshiftDestinationUpdate.S3Update.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"RedshiftDestinationUpdate.S3Update.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"RedshiftDestinationUpdate.S3Update.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3Update.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3Update.CompressionFormat",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3Update.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3Update.EncryptionConfiguration.NoEncryptionConfig",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3Update.ErrorOutputPrefix",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3Update.Prefix",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.S3Update.RoleARN",L"string");
json.UpdateString(L"RedshiftDestinationUpdate.Username",L"string");
json.UpdateString(L"S3DestinationUpdate.BucketARN",L"string");
json.UpdateInt(L"S3DestinationUpdate.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"S3DestinationUpdate.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"S3DestinationUpdate.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"S3DestinationUpdate.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"S3DestinationUpdate.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"S3DestinationUpdate.CompressionFormat",L"string");
json.UpdateString(L"S3DestinationUpdate.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN",L"string");
json.UpdateString(L"S3DestinationUpdate.EncryptionConfiguration.NoEncryptionConfig",L"string");
json.UpdateString(L"S3DestinationUpdate.ErrorOutputPrefix",L"string");
json.UpdateString(L"S3DestinationUpdate.Prefix",L"string");
json.UpdateString(L"S3DestinationUpdate.RoleARN",L"string");
json.UpdateInt(L"SplunkDestinationUpdate.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"SplunkDestinationUpdate.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"SplunkDestinationUpdate.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateInt(L"SplunkDestinationUpdate.HECAcknowledgmentTimeoutInSeconds",123);
json.UpdateString(L"SplunkDestinationUpdate.HECEndpoint",L"string");
json.UpdateString(L"SplunkDestinationUpdate.HECEndpointType",L"string");
json.UpdateString(L"SplunkDestinationUpdate.HECToken",L"string");
json.UpdateInt(L"SplunkDestinationUpdate.ProcessingConfiguration.Enabled",123);
json.UpdateString(L"SplunkDestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterName",L"string");
json.UpdateString(L"SplunkDestinationUpdate.ProcessingConfiguration.Processors[0].Parameters[0].ParameterValue",L"string");
json.UpdateString(L"SplunkDestinationUpdate.ProcessingConfiguration.Processors[0].Type",L"string");
json.UpdateInt(L"SplunkDestinationUpdate.RetryOptions.DurationInSeconds",123);
json.UpdateString(L"SplunkDestinationUpdate.S3BackupMode",L"string");
json.UpdateString(L"SplunkDestinationUpdate.S3Update.BucketARN",L"string");
json.UpdateInt(L"SplunkDestinationUpdate.S3Update.BufferingHints.IntervalInSeconds",123);
json.UpdateInt(L"SplunkDestinationUpdate.S3Update.BufferingHints.SizeInMBs",123);
json.UpdateInt(L"SplunkDestinationUpdate.S3Update.CloudWatchLoggingOptions.Enabled",123);
json.UpdateString(L"SplunkDestinationUpdate.S3Update.CloudWatchLoggingOptions.LogGroupName",L"string");
json.UpdateString(L"SplunkDestinationUpdate.S3Update.CloudWatchLoggingOptions.LogStreamName",L"string");
json.UpdateString(L"SplunkDestinationUpdate.S3Update.CompressionFormat",L"string");
json.UpdateString(L"SplunkDestinationUpdate.S3Update.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN",L"string");
json.UpdateString(L"SplunkDestinationUpdate.S3Update.EncryptionConfiguration.NoEncryptionConfig",L"string");
json.UpdateString(L"SplunkDestinationUpdate.S3Update.ErrorOutputPrefix",L"string");
json.UpdateString(L"SplunkDestinationUpdate.S3Update.Prefix",L"string");
json.UpdateString(L"SplunkDestinationUpdate.S3Update.RoleARN",L"string");
// The JSON request body created by the above code:
// {
// "AmazonopensearchserviceDestinationUpdate": {
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "ClusterEndpoint": "string",
// "DomainARN": "string",
// "IndexName": "string",
// "IndexRotationPeriod": "string",
// "ProcessingConfiguration": {
// "Enabled": boolean,
// "Processors": [
// {
// "Parameters": [
// {
// "ParameterName": "string",
// "ParameterValue": "string"
// }
// ],
// "Type": "string"
// }
// ]
// },
// "RetryOptions": {
// "DurationInSeconds": number
// },
// "RoleARN": "string",
// "S3Update": {
// "BucketARN": "string",
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "CompressionFormat": "string",
// "EncryptionConfiguration": {
// "KMSEncryptionConfig": {
// "AWSKMSKeyARN": "string"
// },
// "NoEncryptionConfig": "string"
// },
// "ErrorOutputPrefix": "string",
// "Prefix": "string",
// "RoleARN": "string"
// },
// "TypeName": "string"
// },
// "CurrentDeliveryStreamVersionId": "string",
// "DeliveryStreamName": "string",
// "DestinationId": "string",
// "ElasticsearchDestinationUpdate": {
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "ClusterEndpoint": "string",
// "DomainARN": "string",
// "IndexName": "string",
// "IndexRotationPeriod": "string",
// "ProcessingConfiguration": {
// "Enabled": boolean,
// "Processors": [
// {
// "Parameters": [
// {
// "ParameterName": "string",
// "ParameterValue": "string"
// }
// ],
// "Type": "string"
// }
// ]
// },
// "RetryOptions": {
// "DurationInSeconds": number
// },
// "RoleARN": "string",
// "S3Update": {
// "BucketARN": "string",
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "CompressionFormat": "string",
// "EncryptionConfiguration": {
// "KMSEncryptionConfig": {
// "AWSKMSKeyARN": "string"
// },
// "NoEncryptionConfig": "string"
// },
// "ErrorOutputPrefix": "string",
// "Prefix": "string",
// "RoleARN": "string"
// },
// "TypeName": "string"
// },
// "ExtendedS3DestinationUpdate": {
// "BucketARN": "string",
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "CompressionFormat": "string",
// "DataFormatConversionConfiguration": {
// "Enabled": boolean,
// "InputFormatConfiguration": {
// "Deserializer": {
// "HiveJsonSerDe": {
// "TimestampFormats": [
// "string"
// ]
// },
// "OpenXJsonSerDe": {
// "CaseInsensitive": boolean,
// "ColumnToJsonKeyMappings": {
// "string": "string"
// },
// "ConvertDotsInJsonKeysToUnderscores": boolean
// }
// }
// },
// "OutputFormatConfiguration": {
// "Serializer": {
// "OrcSerDe": {
// "BlockSizeBytes": number,
// "BloomFilterColumns": [
// "string"
// ],
// "BloomFilterFalsePositiveProbability": number,
// "Compression": "string",
// "DictionaryKeyThreshold": number,
// "EnablePadding": boolean,
// "FormatVersion": "string",
// "PaddingTolerance": number,
// "RowIndexStride": number,
// "StripeSizeBytes": number
// },
// "ParquetSerDe": {
// "BlockSizeBytes": number,
// "Compression": "string",
// "EnableDictionaryCompression": boolean,
// "MaxPaddingBytes": number,
// "PageSizeBytes": number,
// "WriterVersion": "string"
// }
// }
// },
// "SchemaConfiguration": {
// "CatalogId": "string",
// "DatabaseName": "string",
// "Region": "string",
// "RoleARN": "string",
// "TableName": "string",
// "VersionId": "string"
// }
// },
// "DynamicPartitioningConfiguration": {
// "Enabled": boolean,
// "RetryOptions": {
// "DurationInSeconds": number
// }
// },
// "EncryptionConfiguration": {
// "KMSEncryptionConfig": {
// "AWSKMSKeyARN": "string"
// },
// "NoEncryptionConfig": "string"
// },
// "ErrorOutputPrefix": "string",
// "Prefix": "string",
// "ProcessingConfiguration": {
// "Enabled": boolean,
// "Processors": [
// {
// "Parameters": [
// {
// "ParameterName": "string",
// "ParameterValue": "string"
// }
// ],
// "Type": "string"
// }
// ]
// },
// "RoleARN": "string",
// "S3BackupMode": "string",
// "S3BackupUpdate": {
// "BucketARN": "string",
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "CompressionFormat": "string",
// "EncryptionConfiguration": {
// "KMSEncryptionConfig": {
// "AWSKMSKeyARN": "string"
// },
// "NoEncryptionConfig": "string"
// },
// "ErrorOutputPrefix": "string",
// "Prefix": "string",
// "RoleARN": "string"
// }
// },
// "HttpEndpointDestinationUpdate": {
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "EndpointConfiguration": {
// "AccessKey": "string",
// "Name": "string",
// "Url": "string"
// },
// "ProcessingConfiguration": {
// "Enabled": boolean,
// "Processors": [
// {
// "Parameters": [
// {
// "ParameterName": "string",
// "ParameterValue": "string"
// }
// ],
// "Type": "string"
// }
// ]
// },
// "RequestConfiguration": {
// "CommonAttributes": [
// {
// "AttributeName": "string",
// "AttributeValue": "string"
// }
// ],
// "ContentEncoding": "string"
// },
// "RetryOptions": {
// "DurationInSeconds": number
// },
// "RoleARN": "string",
// "S3BackupMode": "string",
// "S3Update": {
// "BucketARN": "string",
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "CompressionFormat": "string",
// "EncryptionConfiguration": {
// "KMSEncryptionConfig": {
// "AWSKMSKeyARN": "string"
// },
// "NoEncryptionConfig": "string"
// },
// "ErrorOutputPrefix": "string",
// "Prefix": "string",
// "RoleARN": "string"
// }
// },
// "RedshiftDestinationUpdate": {
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "ClusterJDBCURL": "string",
// "CopyCommand": {
// "CopyOptions": "string",
// "DataTableColumns": "string",
// "DataTableName": "string"
// },
// "Password": "string",
// "ProcessingConfiguration": {
// "Enabled": boolean,
// "Processors": [
// {
// "Parameters": [
// {
// "ParameterName": "string",
// "ParameterValue": "string"
// }
// ],
// "Type": "string"
// }
// ]
// },
// "RetryOptions": {
// "DurationInSeconds": number
// },
// "RoleARN": "string",
// "S3BackupMode": "string",
// "S3BackupUpdate": {
// "BucketARN": "string",
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "CompressionFormat": "string",
// "EncryptionConfiguration": {
// "KMSEncryptionConfig": {
// "AWSKMSKeyARN": "string"
// },
// "NoEncryptionConfig": "string"
// },
// "ErrorOutputPrefix": "string",
// "Prefix": "string",
// "RoleARN": "string"
// },
// "S3Update": {
// "BucketARN": "string",
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "CompressionFormat": "string",
// "EncryptionConfiguration": {
// "KMSEncryptionConfig": {
// "AWSKMSKeyARN": "string"
// },
// "NoEncryptionConfig": "string"
// },
// "ErrorOutputPrefix": "string",
// "Prefix": "string",
// "RoleARN": "string"
// },
// "Username": "string"
// },
// "S3DestinationUpdate": {
// "BucketARN": "string",
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "CompressionFormat": "string",
// "EncryptionConfiguration": {
// "KMSEncryptionConfig": {
// "AWSKMSKeyARN": "string"
// },
// "NoEncryptionConfig": "string"
// },
// "ErrorOutputPrefix": "string",
// "Prefix": "string",
// "RoleARN": "string"
// },
// "SplunkDestinationUpdate": {
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "HECAcknowledgmentTimeoutInSeconds": number,
// "HECEndpoint": "string",
// "HECEndpointType": "string",
// "HECToken": "string",
// "ProcessingConfiguration": {
// "Enabled": boolean,
// "Processors": [
// {
// "Parameters": [
// {
// "ParameterName": "string",
// "ParameterValue": "string"
// }
// ],
// "Type": "string"
// }
// ]
// },
// "RetryOptions": {
// "DurationInSeconds": number
// },
// "S3BackupMode": "string",
// "S3Update": {
// "BucketARN": "string",
// "BufferingHints": {
// "IntervalInSeconds": number,
// "SizeInMBs": number
// },
// "CloudWatchLoggingOptions": {
// "Enabled": boolean,
// "LogGroupName": "string",
// "LogStreamName": "string"
// },
// "CompressionFormat": "string",
// "EncryptionConfiguration": {
// "KMSEncryptionConfig": {
// "AWSKMSKeyARN": "string"
// },
// "NoEncryptionConfig": "string"
// },
// "ErrorOutputPrefix": "string",
// "Prefix": "string",
// "RoleARN": "string"
// }
// }
// }
rest.AddHeader(L"Content-Type",L"application/x-amz-json-1.1");
rest.AddHeader(L"X-Amz-Target",L"Firehose_20150804.UpdateDestination");
CkStringBuilderW sbRequestBody;
json.EmitSb(sbRequestBody);
CkStringBuilderW sbResponseBody;
success = rest.FullRequestSb(L"POST",L"/",sbRequestBody,sbResponseBody);
if (success != true) {
wprintf(L"%s\n",rest.lastErrorText());
return;
}
int respStatusCode = rest.get_ResponseStatusCode();
wprintf(L"response status code = %d\n",respStatusCode);
if (respStatusCode != 200) {
wprintf(L"Response Header:\n");
wprintf(L"%s\n",rest.responseHeader());
wprintf(L"Response Body:\n");
wprintf(L"%s\n",sbResponseBody.getAsString());
return;
}
// If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body.
}