/* * 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 ram-2018-01-04.normal.json service model. */ using System; using System.Runtime.ExceptionServices; using System.Threading; using System.Threading.Tasks; using System.Collections.Generic; using System.Net; using Amazon.RAM.Model; using Amazon.RAM.Model.Internal.MarshallTransformations; using Amazon.RAM.Internal; using Amazon.Runtime; using Amazon.Runtime.Internal; using Amazon.Runtime.Internal.Auth; using Amazon.Runtime.Internal.Transform; namespace Amazon.RAM { /// /// Implementation for accessing RAM /// /// This is the Resource Access Manager API Reference. This documentation provides /// descriptions and syntax for each of the actions and data types in RAM. RAM is a service /// that helps you securely share your Amazon Web Services resources to other Amazon Web /// Services accounts. If you use Organizations to manage your accounts, then you can /// share your resources with your entire organization or to organizational units (OUs). /// For supported resource types, you can also share resources with individual Identity /// and Access Management (IAM) roles and users. /// /// /// /// To learn more about RAM, see the following resources: /// /// /// public partial class AmazonRAMClient : AmazonServiceClient, IAmazonRAM { private static IServiceMetadata serviceMetadata = new AmazonRAMMetadata(); #region Constructors /// /// Constructs AmazonRAMClient 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 AmazonRAMClient() : base(FallbackCredentialsFactory.GetCredentials(), new AmazonRAMConfig()) { } /// /// Constructs AmazonRAMClient 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 AmazonRAMClient(RegionEndpoint region) : base(FallbackCredentialsFactory.GetCredentials(), new AmazonRAMConfig{RegionEndpoint = region}) { } /// /// Constructs AmazonRAMClient 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 AmazonRAMClient Configuration Object public AmazonRAMClient(AmazonRAMConfig config) : base(FallbackCredentialsFactory.GetCredentials(config), config){} /// /// Constructs AmazonRAMClient with AWS Credentials /// /// AWS Credentials public AmazonRAMClient(AWSCredentials credentials) : this(credentials, new AmazonRAMConfig()) { } /// /// Constructs AmazonRAMClient with AWS Credentials /// /// AWS Credentials /// The region to connect. public AmazonRAMClient(AWSCredentials credentials, RegionEndpoint region) : this(credentials, new AmazonRAMConfig{RegionEndpoint = region}) { } /// /// Constructs AmazonRAMClient with AWS Credentials and an /// AmazonRAMClient Configuration object. /// /// AWS Credentials /// The AmazonRAMClient Configuration Object public AmazonRAMClient(AWSCredentials credentials, AmazonRAMConfig clientConfig) : base(credentials, clientConfig) { } /// /// Constructs AmazonRAMClient with AWS Access Key ID and AWS Secret Key /// /// AWS Access Key ID /// AWS Secret Access Key public AmazonRAMClient(string awsAccessKeyId, string awsSecretAccessKey) : this(awsAccessKeyId, awsSecretAccessKey, new AmazonRAMConfig()) { } /// /// Constructs AmazonRAMClient with AWS Access Key ID and AWS Secret Key /// /// AWS Access Key ID /// AWS Secret Access Key /// The region to connect. public AmazonRAMClient(string awsAccessKeyId, string awsSecretAccessKey, RegionEndpoint region) : this(awsAccessKeyId, awsSecretAccessKey, new AmazonRAMConfig() {RegionEndpoint=region}) { } /// /// Constructs AmazonRAMClient with AWS Access Key ID, AWS Secret Key and an /// AmazonRAMClient Configuration object. /// /// AWS Access Key ID /// AWS Secret Access Key /// The AmazonRAMClient Configuration Object public AmazonRAMClient(string awsAccessKeyId, string awsSecretAccessKey, AmazonRAMConfig clientConfig) : base(awsAccessKeyId, awsSecretAccessKey, clientConfig) { } /// /// Constructs AmazonRAMClient with AWS Access Key ID and AWS Secret Key /// /// AWS Access Key ID /// AWS Secret Access Key /// AWS Session Token public AmazonRAMClient(string awsAccessKeyId, string awsSecretAccessKey, string awsSessionToken) : this(awsAccessKeyId, awsSecretAccessKey, awsSessionToken, new AmazonRAMConfig()) { } /// /// Constructs AmazonRAMClient 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 AmazonRAMClient(string awsAccessKeyId, string awsSecretAccessKey, string awsSessionToken, RegionEndpoint region) : this(awsAccessKeyId, awsSecretAccessKey, awsSessionToken, new AmazonRAMConfig{RegionEndpoint = region}) { } /// /// Constructs AmazonRAMClient with AWS Access Key ID, AWS Secret Key and an /// AmazonRAMClient Configuration object. /// /// AWS Access Key ID /// AWS Secret Access Key /// AWS Session Token /// The AmazonRAMClient Configuration Object public AmazonRAMClient(string awsAccessKeyId, string awsSecretAccessKey, string awsSessionToken, AmazonRAMConfig clientConfig) : base(awsAccessKeyId, awsSecretAccessKey, awsSessionToken, clientConfig) { } #endregion #if AWS_ASYNC_ENUMERABLES_API private IRAMPaginatorFactory _paginators; /// /// Paginators for the service /// public IRAMPaginatorFactory Paginators { get { if (this._paginators == null) { this._paginators = new RAMPaginatorFactory(this); } return this._paginators; } } #endif #region Overrides /// /// Creates the signer for the service. /// protected override AbstractAWSSigner CreateSigner() { return new AWS4Signer(); } /// /// Customizes the runtime pipeline. /// /// Runtime pipeline for the current client. protected override void CustomizeRuntimePipeline(RuntimePipeline pipeline) { pipeline.RemoveHandler(); pipeline.AddHandlerAfter(new AmazonRAMEndpointResolver()); } /// /// 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 AcceptResourceShareInvitation internal virtual AcceptResourceShareInvitationResponse AcceptResourceShareInvitation(AcceptResourceShareInvitationRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = AcceptResourceShareInvitationRequestMarshaller.Instance; options.ResponseUnmarshaller = AcceptResourceShareInvitationResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Accepts an invitation to a resource share from another Amazon Web Services account. /// After you accept the invitation, the resources included in the resource share are /// available to interact with in the relevant Amazon Web Services Management Consoles /// and tools. /// /// Container for the necessary parameters to execute the AcceptResourceShareInvitation service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the AcceptResourceShareInvitation service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the specified invitation was already accepted. /// /// /// The operation failed because the specified invitation was already rejected. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) for an invitation was not found. /// /// /// The operation failed because the specified invitation is past its expiration date /// and time. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// REST API Reference for AcceptResourceShareInvitation Operation public virtual Task AcceptResourceShareInvitationAsync(AcceptResourceShareInvitationRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = AcceptResourceShareInvitationRequestMarshaller.Instance; options.ResponseUnmarshaller = AcceptResourceShareInvitationResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region AssociateResourceShare internal virtual AssociateResourceShareResponse AssociateResourceShare(AssociateResourceShareRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = AssociateResourceShareRequestMarshaller.Instance; options.ResponseUnmarshaller = AssociateResourceShareResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Adds the specified list of principals and list of resources to a resource share. Principals /// that already have access to this resource share immediately receive access to the /// added resources. Newly added principals immediately receive access to the resources /// shared in this resource share. /// /// Container for the necessary parameters to execute the AssociateResourceShare service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the AssociateResourceShare service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the requested operation isn't valid for the resource /// share in its current state. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because it would exceed the limit for resource shares for your /// account. To view the limits for your Amazon Web Services account, see the RAM /// page in the Service Quotas console. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because it exceeded the rate at which you are allowed to perform /// this operation. Please try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for AssociateResourceShare Operation public virtual Task AssociateResourceShareAsync(AssociateResourceShareRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = AssociateResourceShareRequestMarshaller.Instance; options.ResponseUnmarshaller = AssociateResourceShareResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region AssociateResourceSharePermission internal virtual AssociateResourceSharePermissionResponse AssociateResourceSharePermission(AssociateResourceSharePermissionRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = AssociateResourceSharePermissionRequestMarshaller.Instance; options.ResponseUnmarshaller = AssociateResourceSharePermissionResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Adds or replaces the RAM permission for a resource type included in a resource share. /// You can have exactly one permission associated with each resource type in the resource /// share. You can add a new RAM permission only if there are currently no resources of /// that resource type currently in the resource share. /// /// Container for the necessary parameters to execute the AssociateResourceSharePermission service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the AssociateResourceSharePermission service method, as returned by RAM. /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for AssociateResourceSharePermission Operation public virtual Task AssociateResourceSharePermissionAsync(AssociateResourceSharePermissionRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = AssociateResourceSharePermissionRequestMarshaller.Instance; options.ResponseUnmarshaller = AssociateResourceSharePermissionResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region CreatePermission internal virtual CreatePermissionResponse CreatePermission(CreatePermissionRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = CreatePermissionRequestMarshaller.Instance; options.ResponseUnmarshaller = CreatePermissionResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Creates a customer managed permission for a specified resource type that you can attach /// to resource shares. It is created in the Amazon Web Services Region in which you call /// the operation. /// /// Container for the necessary parameters to execute the CreatePermission service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the CreatePermission service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because a policy you specified isn't valid. /// /// /// The operation failed because the policy template that you provided isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because a permission with the specified name already exists in /// the requested Amazon Web Services Region. Choose a different name. /// /// /// The operation failed because it would exceed the maximum number of permissions you /// can create in each Amazon Web Services Region. To view the limits for your Amazon /// Web Services account, see the RAM /// page in the Service Quotas console. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// REST API Reference for CreatePermission Operation public virtual Task CreatePermissionAsync(CreatePermissionRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = CreatePermissionRequestMarshaller.Instance; options.ResponseUnmarshaller = CreatePermissionResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region CreatePermissionVersion internal virtual CreatePermissionVersionResponse CreatePermissionVersion(CreatePermissionVersionRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = CreatePermissionVersionRequestMarshaller.Instance; options.ResponseUnmarshaller = CreatePermissionVersionResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Creates a new version of the specified customer managed permission. The new version /// is automatically set as the default version of the customer managed permission. New /// resource shares automatically use the default permission. Existing resource shares /// continue to use their original permission versions, but you can use ReplacePermissionAssociations /// to update them. /// /// /// /// If the specified customer managed permission already has the maximum of 5 versions, /// then you must delete one of the existing versions before you can create a new one. /// /// /// Container for the necessary parameters to execute the CreatePermissionVersion service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the CreatePermissionVersion service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because a policy you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the policy template that you provided isn't valid. /// /// /// The operation failed because it would exceed the limit for the number of versions /// you can have for a permission. To view the limits for your Amazon Web Services account, /// see the RAM /// page in the Service Quotas console. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for CreatePermissionVersion Operation public virtual Task CreatePermissionVersionAsync(CreatePermissionVersionRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = CreatePermissionVersionRequestMarshaller.Instance; options.ResponseUnmarshaller = CreatePermissionVersionResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region CreateResourceShare internal virtual CreateResourceShareResponse CreateResourceShare(CreateResourceShareRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = CreateResourceShareRequestMarshaller.Instance; options.ResponseUnmarshaller = CreateResourceShareResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Creates a resource share. You can provide a list of the Amazon /// Resource Names (ARNs) for the resources that you want to share, a list of principals /// you want to share the resources with, and the permissions to grant those principals. /// /// /// /// Sharing a resource makes it available for use by principals outside of the Amazon /// Web Services account that created the resource. Sharing doesn't change any permissions /// or quotas that apply to the resource in the account that created it. /// /// /// /// Container for the necessary parameters to execute the CreateResourceShare service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the CreateResourceShare service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the requested operation isn't valid for the resource /// share in its current state. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because it would exceed the limit for resource shares for your /// account. To view the limits for your Amazon Web Services account, see the RAM /// page in the Service Quotas console. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because it would exceed the limit for tags for your Amazon Web /// Services account. /// /// /// The operation failed because the specified tag key is a reserved word and can't be /// used. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for CreateResourceShare Operation public virtual Task CreateResourceShareAsync(CreateResourceShareRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = CreateResourceShareRequestMarshaller.Instance; options.ResponseUnmarshaller = CreateResourceShareResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region DeletePermission internal virtual DeletePermissionResponse DeletePermission(DeletePermissionRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = DeletePermissionRequestMarshaller.Instance; options.ResponseUnmarshaller = DeletePermissionResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Deletes the specified customer managed permission in the Amazon Web Services Region /// in which you call this operation. You can delete a customer managed permission only /// if it isn't attached to any resource share. The operation deletes all versions associated /// with the customer managed permission. /// /// Container for the necessary parameters to execute the DeletePermission service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the DeletePermission service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for DeletePermission Operation public virtual Task DeletePermissionAsync(DeletePermissionRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = DeletePermissionRequestMarshaller.Instance; options.ResponseUnmarshaller = DeletePermissionResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region DeletePermissionVersion internal virtual DeletePermissionVersionResponse DeletePermissionVersion(DeletePermissionVersionRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = DeletePermissionVersionRequestMarshaller.Instance; options.ResponseUnmarshaller = DeletePermissionVersionResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Deletes one version of a customer managed permission. The version you specify must /// not be attached to any resource share and must not be the default version for the /// permission. /// /// /// /// If a customer managed permission has the maximum of 5 versions, then you must delete /// at least one version before you can create another. /// /// /// Container for the necessary parameters to execute the DeletePermissionVersion service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the DeletePermissionVersion service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for DeletePermissionVersion Operation public virtual Task DeletePermissionVersionAsync(DeletePermissionVersionRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = DeletePermissionVersionRequestMarshaller.Instance; options.ResponseUnmarshaller = DeletePermissionVersionResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region DeleteResourceShare internal virtual DeleteResourceShareResponse DeleteResourceShare(DeleteResourceShareRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = DeleteResourceShareRequestMarshaller.Instance; options.ResponseUnmarshaller = DeleteResourceShareResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Deletes the specified resource share. /// /// /// /// This doesn't delete any of the resources that were associated with the resource share; /// it only stops the sharing of those resources through this resource share. /// /// /// /// Container for the necessary parameters to execute the DeleteResourceShare service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the DeleteResourceShare service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the requested operation isn't valid for the resource /// share in its current state. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for DeleteResourceShare Operation public virtual Task DeleteResourceShareAsync(DeleteResourceShareRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = DeleteResourceShareRequestMarshaller.Instance; options.ResponseUnmarshaller = DeleteResourceShareResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region DisassociateResourceShare internal virtual DisassociateResourceShareResponse DisassociateResourceShare(DisassociateResourceShareRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = DisassociateResourceShareRequestMarshaller.Instance; options.ResponseUnmarshaller = DisassociateResourceShareResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Removes the specified principals or resources from participating in the specified /// resource share. /// /// Container for the necessary parameters to execute the DisassociateResourceShare service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the DisassociateResourceShare service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the requested operation isn't valid for the resource /// share in its current state. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because it would exceed the limit for resource shares for your /// account. To view the limits for your Amazon Web Services account, see the RAM /// page in the Service Quotas console. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for DisassociateResourceShare Operation public virtual Task DisassociateResourceShareAsync(DisassociateResourceShareRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = DisassociateResourceShareRequestMarshaller.Instance; options.ResponseUnmarshaller = DisassociateResourceShareResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region DisassociateResourceSharePermission internal virtual DisassociateResourceSharePermissionResponse DisassociateResourceSharePermission(DisassociateResourceSharePermissionRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = DisassociateResourceSharePermissionRequestMarshaller.Instance; options.ResponseUnmarshaller = DisassociateResourceSharePermissionResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Removes a managed permission from a resource share. Permission changes take effect /// immediately. You can remove a managed permission from a resource share only if there /// are currently no resources of the relevant resource type currently attached to the /// resource share. /// /// Container for the necessary parameters to execute the DisassociateResourceSharePermission service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the DisassociateResourceSharePermission service method, as returned by RAM. /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the requested operation isn't valid for the resource /// share in its current state. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for DisassociateResourceSharePermission Operation public virtual Task DisassociateResourceSharePermissionAsync(DisassociateResourceSharePermissionRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = DisassociateResourceSharePermissionRequestMarshaller.Instance; options.ResponseUnmarshaller = DisassociateResourceSharePermissionResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region EnableSharingWithAwsOrganization internal virtual EnableSharingWithAwsOrganizationResponse EnableSharingWithAwsOrganization(EnableSharingWithAwsOrganizationRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = EnableSharingWithAwsOrganizationRequestMarshaller.Instance; options.ResponseUnmarshaller = EnableSharingWithAwsOrganizationResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Enables resource sharing within your organization in Organizations. This operation /// creates a service-linked role called AWSServiceRoleForResourceAccessManager /// that has the IAM managed policy named AWSResourceAccessManagerServiceRolePolicy attached. /// This role permits RAM to retrieve information about the organization and its structure. /// This lets you share resources with all of the accounts in the calling account's organization /// by specifying the organization ID, or all of the accounts in an organizational unit /// (OU) by specifying the OU ID. Until you enable sharing within the organization, you /// can specify only individual Amazon Web Services accounts, or for supported resource /// types, IAM roles and users. /// /// /// /// You must call this operation from an IAM role or user in the organization's management /// account. /// /// /// Container for the necessary parameters to execute the EnableSharingWithAwsOrganization service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the EnableSharingWithAwsOrganization service method, as returned by RAM. /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// REST API Reference for EnableSharingWithAwsOrganization Operation public virtual Task EnableSharingWithAwsOrganizationAsync(EnableSharingWithAwsOrganizationRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = EnableSharingWithAwsOrganizationRequestMarshaller.Instance; options.ResponseUnmarshaller = EnableSharingWithAwsOrganizationResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region GetPermission internal virtual GetPermissionResponse GetPermission(GetPermissionRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = GetPermissionRequestMarshaller.Instance; options.ResponseUnmarshaller = GetPermissionResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Retrieves the contents of a managed permission in JSON format. /// /// Container for the necessary parameters to execute the GetPermission service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the GetPermission service method, as returned by RAM. /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for GetPermission Operation public virtual Task GetPermissionAsync(GetPermissionRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = GetPermissionRequestMarshaller.Instance; options.ResponseUnmarshaller = GetPermissionResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region GetResourcePolicies internal virtual GetResourcePoliciesResponse GetResourcePolicies(GetResourcePoliciesRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = GetResourcePoliciesRequestMarshaller.Instance; options.ResponseUnmarshaller = GetResourcePoliciesResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Retrieves the resource policies for the specified resources that you own and have /// shared. /// /// Container for the necessary parameters to execute the GetResourcePolicies service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the GetResourcePolicies service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) was not found. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// REST API Reference for GetResourcePolicies Operation public virtual Task GetResourcePoliciesAsync(GetResourcePoliciesRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = GetResourcePoliciesRequestMarshaller.Instance; options.ResponseUnmarshaller = GetResourcePoliciesResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region GetResourceShareAssociations internal virtual GetResourceShareAssociationsResponse GetResourceShareAssociations(GetResourceShareAssociationsRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = GetResourceShareAssociationsRequestMarshaller.Instance; options.ResponseUnmarshaller = GetResourceShareAssociationsResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Retrieves the lists of resources and principals that associated for resource shares /// that you own. /// /// Container for the necessary parameters to execute the GetResourceShareAssociations service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the GetResourceShareAssociations service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for GetResourceShareAssociations Operation public virtual Task GetResourceShareAssociationsAsync(GetResourceShareAssociationsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = GetResourceShareAssociationsRequestMarshaller.Instance; options.ResponseUnmarshaller = GetResourceShareAssociationsResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region GetResourceShareInvitations internal virtual GetResourceShareInvitationsResponse GetResourceShareInvitations(GetResourceShareInvitationsRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = GetResourceShareInvitationsRequestMarshaller.Instance; options.ResponseUnmarshaller = GetResourceShareInvitationsResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Retrieves details about invitations that you have received for resource shares. /// /// Container for the necessary parameters to execute the GetResourceShareInvitations service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the GetResourceShareInvitations service method, as returned by RAM. /// /// The operation failed because the specified value for MaxResults isn't /// valid. /// /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) for an invitation was not found. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for GetResourceShareInvitations Operation public virtual Task GetResourceShareInvitationsAsync(GetResourceShareInvitationsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = GetResourceShareInvitationsRequestMarshaller.Instance; options.ResponseUnmarshaller = GetResourceShareInvitationsResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region GetResourceShares internal virtual GetResourceSharesResponse GetResourceShares(GetResourceSharesRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = GetResourceSharesRequestMarshaller.Instance; options.ResponseUnmarshaller = GetResourceSharesResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Retrieves details about the resource shares that you own or that are shared with you. /// /// Container for the necessary parameters to execute the GetResourceShares service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the GetResourceShares service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for GetResourceShares Operation public virtual Task GetResourceSharesAsync(GetResourceSharesRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = GetResourceSharesRequestMarshaller.Instance; options.ResponseUnmarshaller = GetResourceSharesResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region ListPendingInvitationResources internal virtual ListPendingInvitationResourcesResponse ListPendingInvitationResources(ListPendingInvitationResourcesRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ListPendingInvitationResourcesRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPendingInvitationResourcesResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Lists the resources in a resource share that is shared with you but for which the /// invitation is still PENDING. That means that you haven't accepted or /// rejected the invitation and the invitation hasn't expired. /// /// Container for the necessary parameters to execute the ListPendingInvitationResources service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the ListPendingInvitationResources service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because a required input parameter is missing. /// /// /// The operation failed because the specified invitation was already rejected. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) for an invitation was not found. /// /// /// The operation failed because the specified invitation is past its expiration date /// and time. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// REST API Reference for ListPendingInvitationResources Operation public virtual Task ListPendingInvitationResourcesAsync(ListPendingInvitationResourcesRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ListPendingInvitationResourcesRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPendingInvitationResourcesResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region ListPermissionAssociations internal virtual ListPermissionAssociationsResponse ListPermissionAssociations(ListPermissionAssociationsRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ListPermissionAssociationsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPermissionAssociationsResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Lists information about the managed permission and its associations to any resource /// shares that use this managed permission. This lets you see which resource shares use /// which versions of the specified managed permission. /// /// Container for the necessary parameters to execute the ListPermissionAssociations service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the ListPermissionAssociations service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// REST API Reference for ListPermissionAssociations Operation public virtual Task ListPermissionAssociationsAsync(ListPermissionAssociationsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ListPermissionAssociationsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPermissionAssociationsResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region ListPermissions internal virtual ListPermissionsResponse ListPermissions(ListPermissionsRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ListPermissionsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPermissionsResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Retrieves a list of available RAM permissions that you can use for the supported resource /// types. /// /// Container for the necessary parameters to execute the ListPermissions service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the ListPermissions service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// REST API Reference for ListPermissions Operation public virtual Task ListPermissionsAsync(ListPermissionsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ListPermissionsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPermissionsResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region ListPermissionVersions internal virtual ListPermissionVersionsResponse ListPermissionVersions(ListPermissionVersionsRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ListPermissionVersionsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPermissionVersionsResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Lists the available versions of the specified RAM permission. /// /// Container for the necessary parameters to execute the ListPermissionVersions service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the ListPermissionVersions service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for ListPermissionVersions Operation public virtual Task ListPermissionVersionsAsync(ListPermissionVersionsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ListPermissionVersionsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPermissionVersionsResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region ListPrincipals internal virtual ListPrincipalsResponse ListPrincipals(ListPrincipalsRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ListPrincipalsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPrincipalsResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Lists the principals that you are sharing resources with or that are sharing resources /// with you. /// /// Container for the necessary parameters to execute the ListPrincipals service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the ListPrincipals service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for ListPrincipals Operation public virtual Task ListPrincipalsAsync(ListPrincipalsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ListPrincipalsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPrincipalsResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region ListReplacePermissionAssociationsWork internal virtual ListReplacePermissionAssociationsWorkResponse ListReplacePermissionAssociationsWork(ListReplacePermissionAssociationsWorkRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ListReplacePermissionAssociationsWorkRequestMarshaller.Instance; options.ResponseUnmarshaller = ListReplacePermissionAssociationsWorkResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Retrieves the current status of the asynchronous tasks performed by RAM when you perform /// the ReplacePermissionAssociationsWork operation. /// /// Container for the necessary parameters to execute the ListReplacePermissionAssociationsWork service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the ListReplacePermissionAssociationsWork service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// REST API Reference for ListReplacePermissionAssociationsWork Operation public virtual Task ListReplacePermissionAssociationsWorkAsync(ListReplacePermissionAssociationsWorkRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ListReplacePermissionAssociationsWorkRequestMarshaller.Instance; options.ResponseUnmarshaller = ListReplacePermissionAssociationsWorkResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region ListResources internal virtual ListResourcesResponse ListResources(ListResourcesRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ListResourcesRequestMarshaller.Instance; options.ResponseUnmarshaller = ListResourcesResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Lists the resources that you added to a resource share or the resources that are shared /// with you. /// /// Container for the necessary parameters to execute the ListResources service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the ListResources service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified resource type isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for ListResources Operation public virtual Task ListResourcesAsync(ListResourcesRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ListResourcesRequestMarshaller.Instance; options.ResponseUnmarshaller = ListResourcesResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region ListResourceSharePermissions internal virtual ListResourceSharePermissionsResponse ListResourceSharePermissions(ListResourceSharePermissionsRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ListResourceSharePermissionsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListResourceSharePermissionsResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Lists the RAM permissions that are associated with a resource share. /// /// Container for the necessary parameters to execute the ListResourceSharePermissions service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the ListResourceSharePermissions service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for ListResourceSharePermissions Operation public virtual Task ListResourceSharePermissionsAsync(ListResourceSharePermissionsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ListResourceSharePermissionsRequestMarshaller.Instance; options.ResponseUnmarshaller = ListResourceSharePermissionsResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region ListResourceTypes internal virtual ListResourceTypesResponse ListResourceTypes(ListResourceTypesRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ListResourceTypesRequestMarshaller.Instance; options.ResponseUnmarshaller = ListResourceTypesResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Lists the resource types that can be shared by RAM. /// /// Container for the necessary parameters to execute the ListResourceTypes service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the ListResourceTypes service method, as returned by RAM. /// /// The operation failed because the specified value for NextToken isn't /// valid. You must specify a value you received in the NextToken response /// of a previous call to this operation. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// REST API Reference for ListResourceTypes Operation public virtual Task ListResourceTypesAsync(ListResourceTypesRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ListResourceTypesRequestMarshaller.Instance; options.ResponseUnmarshaller = ListResourceTypesResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region PromotePermissionCreatedFromPolicy internal virtual PromotePermissionCreatedFromPolicyResponse PromotePermissionCreatedFromPolicy(PromotePermissionCreatedFromPolicyRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = PromotePermissionCreatedFromPolicyRequestMarshaller.Instance; options.ResponseUnmarshaller = PromotePermissionCreatedFromPolicyResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// When you attach a resource-based policy to a resource, RAM automatically creates a /// resource share of featureSet=CREATED_FROM_POLICY with a /// managed permission that has the same IAM permissions as the original resource-based /// policy. However, this type of managed permission is visible to only the resource share /// owner, and the associated resource share can't be modified by using RAM. /// /// /// /// This operation creates a separate, fully manageable customer managed permission that /// has the same IAM permissions as the original resource-based policy. You can associate /// this customer managed permission to any resource shares. /// /// /// /// Before you use PromoteResourceShareCreatedFromPolicy, you should first run /// this operation to ensure that you have an appropriate customer managed permission /// that can be associated with the promoted resource share. /// ///
  • /// /// The original CREATED_FROM_POLICY policy isn't deleted, and resource shares /// using that original policy aren't automatically updated. /// ///
  • /// /// You can't modify a CREATED_FROM_POLICY resource share so you can't associate /// the new customer managed permission by using ReplacePermsissionAssociations. /// However, if you use PromoteResourceShareCreatedFromPolicy, that operation automatically /// associates the fully manageable customer managed permission to the newly promoted /// STANDARD resource share. /// ///
  • /// /// After you promote a resource share, if the original CREATED_FROM_POLICY /// managed permission has no other associations to A resource share, then RAM automatically /// deletes it. /// ///
///
/// Container for the necessary parameters to execute the PromotePermissionCreatedFromPolicy service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the PromotePermissionCreatedFromPolicy service method, as returned by RAM. /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because a required input parameter is missing. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for PromotePermissionCreatedFromPolicy Operation public virtual Task PromotePermissionCreatedFromPolicyAsync(PromotePermissionCreatedFromPolicyRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = PromotePermissionCreatedFromPolicyRequestMarshaller.Instance; options.ResponseUnmarshaller = PromotePermissionCreatedFromPolicyResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region PromoteResourceShareCreatedFromPolicy internal virtual PromoteResourceShareCreatedFromPolicyResponse PromoteResourceShareCreatedFromPolicy(PromoteResourceShareCreatedFromPolicyRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = PromoteResourceShareCreatedFromPolicyRequestMarshaller.Instance; options.ResponseUnmarshaller = PromoteResourceShareCreatedFromPolicyResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// When you attach a resource-based policy to a resource, RAM automatically creates a /// resource share of featureSet=CREATED_FROM_POLICY with a /// managed permission that has the same IAM permissions as the original resource-based /// policy. However, this type of managed permission is visible to only the resource share /// owner, and the associated resource share can't be modified by using RAM. /// /// /// /// This operation promotes the resource share to a STANDARD resource share /// that is fully manageable in RAM. When you promote a resource share, you can then manage /// the resource share in RAM and it becomes visible to all of the principals you shared /// it with. /// /// /// /// Before you perform this operation, you should first run PromotePermissionCreatedFromPolicyto /// ensure that you have an appropriate customer managed permission that can be associated /// with this resource share after its is promoted. If this operation can't find a managed /// permission that exactly matches the existing CREATED_FROM_POLICY permission, /// then this operation fails. /// /// /// /// Container for the necessary parameters to execute the PromoteResourceShareCreatedFromPolicy service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the PromoteResourceShareCreatedFromPolicy service method, as returned by RAM. /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the requested operation isn't valid for the resource /// share in its current state. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because a required input parameter is missing. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because it would exceed the limit for resource shares for your /// account. To view the limits for your Amazon Web Services account, see the RAM /// page in the Service Quotas console. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// /// There isn't an existing managed permission defined in RAM that has the same IAM permissions /// as the resource-based policy attached to the resource. You should first run PromotePermissionCreatedFromPolicy /// to create that managed permission. /// /// REST API Reference for PromoteResourceShareCreatedFromPolicy Operation public virtual Task PromoteResourceShareCreatedFromPolicyAsync(PromoteResourceShareCreatedFromPolicyRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = PromoteResourceShareCreatedFromPolicyRequestMarshaller.Instance; options.ResponseUnmarshaller = PromoteResourceShareCreatedFromPolicyResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region RejectResourceShareInvitation internal virtual RejectResourceShareInvitationResponse RejectResourceShareInvitation(RejectResourceShareInvitationRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = RejectResourceShareInvitationRequestMarshaller.Instance; options.ResponseUnmarshaller = RejectResourceShareInvitationResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Rejects an invitation to a resource share from another Amazon Web Services account. /// /// Container for the necessary parameters to execute the RejectResourceShareInvitation service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the RejectResourceShareInvitation service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the specified invitation was already accepted. /// /// /// The operation failed because the specified invitation was already rejected. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) for an invitation was not found. /// /// /// The operation failed because the specified invitation is past its expiration date /// and time. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// REST API Reference for RejectResourceShareInvitation Operation public virtual Task RejectResourceShareInvitationAsync(RejectResourceShareInvitationRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = RejectResourceShareInvitationRequestMarshaller.Instance; options.ResponseUnmarshaller = RejectResourceShareInvitationResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region ReplacePermissionAssociations internal virtual ReplacePermissionAssociationsResponse ReplacePermissionAssociations(ReplacePermissionAssociationsRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ReplacePermissionAssociationsRequestMarshaller.Instance; options.ResponseUnmarshaller = ReplacePermissionAssociationsResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Updates all resource shares that use a managed permission to a different managed permission. /// This operation always applies the default version of the target managed permission. /// You can optionally specify that the update applies to only resource shares that currently /// use a specified version. This enables you to update to the latest version, without /// changing the which managed permission is used. /// /// /// /// You can use this operation to update all of your resource shares to use the current /// default version of the permission by specifying the same value for the fromPermissionArn /// and toPermissionArn parameters. /// /// /// /// You can use the optional fromPermissionVersion parameter to update only /// those resources that use a specified version of the managed permission to the new /// managed permission. /// /// /// /// To successfully perform this operation, you must have permission to update the resource-based /// policy on all affected resource types. /// /// /// /// Container for the necessary parameters to execute the ReplacePermissionAssociations service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the ReplacePermissionAssociations service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for ReplacePermissionAssociations Operation public virtual Task ReplacePermissionAssociationsAsync(ReplacePermissionAssociationsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ReplacePermissionAssociationsRequestMarshaller.Instance; options.ResponseUnmarshaller = ReplacePermissionAssociationsResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region SetDefaultPermissionVersion internal virtual SetDefaultPermissionVersionResponse SetDefaultPermissionVersion(SetDefaultPermissionVersionRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = SetDefaultPermissionVersionRequestMarshaller.Instance; options.ResponseUnmarshaller = SetDefaultPermissionVersionResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Designates the specified version number as the default version for the specified customer /// managed permission. New resource shares automatically use this new default permission. /// Existing resource shares continue to use their original permission version, but you /// can use ReplacePermissionAssociations to update them. /// /// Container for the necessary parameters to execute the SetDefaultPermissionVersion service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the SetDefaultPermissionVersion service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for SetDefaultPermissionVersion Operation public virtual Task SetDefaultPermissionVersionAsync(SetDefaultPermissionVersionRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = SetDefaultPermissionVersionRequestMarshaller.Instance; options.ResponseUnmarshaller = SetDefaultPermissionVersionResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region TagResource internal virtual TagResourceResponse TagResource(TagResourceRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = TagResourceRequestMarshaller.Instance; options.ResponseUnmarshaller = TagResourceResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Adds the specified tag keys and values to a resource share or managed permission. /// If you choose a resource share, the tags are attached to only the resource share, /// not to the resources that are in the resource share. /// /// /// /// The tags on a managed permission are the same for all versions of the managed permission. /// /// /// Container for the necessary parameters to execute the TagResource service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the TagResource service method, as returned by RAM. /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) was not found. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because it would exceed the limit for tags for your Amazon Web /// Services account. /// /// /// The operation failed because the specified tag key is a reserved word and can't be /// used. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for TagResource Operation public virtual Task TagResourceAsync(TagResourceRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = TagResourceRequestMarshaller.Instance; options.ResponseUnmarshaller = TagResourceResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region UntagResource internal virtual UntagResourceResponse UntagResource(UntagResourceRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = UntagResourceRequestMarshaller.Instance; options.ResponseUnmarshaller = UntagResourceResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Removes the specified tag key and value pairs from the specified resource share or /// managed permission. /// /// Container for the necessary parameters to execute the UntagResource service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the UntagResource service method, as returned by RAM. /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for UntagResource Operation public virtual Task UntagResourceAsync(UntagResourceRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = UntagResourceRequestMarshaller.Instance; options.ResponseUnmarshaller = UntagResourceResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion #region UpdateResourceShare internal virtual UpdateResourceShareResponse UpdateResourceShare(UpdateResourceShareRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = UpdateResourceShareRequestMarshaller.Instance; options.ResponseUnmarshaller = UpdateResourceShareResponseUnmarshaller.Instance; return Invoke(request, options); } /// /// Modifies some of the properties of the specified resource share. /// /// Container for the necessary parameters to execute the UpdateResourceShare service method. /// /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// /// /// The response from the UpdateResourceShare service method, as returned by RAM. /// /// The operation failed because the client token input parameter matched one that was /// used with a previous call to the operation, but at least one of the other input parameters /// is different from the previous call. /// /// /// The operation failed because the specified client token isn't valid. /// /// /// The operation failed because a parameter you specified isn't valid. /// /// /// The operation failed because the specified Amazon /// Resource Name (ARN) has a format that isn't valid. /// /// /// The operation failed because a required input parameter is missing. /// /// /// The operation failed because the requested operation isn't permitted. /// /// /// The operation failed because the service could not respond to the request due to an /// internal problem. Try again later. /// /// /// The operation failed because the service isn't available. Try again later. /// /// /// The operation failed because a specified resource couldn't be found. /// /// REST API Reference for UpdateResourceShare Operation public virtual Task UpdateResourceShareAsync(UpdateResourceShareRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = UpdateResourceShareRequestMarshaller.Instance; options.ResponseUnmarshaller = UpdateResourceShareResponseUnmarshaller.Instance; return InvokeAsync(request, options, cancellationToken); } #endregion } }