/*
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License").
* You may not use this file except in compliance with the License.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file is distributed
* on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
* express or implied. See the License for the specific language governing
* permissions and limitations under the License.
*/
/*
* Do not modify this file. This file is generated from the cognito-sync-2014-06-30.normal.json service model.
*/
using System;
using System.Collections.Generic;
using System.Net;
using Amazon.CognitoSync.Model;
using Amazon.CognitoSync.Model.Internal.MarshallTransformations;
using Amazon.CognitoSync.Internal;
using Amazon.Runtime;
using Amazon.Runtime.Internal;
using Amazon.Runtime.Internal.Auth;
using Amazon.Runtime.Internal.Transform;
namespace Amazon.CognitoSync
{
///
/// Implementation for accessing CognitoSync
///
/// Amazon Cognito Sync
///
/// Amazon Cognito Sync provides an AWS service and client library that enable cross-device
/// syncing of application-related user data. High-level client libraries are available
/// for both iOS and Android. You can use these libraries to persist data locally so that
/// it's available even if the device is offline. Developer credentials don't need to
/// be stored on the mobile device to access the service. You can use Amazon Cognito to
/// obtain a normalized user ID and credentials. User data is persisted in a dataset that
/// can store up to 1 MB of key-value pairs, and you can have up to 20 datasets per user
/// identity.
///
///
///
/// With Amazon Cognito Sync, the data stored for each identity is accessible only to
/// credentials assigned to that identity. In order to use the Cognito Sync service, you
/// need to make API calls using credentials retrieved with Amazon
/// Cognito Identity service.
///
///
///
/// If you want to use Cognito Sync in an Android or iOS application, you will probably
/// want to make API calls via the AWS Mobile SDK. To learn more, see the Developer
/// Guide for Android and the Developer
/// Guide for iOS.
///
///
public partial class AmazonCognitoSyncClient : AmazonServiceClient, IAmazonCognitoSync
{
private static IServiceMetadata serviceMetadata = new AmazonCognitoSyncMetadata();
#region Constructors
///
/// Constructs AmazonCognitoSyncClient with the credentials loaded from the application's
/// default configuration, and if unsuccessful from the Instance Profile service on an EC2 instance.
///
/// Example App.config with credentials set.
///
/// <?xml version="1.0" encoding="utf-8" ?>
/// <configuration>
/// <appSettings>
/// <add key="AWSProfileName" value="AWS Default"/>
/// </appSettings>
/// </configuration>
///
///
///
public AmazonCognitoSyncClient()
: base(FallbackCredentialsFactory.GetCredentials(), new AmazonCognitoSyncConfig()) { }
///
/// Constructs AmazonCognitoSyncClient with the credentials loaded from the application's
/// default configuration, and if unsuccessful from the Instance Profile service on an EC2 instance.
///
/// Example App.config with credentials set.
///
/// <?xml version="1.0" encoding="utf-8" ?>
/// <configuration>
/// <appSettings>
/// <add key="AWSProfileName" value="AWS Default"/>
/// </appSettings>
/// </configuration>
///
///
///
/// The region to connect.
public AmazonCognitoSyncClient(RegionEndpoint region)
: base(FallbackCredentialsFactory.GetCredentials(), new AmazonCognitoSyncConfig{RegionEndpoint = region}) { }
///
/// Constructs AmazonCognitoSyncClient with the credentials loaded from the application's
/// default configuration, and if unsuccessful from the Instance Profile service on an EC2 instance.
///
/// Example App.config with credentials set.
///
/// <?xml version="1.0" encoding="utf-8" ?>
/// <configuration>
/// <appSettings>
/// <add key="AWSProfileName" value="AWS Default"/>
/// </appSettings>
/// </configuration>
///
///
///
/// The AmazonCognitoSyncClient Configuration Object
public AmazonCognitoSyncClient(AmazonCognitoSyncConfig config)
: base(FallbackCredentialsFactory.GetCredentials(config), config){}
///
/// Constructs AmazonCognitoSyncClient with AWS Credentials
///
/// AWS Credentials
public AmazonCognitoSyncClient(AWSCredentials credentials)
: this(credentials, new AmazonCognitoSyncConfig())
{
}
///
/// Constructs AmazonCognitoSyncClient with AWS Credentials
///
/// AWS Credentials
/// The region to connect.
public AmazonCognitoSyncClient(AWSCredentials credentials, RegionEndpoint region)
: this(credentials, new AmazonCognitoSyncConfig{RegionEndpoint = region})
{
}
///
/// Constructs AmazonCognitoSyncClient with AWS Credentials and an
/// AmazonCognitoSyncClient Configuration object.
///
/// AWS Credentials
/// The AmazonCognitoSyncClient Configuration Object
public AmazonCognitoSyncClient(AWSCredentials credentials, AmazonCognitoSyncConfig clientConfig)
: base(credentials, clientConfig)
{
}
///
/// Constructs AmazonCognitoSyncClient with AWS Access Key ID and AWS Secret Key
///
/// AWS Access Key ID
/// AWS Secret Access Key
public AmazonCognitoSyncClient(string awsAccessKeyId, string awsSecretAccessKey)
: this(awsAccessKeyId, awsSecretAccessKey, new AmazonCognitoSyncConfig())
{
}
///
/// Constructs AmazonCognitoSyncClient with AWS Access Key ID and AWS Secret Key
///
/// AWS Access Key ID
/// AWS Secret Access Key
/// The region to connect.
public AmazonCognitoSyncClient(string awsAccessKeyId, string awsSecretAccessKey, RegionEndpoint region)
: this(awsAccessKeyId, awsSecretAccessKey, new AmazonCognitoSyncConfig() {RegionEndpoint=region})
{
}
///
/// Constructs AmazonCognitoSyncClient with AWS Access Key ID, AWS Secret Key and an
/// AmazonCognitoSyncClient Configuration object.
///
/// AWS Access Key ID
/// AWS Secret Access Key
/// The AmazonCognitoSyncClient Configuration Object
public AmazonCognitoSyncClient(string awsAccessKeyId, string awsSecretAccessKey, AmazonCognitoSyncConfig clientConfig)
: base(awsAccessKeyId, awsSecretAccessKey, clientConfig)
{
}
///
/// Constructs AmazonCognitoSyncClient with AWS Access Key ID and AWS Secret Key
///
/// AWS Access Key ID
/// AWS Secret Access Key
/// AWS Session Token
public AmazonCognitoSyncClient(string awsAccessKeyId, string awsSecretAccessKey, string awsSessionToken)
: this(awsAccessKeyId, awsSecretAccessKey, awsSessionToken, new AmazonCognitoSyncConfig())
{
}
///
/// Constructs AmazonCognitoSyncClient with AWS Access Key ID and AWS Secret Key
///
/// AWS Access Key ID
/// AWS Secret Access Key
/// AWS Session Token
/// The region to connect.
public AmazonCognitoSyncClient(string awsAccessKeyId, string awsSecretAccessKey, string awsSessionToken, RegionEndpoint region)
: this(awsAccessKeyId, awsSecretAccessKey, awsSessionToken, new AmazonCognitoSyncConfig{RegionEndpoint = region})
{
}
///
/// Constructs AmazonCognitoSyncClient with AWS Access Key ID, AWS Secret Key and an
/// AmazonCognitoSyncClient Configuration object.
///
/// AWS Access Key ID
/// AWS Secret Access Key
/// AWS Session Token
/// The AmazonCognitoSyncClient Configuration Object
public AmazonCognitoSyncClient(string awsAccessKeyId, string awsSecretAccessKey, string awsSessionToken, AmazonCognitoSyncConfig clientConfig)
: base(awsAccessKeyId, awsSecretAccessKey, awsSessionToken, clientConfig)
{
}
#endregion
#region Overrides
///
/// Creates the signer for the service.
///
protected override AbstractAWSSigner CreateSigner()
{
return new AWS4Signer();
}
///
/// Customize the pipeline
///
///
protected override void CustomizeRuntimePipeline(RuntimePipeline pipeline)
{
pipeline.RemoveHandler();
pipeline.AddHandlerBefore(new Amazon.CognitoSync.Internal.CognitoCredentialsRetriever(this.Credentials));
pipeline.RemoveHandler();
pipeline.AddHandlerAfter(new AmazonCognitoSyncEndpointResolver());
}
///
/// Capture metadata for the service.
///
protected override IServiceMetadata ServiceMetadata
{
get
{
return serviceMetadata;
}
}
#endregion
#region Dispose
///
/// Disposes the service client.
///
protected override void Dispose(bool disposing)
{
base.Dispose(disposing);
}
#endregion
#region BulkPublish
///
/// Initiates a bulk publish of all existing datasets for an Identity Pool to the configured
/// stream. Customers are limited to one successful bulk publish per 24 hours. Bulk publish
/// is an asynchronous request, customers can see the status of the request via the GetBulkPublishDetails
/// operation.
///
///
///
/// This API can only be called with developer credentials. You cannot call this API with
/// the temporary user credentials provided by Cognito Identity.
///
///
/// Container for the necessary parameters to execute the BulkPublish service method.
///
/// The response from the BulkPublish service method, as returned by CognitoSync.
///
/// An exception thrown when a bulk publish operation is requested less than 24 hours
/// after a previous bulk publish operation completed successfully.
///
///
/// An exception thrown when there is an IN_PROGRESS bulk publish operation for the given
/// identity pool.
///
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
/// REST API Reference for BulkPublish Operation
public virtual BulkPublishResponse BulkPublish(BulkPublishRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = BulkPublishRequestMarshaller.Instance;
options.ResponseUnmarshaller = BulkPublishResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the BulkPublish operation.
///
///
/// Container for the necessary parameters to execute the BulkPublish operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndBulkPublish
/// operation.
/// REST API Reference for BulkPublish Operation
public virtual IAsyncResult BeginBulkPublish(BulkPublishRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = BulkPublishRequestMarshaller.Instance;
options.ResponseUnmarshaller = BulkPublishResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the BulkPublish operation.
///
///
/// The IAsyncResult returned by the call to BeginBulkPublish.
///
/// Returns a BulkPublishResult from CognitoSync.
/// REST API Reference for BulkPublish Operation
public virtual BulkPublishResponse EndBulkPublish(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region DeleteDataset
///
/// Deletes the specific dataset. The dataset will be deleted permanently, and the action
/// can't be undone. Datasets that this dataset was merged with will no longer report
/// the merge. Any subsequent operation on this dataset will result in a ResourceNotFoundException.
///
///
///
/// This API can be called with temporary user credentials provided by Cognito Identity
/// or with developer credentials.
///
///
/// Container for the necessary parameters to execute the DeleteDataset service method.
///
/// The response from the DeleteDataset service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if an update can't be applied because the resource was changed by another call
/// and this would result in a conflict.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for DeleteDataset Operation
public virtual DeleteDatasetResponse DeleteDataset(DeleteDatasetRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = DeleteDatasetRequestMarshaller.Instance;
options.ResponseUnmarshaller = DeleteDatasetResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the DeleteDataset operation.
///
///
/// Container for the necessary parameters to execute the DeleteDataset operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndDeleteDataset
/// operation.
/// REST API Reference for DeleteDataset Operation
public virtual IAsyncResult BeginDeleteDataset(DeleteDatasetRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = DeleteDatasetRequestMarshaller.Instance;
options.ResponseUnmarshaller = DeleteDatasetResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the DeleteDataset operation.
///
///
/// The IAsyncResult returned by the call to BeginDeleteDataset.
///
/// Returns a DeleteDatasetResult from CognitoSync.
/// REST API Reference for DeleteDataset Operation
public virtual DeleteDatasetResponse EndDeleteDataset(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region DescribeDataset
///
/// Gets meta data about a dataset by identity and dataset name. With Amazon Cognito Sync,
/// each identity has access only to its own data. Thus, the credentials used to make
/// this API call need to have access to the identity data.
///
///
///
/// This API can be called with temporary user credentials provided by Cognito Identity
/// or with developer credentials. You should use Cognito Identity credentials to make
/// this API call.
///
///
/// Container for the necessary parameters to execute the DescribeDataset service method.
///
/// The response from the DescribeDataset service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for DescribeDataset Operation
public virtual DescribeDatasetResponse DescribeDataset(DescribeDatasetRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = DescribeDatasetRequestMarshaller.Instance;
options.ResponseUnmarshaller = DescribeDatasetResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the DescribeDataset operation.
///
///
/// Container for the necessary parameters to execute the DescribeDataset operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndDescribeDataset
/// operation.
/// REST API Reference for DescribeDataset Operation
public virtual IAsyncResult BeginDescribeDataset(DescribeDatasetRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = DescribeDatasetRequestMarshaller.Instance;
options.ResponseUnmarshaller = DescribeDatasetResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the DescribeDataset operation.
///
///
/// The IAsyncResult returned by the call to BeginDescribeDataset.
///
/// Returns a DescribeDatasetResult from CognitoSync.
/// REST API Reference for DescribeDataset Operation
public virtual DescribeDatasetResponse EndDescribeDataset(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region DescribeIdentityPoolUsage
///
/// Gets usage details (for example, data storage) about a particular identity pool.
///
///
///
/// This API can only be called with developer credentials. You cannot call this API with
/// the temporary user credentials provided by Cognito Identity.
///
///
/// A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito. GUID generation is unique within a region.
///
/// The response from the DescribeIdentityPoolUsage service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for DescribeIdentityPoolUsage Operation
public virtual DescribeIdentityPoolUsageResponse DescribeIdentityPoolUsage(string identityPoolId)
{
var request = new DescribeIdentityPoolUsageRequest();
request.IdentityPoolId = identityPoolId;
return DescribeIdentityPoolUsage(request);
}
///
/// Gets usage details (for example, data storage) about a particular identity pool.
///
///
///
/// This API can only be called with developer credentials. You cannot call this API with
/// the temporary user credentials provided by Cognito Identity.
///
///
/// Container for the necessary parameters to execute the DescribeIdentityPoolUsage service method.
///
/// The response from the DescribeIdentityPoolUsage service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for DescribeIdentityPoolUsage Operation
public virtual DescribeIdentityPoolUsageResponse DescribeIdentityPoolUsage(DescribeIdentityPoolUsageRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = DescribeIdentityPoolUsageRequestMarshaller.Instance;
options.ResponseUnmarshaller = DescribeIdentityPoolUsageResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the DescribeIdentityPoolUsage operation.
///
///
/// Container for the necessary parameters to execute the DescribeIdentityPoolUsage operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndDescribeIdentityPoolUsage
/// operation.
/// REST API Reference for DescribeIdentityPoolUsage Operation
public virtual IAsyncResult BeginDescribeIdentityPoolUsage(DescribeIdentityPoolUsageRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = DescribeIdentityPoolUsageRequestMarshaller.Instance;
options.ResponseUnmarshaller = DescribeIdentityPoolUsageResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the DescribeIdentityPoolUsage operation.
///
///
/// The IAsyncResult returned by the call to BeginDescribeIdentityPoolUsage.
///
/// Returns a DescribeIdentityPoolUsageResult from CognitoSync.
/// REST API Reference for DescribeIdentityPoolUsage Operation
public virtual DescribeIdentityPoolUsageResponse EndDescribeIdentityPoolUsage(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region DescribeIdentityUsage
///
/// Gets usage information for an identity, including number of datasets and data usage.
///
///
///
/// This API can be called with temporary user credentials provided by Cognito Identity
/// or with developer credentials.
///
///
/// Container for the necessary parameters to execute the DescribeIdentityUsage service method.
///
/// The response from the DescribeIdentityUsage service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for DescribeIdentityUsage Operation
public virtual DescribeIdentityUsageResponse DescribeIdentityUsage(DescribeIdentityUsageRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = DescribeIdentityUsageRequestMarshaller.Instance;
options.ResponseUnmarshaller = DescribeIdentityUsageResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the DescribeIdentityUsage operation.
///
///
/// Container for the necessary parameters to execute the DescribeIdentityUsage operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndDescribeIdentityUsage
/// operation.
/// REST API Reference for DescribeIdentityUsage Operation
public virtual IAsyncResult BeginDescribeIdentityUsage(DescribeIdentityUsageRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = DescribeIdentityUsageRequestMarshaller.Instance;
options.ResponseUnmarshaller = DescribeIdentityUsageResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the DescribeIdentityUsage operation.
///
///
/// The IAsyncResult returned by the call to BeginDescribeIdentityUsage.
///
/// Returns a DescribeIdentityUsageResult from CognitoSync.
/// REST API Reference for DescribeIdentityUsage Operation
public virtual DescribeIdentityUsageResponse EndDescribeIdentityUsage(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region GetBulkPublishDetails
///
/// Get the status of the last BulkPublish operation for an identity pool.
///
///
///
/// This API can only be called with developer credentials. You cannot call this API with
/// the temporary user credentials provided by Cognito Identity.
///
///
/// Container for the necessary parameters to execute the GetBulkPublishDetails service method.
///
/// The response from the GetBulkPublishDetails service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
/// REST API Reference for GetBulkPublishDetails Operation
public virtual GetBulkPublishDetailsResponse GetBulkPublishDetails(GetBulkPublishDetailsRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = GetBulkPublishDetailsRequestMarshaller.Instance;
options.ResponseUnmarshaller = GetBulkPublishDetailsResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the GetBulkPublishDetails operation.
///
///
/// Container for the necessary parameters to execute the GetBulkPublishDetails operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndGetBulkPublishDetails
/// operation.
/// REST API Reference for GetBulkPublishDetails Operation
public virtual IAsyncResult BeginGetBulkPublishDetails(GetBulkPublishDetailsRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = GetBulkPublishDetailsRequestMarshaller.Instance;
options.ResponseUnmarshaller = GetBulkPublishDetailsResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the GetBulkPublishDetails operation.
///
///
/// The IAsyncResult returned by the call to BeginGetBulkPublishDetails.
///
/// Returns a GetBulkPublishDetailsResult from CognitoSync.
/// REST API Reference for GetBulkPublishDetails Operation
public virtual GetBulkPublishDetailsResponse EndGetBulkPublishDetails(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region GetCognitoEvents
///
/// Gets the events and the corresponding Lambda functions associated with an identity
/// pool.
///
///
///
/// This API can only be called with developer credentials. You cannot call this API with
/// the temporary user credentials provided by Cognito Identity.
///
///
/// Container for the necessary parameters to execute the GetCognitoEvents service method.
///
/// The response from the GetCognitoEvents service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for GetCognitoEvents Operation
public virtual GetCognitoEventsResponse GetCognitoEvents(GetCognitoEventsRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = GetCognitoEventsRequestMarshaller.Instance;
options.ResponseUnmarshaller = GetCognitoEventsResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the GetCognitoEvents operation.
///
///
/// Container for the necessary parameters to execute the GetCognitoEvents operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndGetCognitoEvents
/// operation.
/// REST API Reference for GetCognitoEvents Operation
public virtual IAsyncResult BeginGetCognitoEvents(GetCognitoEventsRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = GetCognitoEventsRequestMarshaller.Instance;
options.ResponseUnmarshaller = GetCognitoEventsResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the GetCognitoEvents operation.
///
///
/// The IAsyncResult returned by the call to BeginGetCognitoEvents.
///
/// Returns a GetCognitoEventsResult from CognitoSync.
/// REST API Reference for GetCognitoEvents Operation
public virtual GetCognitoEventsResponse EndGetCognitoEvents(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region GetIdentityPoolConfiguration
///
/// Gets the configuration settings of an identity pool.
///
///
///
/// This API can only be called with developer credentials. You cannot call this API with
/// the temporary user credentials provided by Cognito Identity.
///
///
/// A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito. This is the ID of the pool for which to return a configuration.
///
/// The response from the GetIdentityPoolConfiguration service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for GetIdentityPoolConfiguration Operation
public virtual GetIdentityPoolConfigurationResponse GetIdentityPoolConfiguration(string identityPoolId)
{
var request = new GetIdentityPoolConfigurationRequest();
request.IdentityPoolId = identityPoolId;
return GetIdentityPoolConfiguration(request);
}
///
/// Gets the configuration settings of an identity pool.
///
///
///
/// This API can only be called with developer credentials. You cannot call this API with
/// the temporary user credentials provided by Cognito Identity.
///
///
/// Container for the necessary parameters to execute the GetIdentityPoolConfiguration service method.
///
/// The response from the GetIdentityPoolConfiguration service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for GetIdentityPoolConfiguration Operation
public virtual GetIdentityPoolConfigurationResponse GetIdentityPoolConfiguration(GetIdentityPoolConfigurationRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = GetIdentityPoolConfigurationRequestMarshaller.Instance;
options.ResponseUnmarshaller = GetIdentityPoolConfigurationResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the GetIdentityPoolConfiguration operation.
///
///
/// Container for the necessary parameters to execute the GetIdentityPoolConfiguration operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndGetIdentityPoolConfiguration
/// operation.
/// REST API Reference for GetIdentityPoolConfiguration Operation
public virtual IAsyncResult BeginGetIdentityPoolConfiguration(GetIdentityPoolConfigurationRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = GetIdentityPoolConfigurationRequestMarshaller.Instance;
options.ResponseUnmarshaller = GetIdentityPoolConfigurationResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the GetIdentityPoolConfiguration operation.
///
///
/// The IAsyncResult returned by the call to BeginGetIdentityPoolConfiguration.
///
/// Returns a GetIdentityPoolConfigurationResult from CognitoSync.
/// REST API Reference for GetIdentityPoolConfiguration Operation
public virtual GetIdentityPoolConfigurationResponse EndGetIdentityPoolConfiguration(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region ListDatasets
///
/// Lists datasets for an identity. With Amazon Cognito Sync, each identity has access
/// only to its own data. Thus, the credentials used to make this API call need to have
/// access to the identity data.
///
///
///
/// ListDatasets can be called with temporary user credentials provided by Cognito Identity
/// or with developer credentials. You should use the Cognito Identity credentials to
/// make this API call.
///
///
/// Container for the necessary parameters to execute the ListDatasets service method.
///
/// The response from the ListDatasets service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for ListDatasets Operation
public virtual ListDatasetsResponse ListDatasets(ListDatasetsRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = ListDatasetsRequestMarshaller.Instance;
options.ResponseUnmarshaller = ListDatasetsResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the ListDatasets operation.
///
///
/// Container for the necessary parameters to execute the ListDatasets operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndListDatasets
/// operation.
/// REST API Reference for ListDatasets Operation
public virtual IAsyncResult BeginListDatasets(ListDatasetsRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = ListDatasetsRequestMarshaller.Instance;
options.ResponseUnmarshaller = ListDatasetsResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the ListDatasets operation.
///
///
/// The IAsyncResult returned by the call to BeginListDatasets.
///
/// Returns a ListDatasetsResult from CognitoSync.
/// REST API Reference for ListDatasets Operation
public virtual ListDatasetsResponse EndListDatasets(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region ListIdentityPoolUsage
///
/// Gets a list of identity pools registered with Cognito.
///
///
///
/// ListIdentityPoolUsage can only be called with developer credentials. You cannot make
/// this API call with the temporary user credentials provided by Cognito Identity.
///
///
/// Container for the necessary parameters to execute the ListIdentityPoolUsage service method.
///
/// The response from the ListIdentityPoolUsage service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for ListIdentityPoolUsage Operation
public virtual ListIdentityPoolUsageResponse ListIdentityPoolUsage(ListIdentityPoolUsageRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = ListIdentityPoolUsageRequestMarshaller.Instance;
options.ResponseUnmarshaller = ListIdentityPoolUsageResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the ListIdentityPoolUsage operation.
///
///
/// Container for the necessary parameters to execute the ListIdentityPoolUsage operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndListIdentityPoolUsage
/// operation.
/// REST API Reference for ListIdentityPoolUsage Operation
public virtual IAsyncResult BeginListIdentityPoolUsage(ListIdentityPoolUsageRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = ListIdentityPoolUsageRequestMarshaller.Instance;
options.ResponseUnmarshaller = ListIdentityPoolUsageResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the ListIdentityPoolUsage operation.
///
///
/// The IAsyncResult returned by the call to BeginListIdentityPoolUsage.
///
/// Returns a ListIdentityPoolUsageResult from CognitoSync.
/// REST API Reference for ListIdentityPoolUsage Operation
public virtual ListIdentityPoolUsageResponse EndListIdentityPoolUsage(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region ListRecords
///
/// Gets paginated records, optionally changed after a particular sync count for a dataset
/// and identity. With Amazon Cognito Sync, each identity has access only to its own data.
/// Thus, the credentials used to make this API call need to have access to the identity
/// data.
///
///
///
/// ListRecords can be called with temporary user credentials provided by Cognito Identity
/// or with developer credentials. You should use Cognito Identity credentials to make
/// this API call.
///
///
/// Container for the necessary parameters to execute the ListRecords service method.
///
/// The response from the ListRecords service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for ListRecords Operation
public virtual ListRecordsResponse ListRecords(ListRecordsRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = ListRecordsRequestMarshaller.Instance;
options.ResponseUnmarshaller = ListRecordsResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the ListRecords operation.
///
///
/// Container for the necessary parameters to execute the ListRecords operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndListRecords
/// operation.
/// REST API Reference for ListRecords Operation
public virtual IAsyncResult BeginListRecords(ListRecordsRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = ListRecordsRequestMarshaller.Instance;
options.ResponseUnmarshaller = ListRecordsResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the ListRecords operation.
///
///
/// The IAsyncResult returned by the call to BeginListRecords.
///
/// Returns a ListRecordsResult from CognitoSync.
/// REST API Reference for ListRecords Operation
public virtual ListRecordsResponse EndListRecords(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region RegisterDevice
///
/// Registers a device to receive push sync notifications.
///
///
///
/// This API can only be called with temporary credentials provided by Cognito Identity.
/// You cannot call this API with developer credentials.
///
///
/// Container for the necessary parameters to execute the RegisterDevice service method.
///
/// The response from the RegisterDevice service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
///
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for RegisterDevice Operation
public virtual RegisterDeviceResponse RegisterDevice(RegisterDeviceRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = RegisterDeviceRequestMarshaller.Instance;
options.ResponseUnmarshaller = RegisterDeviceResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the RegisterDevice operation.
///
///
/// Container for the necessary parameters to execute the RegisterDevice operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndRegisterDevice
/// operation.
/// REST API Reference for RegisterDevice Operation
public virtual IAsyncResult BeginRegisterDevice(RegisterDeviceRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = RegisterDeviceRequestMarshaller.Instance;
options.ResponseUnmarshaller = RegisterDeviceResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the RegisterDevice operation.
///
///
/// The IAsyncResult returned by the call to BeginRegisterDevice.
///
/// Returns a RegisterDeviceResult from CognitoSync.
/// REST API Reference for RegisterDevice Operation
public virtual RegisterDeviceResponse EndRegisterDevice(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region SetCognitoEvents
///
/// Sets the AWS Lambda function for a given event type for an identity pool. This request
/// only updates the key/value pair specified. Other key/values pairs are not updated.
/// To remove a key value pair, pass a empty value for the particular key.
///
///
///
/// This API can only be called with developer credentials. You cannot call this API with
/// the temporary user credentials provided by Cognito Identity.
///
///
/// Container for the necessary parameters to execute the SetCognitoEvents service method.
///
/// The response from the SetCognitoEvents service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for SetCognitoEvents Operation
public virtual SetCognitoEventsResponse SetCognitoEvents(SetCognitoEventsRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = SetCognitoEventsRequestMarshaller.Instance;
options.ResponseUnmarshaller = SetCognitoEventsResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the SetCognitoEvents operation.
///
///
/// Container for the necessary parameters to execute the SetCognitoEvents operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndSetCognitoEvents
/// operation.
/// REST API Reference for SetCognitoEvents Operation
public virtual IAsyncResult BeginSetCognitoEvents(SetCognitoEventsRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = SetCognitoEventsRequestMarshaller.Instance;
options.ResponseUnmarshaller = SetCognitoEventsResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the SetCognitoEvents operation.
///
///
/// The IAsyncResult returned by the call to BeginSetCognitoEvents.
///
/// Returns a SetCognitoEventsResult from CognitoSync.
/// REST API Reference for SetCognitoEvents Operation
public virtual SetCognitoEventsResponse EndSetCognitoEvents(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region SetIdentityPoolConfiguration
///
/// Sets the necessary configuration for push sync.
///
///
///
/// This API can only be called with developer credentials. You cannot call this API with
/// the temporary user credentials provided by Cognito Identity.
///
///
/// Container for the necessary parameters to execute the SetIdentityPoolConfiguration service method.
///
/// The response from the SetIdentityPoolConfiguration service method, as returned by CognitoSync.
///
/// Thrown if there are parallel requests to modify a resource.
///
///
/// Indicates an internal service error.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for SetIdentityPoolConfiguration Operation
public virtual SetIdentityPoolConfigurationResponse SetIdentityPoolConfiguration(SetIdentityPoolConfigurationRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = SetIdentityPoolConfigurationRequestMarshaller.Instance;
options.ResponseUnmarshaller = SetIdentityPoolConfigurationResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the SetIdentityPoolConfiguration operation.
///
///
/// Container for the necessary parameters to execute the SetIdentityPoolConfiguration operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndSetIdentityPoolConfiguration
/// operation.
/// REST API Reference for SetIdentityPoolConfiguration Operation
public virtual IAsyncResult BeginSetIdentityPoolConfiguration(SetIdentityPoolConfigurationRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = SetIdentityPoolConfigurationRequestMarshaller.Instance;
options.ResponseUnmarshaller = SetIdentityPoolConfigurationResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the SetIdentityPoolConfiguration operation.
///
///
/// The IAsyncResult returned by the call to BeginSetIdentityPoolConfiguration.
///
/// Returns a SetIdentityPoolConfigurationResult from CognitoSync.
/// REST API Reference for SetIdentityPoolConfiguration Operation
public virtual SetIdentityPoolConfigurationResponse EndSetIdentityPoolConfiguration(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region SubscribeToDataset
///
/// Subscribes to receive notifications when a dataset is modified by another device.
///
///
///
/// This API can only be called with temporary credentials provided by Cognito Identity.
/// You cannot call this API with developer credentials.
///
///
/// Container for the necessary parameters to execute the SubscribeToDataset service method.
///
/// The response from the SubscribeToDataset service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
///
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for SubscribeToDataset Operation
public virtual SubscribeToDatasetResponse SubscribeToDataset(SubscribeToDatasetRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = SubscribeToDatasetRequestMarshaller.Instance;
options.ResponseUnmarshaller = SubscribeToDatasetResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the SubscribeToDataset operation.
///
///
/// Container for the necessary parameters to execute the SubscribeToDataset operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndSubscribeToDataset
/// operation.
/// REST API Reference for SubscribeToDataset Operation
public virtual IAsyncResult BeginSubscribeToDataset(SubscribeToDatasetRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = SubscribeToDatasetRequestMarshaller.Instance;
options.ResponseUnmarshaller = SubscribeToDatasetResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the SubscribeToDataset operation.
///
///
/// The IAsyncResult returned by the call to BeginSubscribeToDataset.
///
/// Returns a SubscribeToDatasetResult from CognitoSync.
/// REST API Reference for SubscribeToDataset Operation
public virtual SubscribeToDatasetResponse EndSubscribeToDataset(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region UnsubscribeFromDataset
///
/// Unsubscribes from receiving notifications when a dataset is modified by another device.
///
///
///
/// This API can only be called with temporary credentials provided by Cognito Identity.
/// You cannot call this API with developer credentials.
///
///
/// Container for the necessary parameters to execute the UnsubscribeFromDataset service method.
///
/// The response from the UnsubscribeFromDataset service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
///
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for UnsubscribeFromDataset Operation
public virtual UnsubscribeFromDatasetResponse UnsubscribeFromDataset(UnsubscribeFromDatasetRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = UnsubscribeFromDatasetRequestMarshaller.Instance;
options.ResponseUnmarshaller = UnsubscribeFromDatasetResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the UnsubscribeFromDataset operation.
///
///
/// Container for the necessary parameters to execute the UnsubscribeFromDataset operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndUnsubscribeFromDataset
/// operation.
/// REST API Reference for UnsubscribeFromDataset Operation
public virtual IAsyncResult BeginUnsubscribeFromDataset(UnsubscribeFromDatasetRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = UnsubscribeFromDatasetRequestMarshaller.Instance;
options.ResponseUnmarshaller = UnsubscribeFromDatasetResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the UnsubscribeFromDataset operation.
///
///
/// The IAsyncResult returned by the call to BeginUnsubscribeFromDataset.
///
/// Returns a UnsubscribeFromDatasetResult from CognitoSync.
/// REST API Reference for UnsubscribeFromDataset Operation
public virtual UnsubscribeFromDatasetResponse EndUnsubscribeFromDataset(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
#region UpdateRecords
///
/// Posts updates to records and adds and deletes records for a dataset and user.
///
///
///
/// The sync count in the record patch is your last known sync count for that record.
/// The server will reject an UpdateRecords request with a ResourceConflictException if
/// you try to patch a record with a new value but a stale sync count.
///
///
///
/// For example, if the sync count on the server is 5 for a key called highScore and you
/// try and submit a new highScore with sync count of 4, the request will be rejected.
/// To obtain the current sync count for a record, call ListRecords. On a successful update
/// of the record, the response returns the new sync count for that record. You should
/// present that sync count the next time you try to update that same record. When the
/// record does not exist, specify the sync count as 0.
///
///
///
/// This API can be called with temporary user credentials provided by Cognito Identity
/// or with developer credentials.
///
///
/// Container for the necessary parameters to execute the UpdateRecords service method.
///
/// The response from the UpdateRecords service method, as returned by CognitoSync.
///
/// Indicates an internal service error.
///
///
/// The AWS Lambda function returned invalid output or an exception.
///
///
/// Thrown when a request parameter does not comply with the associated constraints.
///
///
/// AWS Lambda throttled your account, please contact AWS Support
///
///
/// Thrown when the limit on the number of objects or operations has been exceeded.
///
///
/// Thrown when a user is not authorized to access the requested resource.
///
///
/// Thrown if an update can't be applied because the resource was changed by another call
/// and this would result in a conflict.
///
///
/// Thrown if the resource doesn't exist.
///
///
/// Thrown if the request is throttled.
///
/// REST API Reference for UpdateRecords Operation
public virtual UpdateRecordsResponse UpdateRecords(UpdateRecordsRequest request)
{
var options = new InvokeOptions();
options.RequestMarshaller = UpdateRecordsRequestMarshaller.Instance;
options.ResponseUnmarshaller = UpdateRecordsResponseUnmarshaller.Instance;
return Invoke(request, options);
}
///
/// Initiates the asynchronous execution of the UpdateRecords operation.
///
///
/// Container for the necessary parameters to execute the UpdateRecords operation on AmazonCognitoSyncClient.
/// An AsyncCallback delegate that is invoked when the operation completes.
/// A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
/// procedure using the AsyncState property.
///
/// An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndUpdateRecords
/// operation.
/// REST API Reference for UpdateRecords Operation
public virtual IAsyncResult BeginUpdateRecords(UpdateRecordsRequest request, AsyncCallback callback, object state)
{
var options = new InvokeOptions();
options.RequestMarshaller = UpdateRecordsRequestMarshaller.Instance;
options.ResponseUnmarshaller = UpdateRecordsResponseUnmarshaller.Instance;
return BeginInvoke(request, options, callback, state);
}
///
/// Finishes the asynchronous execution of the UpdateRecords operation.
///
///
/// The IAsyncResult returned by the call to BeginUpdateRecords.
///
/// Returns a UpdateRecordsResult from CognitoSync.
/// REST API Reference for UpdateRecords Operation
public virtual UpdateRecordsResponse EndUpdateRecords(IAsyncResult asyncResult)
{
return EndInvoke(asyncResult);
}
#endregion
}
}