Class: Aws::Repostspace::Client
- Inherits:
-
Seahorse::Client::Base
- Object
- Seahorse::Client::Base
- Aws::Repostspace::Client
- Includes:
- ClientStubs
- Defined in:
- lib/aws-sdk-repostspace/client.rb,
sig/client.rbs
Overview
An API client for Repostspace. To construct a client, you need to configure a :region and :credentials.
client = Aws::Repostspace::Client.new(
region: region_name,
credentials: credentials,
# ...
)
For details on configuring region and credentials see the developer guide.
See #initialize for a full list of supported configuration options.
Defined Under Namespace
Modules: _BatchAddChannelRoleToAccessorsResponseSuccess, _BatchAddRoleResponseSuccess, _BatchRemoveChannelRoleFromAccessorsResponseSuccess, _BatchRemoveRoleResponseSuccess, _CreateChannelResponseSuccess, _CreateSpaceResponseSuccess, _GetChannelResponseSuccess, _GetSpaceResponseSuccess, _ListChannelsResponseSuccess, _ListSpacesResponseSuccess, _ListTagsForResourceResponseSuccess, _TagResourceResponseSuccess, _UntagResourceResponseSuccess, _UpdateChannelResponseSuccess
Class Attribute Summary collapse
- .identifier ⇒ Object readonly private
API Operations collapse
-
#batch_add_channel_role_to_accessors(params = {}) ⇒ Types::BatchAddChannelRoleToAccessorsOutput
Add role to multiple users or groups in a private re:Post channel.
-
#batch_add_role(params = {}) ⇒ Types::BatchAddRoleOutput
Add a role to multiple users or groups in a private re:Post.
-
#batch_remove_channel_role_from_accessors(params = {}) ⇒ Types::BatchRemoveChannelRoleFromAccessorsOutput
Remove a role from multiple users or groups in a private re:Post channel.
-
#batch_remove_role(params = {}) ⇒ Types::BatchRemoveRoleOutput
Remove a role from multiple users or groups in a private re:Post.
-
#create_channel(params = {}) ⇒ Types::CreateChannelOutput
Creates a channel in an AWS re:Post Private private re:Post.
-
#create_space(params = {}) ⇒ Types::CreateSpaceOutput
Creates an AWS re:Post Private private re:Post.
-
#delete_space(params = {}) ⇒ Struct
Deletes an AWS re:Post Private private re:Post.
-
#deregister_admin(params = {}) ⇒ Struct
Removes the user or group from the list of administrators of the private re:Post.
-
#get_channel(params = {}) ⇒ Types::GetChannelOutput
Displays information about a channel in a private re:Post.
-
#get_space(params = {}) ⇒ Types::GetSpaceOutput
Displays information about the AWS re:Post Private private re:Post.
-
#list_channels(params = {}) ⇒ Types::ListChannelsOutput
Returns the list of channel within a private re:Post with some information about each channel.
-
#list_spaces(params = {}) ⇒ Types::ListSpacesOutput
Returns a list of AWS re:Post Private private re:Posts in the account with some information about each private re:Post.
-
#list_tags_for_resource(params = {}) ⇒ Types::ListTagsForResourceResponse
Returns the tags that are associated with the AWS re:Post Private resource specified by the resourceArn.
-
#register_admin(params = {}) ⇒ Struct
Adds a user or group to the list of administrators of the private re:Post.
-
#send_invites(params = {}) ⇒ Struct
Sends an invitation email to selected users and groups.
-
#tag_resource(params = {}) ⇒ Struct
Associates tags with an AWS re:Post Private resource.
-
#untag_resource(params = {}) ⇒ Struct
Removes the association of the tag with the AWS re:Post Private resource.
-
#update_channel(params = {}) ⇒ Struct
Modifies an existing channel.
-
#update_space(params = {}) ⇒ Struct
Modifies an existing AWS re:Post Private private re:Post.
Class Method Summary collapse
- .errors_module ⇒ Object private
- .new ⇒ Object
Instance Method Summary collapse
- #build_request(operation_name, params = {}) ⇒ Object private
-
#initialize(options) ⇒ Client
constructor
A new instance of Client.
-
#wait_until(waiter_name, params = {}, options = {}) {|w.waiter| ... } ⇒ Boolean
Polls an API operation until a resource enters a desired state.
- #waiter_names ⇒ Object deprecated private Deprecated.
Constructor Details
#initialize(options) ⇒ Client
Returns a new instance of Client.
471 472 473 |
# File 'lib/aws-sdk-repostspace/client.rb', line 471 def initialize(*args) super end |
Class Attribute Details
.identifier ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1598 1599 1600 |
# File 'lib/aws-sdk-repostspace/client.rb', line 1598 def identifier @identifier end |
Class Method Details
.errors_module ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1601 1602 1603 |
# File 'lib/aws-sdk-repostspace/client.rb', line 1601 def errors_module Errors end |
.new ⇒ Object
14 |
# File 'sig/client.rbs', line 14
def self.new: (
|
Instance Method Details
#batch_add_channel_role_to_accessors(params = {}) ⇒ Types::BatchAddChannelRoleToAccessorsOutput
Add role to multiple users or groups in a private re:Post channel.
87 |
# File 'sig/client.rbs', line 87
def batch_add_channel_role_to_accessors: (
|
#batch_add_role(params = {}) ⇒ Types::BatchAddRoleOutput
Add a role to multiple users or groups in a private re:Post.
101 |
# File 'sig/client.rbs', line 101
def batch_add_role: (
|
#batch_remove_channel_role_from_accessors(params = {}) ⇒ Types::BatchRemoveChannelRoleFromAccessorsOutput
Remove a role from multiple users or groups in a private re:Post channel.
114 |
# File 'sig/client.rbs', line 114
def batch_remove_channel_role_from_accessors: (
|
#batch_remove_role(params = {}) ⇒ Types::BatchRemoveRoleOutput
Remove a role from multiple users or groups in a private re:Post.
128 |
# File 'sig/client.rbs', line 128
def batch_remove_role: (
|
#build_request(operation_name, params = {}) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 |
# File 'lib/aws-sdk-repostspace/client.rb', line 1452 def build_request(operation_name, params = {}) handlers = @handlers.for(operation_name) tracer = config.telemetry_provider.tracer_provider.tracer( Aws::Telemetry.module_to_tracer_name('Aws::Repostspace') ) context = Seahorse::Client::RequestContext.new( operation_name: operation_name, operation: config.api.operation(operation_name), client: self, params: params, config: config, tracer: tracer ) context[:gem_name] = 'aws-sdk-repostspace' context[:gem_version] = '1.39.0' Seahorse::Client::Request.new(handlers, context) end |
#create_channel(params = {}) ⇒ Types::CreateChannelOutput
Creates a channel in an AWS re:Post Private private re:Post.
140 |
# File 'sig/client.rbs', line 140
def create_channel: (
|
#create_space(params = {}) ⇒ Types::CreateSpaceOutput
Creates an AWS re:Post Private private re:Post.
152 |
# File 'sig/client.rbs', line 152
def create_space: (
|
#delete_space(params = {}) ⇒ Struct
Deletes an AWS re:Post Private private re:Post.
168 |
# File 'sig/client.rbs', line 168
def delete_space: (
|
#deregister_admin(params = {}) ⇒ Struct
Removes the user or group from the list of administrators of the private re:Post.
174 |
# File 'sig/client.rbs', line 174
def deregister_admin: (
|
#get_channel(params = {}) ⇒ Types::GetChannelOutput
Displays information about a channel in a private re:Post.
The following waiters are defined for this operation (see #wait_until for detailed usage):
* channel_created
* channel_deleted
192 |
# File 'sig/client.rbs', line 192
def get_channel: (
|
#get_space(params = {}) ⇒ Types::GetSpaceOutput
Displays information about the AWS re:Post Private private re:Post.
The following waiters are defined for this operation (see #wait_until for detailed usage):
* space_created
* space_deleted
226 |
# File 'sig/client.rbs', line 226
def get_space: (
|
#list_channels(params = {}) ⇒ Types::ListChannelsOutput
Returns the list of channel within a private re:Post with some information about each channel.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
237 |
# File 'sig/client.rbs', line 237
def list_channels: (
|
#list_spaces(params = {}) ⇒ Types::ListSpacesOutput
Returns a list of AWS re:Post Private private re:Posts in the account with some information about each private re:Post.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
250 |
# File 'sig/client.rbs', line 250
def list_spaces: (
|
#list_tags_for_resource(params = {}) ⇒ Types::ListTagsForResourceResponse
Returns the tags that are associated with the AWS re:Post Private resource specified by the resourceArn. The only resource that can be tagged is a private re:Post.
261 |
# File 'sig/client.rbs', line 261
def list_tags_for_resource: (
|
#register_admin(params = {}) ⇒ Struct
Adds a user or group to the list of administrators of the private re:Post.
267 |
# File 'sig/client.rbs', line 267
def register_admin: (
|
#send_invites(params = {}) ⇒ Struct
Sends an invitation email to selected users and groups.
274 |
# File 'sig/client.rbs', line 274
def send_invites: (
|
#tag_resource(params = {}) ⇒ Struct
Associates tags with an AWS re:Post Private resource. Currently, the only resource that can be tagged is the private re:Post. If you specify a new tag key for the resource, the tag is appended to the list of tags that are associated with the resource. If you specify a tag key that’s already associated with the resource, the new tag value that you specify replaces the previous value for that tag.
286 |
# File 'sig/client.rbs', line 286
def tag_resource: (
|
#untag_resource(params = {}) ⇒ Struct
Removes the association of the tag with the AWS re:Post Private resource.
296 |
# File 'sig/client.rbs', line 296
def untag_resource: (
|
#update_channel(params = {}) ⇒ Struct
Modifies an existing channel.
306 |
# File 'sig/client.rbs', line 306
def update_channel: (
|
#update_space(params = {}) ⇒ Struct
Modifies an existing AWS re:Post Private private re:Post.
315 |
# File 'sig/client.rbs', line 315
def update_space: (
|
#wait_until(waiter_name, params = {}, options = {}) {|w.waiter| ... } ⇒ Boolean
Polls an API operation until a resource enters a desired state.
Basic Usage
A waiter will call an API operation until:
- It is successful
- It enters a terminal state
- It makes the maximum number of attempts
In between attempts, the waiter will sleep.
# polls in a loop, sleeping between attempts
client.wait_until(waiter_name, params)
Configuration
You can configure the maximum number of polling attempts, and the delay (in seconds) between each polling attempt. You can pass configuration as the final arguments hash.
# poll for ~25 seconds
client.wait_until(waiter_name, params, {
max_attempts: 5,
delay: 5,
})
Callbacks
You can be notified before each polling attempt and before each
delay. If you throw :success or :failure from these callbacks,
it will terminate the waiter.
started_at = Time.now
client.wait_until(waiter_name, params, {
# disable max attempts
max_attempts: nil,
# poll for 1 hour, instead of a number of attempts
before_wait: -> (attempts, response) do
throw :failure if Time.now - started_at > 3600
end
})
Handling Errors
When a waiter is unsuccessful, it will raise an error. All of the failure errors extend from Waiters::Errors::WaiterFailed.
begin
client.wait_until(...)
rescue Aws::Waiters::Errors::WaiterFailed
# resource did not enter the desired state in time
end
Valid Waiters
The following table lists the valid waiter names, the operations they call,
and the default :delay and :max_attempts values.
| waiter_name | params | :delay | :max_attempts |
|---|---|---|---|
| channel_created | #get_channel | 2 | 60 |
| channel_deleted | #get_channel | 2 | 60 |
| space_created | #get_space | 300 | 24 |
| space_deleted | #get_space | 300 | 24 |
328 |
# File 'sig/client.rbs', line 328
def wait_until: (:channel_created waiter_name,
|
#waiter_names ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1569 1570 1571 |
# File 'lib/aws-sdk-repostspace/client.rb', line 1569 def waiter_names waiters.keys end |