aws-sdk-transfer 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/lib/aws-sdk-transfer.rb +47 -0
- data/lib/aws-sdk-transfer/client.rb +1067 -0
- data/lib/aws-sdk-transfer/client_api.rb +511 -0
- data/lib/aws-sdk-transfer/customizations.rb +0 -0
- data/lib/aws-sdk-transfer/errors.rb +14 -0
- data/lib/aws-sdk-transfer/resource.rb +23 -0
- data/lib/aws-sdk-transfer/types.rb +1134 -0
- metadata +88 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 2ce5d4632753945671ecf842f479f3f6d61a684f
|
4
|
+
data.tar.gz: 270b1987e90ccb94ec661ea75544cde0faca20ce
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 18f792173bb1d0313e622ae188787f76b25be249f18805d580b9d4501c2665944dce251ce120f311bad6c5cc5903d570a7a0d08a3bae12c061fd4ace4a3e8267
|
7
|
+
data.tar.gz: 8f0b327ff6e745479dceac85620c83933975c7117bf51d213d7c556efc3d429bf322b896f731592ae2f30b9c12d9179441d68ce3ae66c3be14f0bb5f5237ce2e
|
@@ -0,0 +1,47 @@
|
|
1
|
+
# WARNING ABOUT GENERATED CODE
|
2
|
+
#
|
3
|
+
# This file is generated. See the contributing guide for more information:
|
4
|
+
# https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
|
5
|
+
#
|
6
|
+
# WARNING ABOUT GENERATED CODE
|
7
|
+
|
8
|
+
require 'aws-sdk-core'
|
9
|
+
require 'aws-sigv4'
|
10
|
+
|
11
|
+
require_relative 'aws-sdk-transfer/types'
|
12
|
+
require_relative 'aws-sdk-transfer/client_api'
|
13
|
+
require_relative 'aws-sdk-transfer/client'
|
14
|
+
require_relative 'aws-sdk-transfer/errors'
|
15
|
+
require_relative 'aws-sdk-transfer/resource'
|
16
|
+
require_relative 'aws-sdk-transfer/customizations'
|
17
|
+
|
18
|
+
# This module provides support for AWS Transfer for SFTP. This module is available in the
|
19
|
+
# `aws-sdk-transfer` gem.
|
20
|
+
#
|
21
|
+
# # Client
|
22
|
+
#
|
23
|
+
# The {Client} class provides one method for each API operation. Operation
|
24
|
+
# methods each accept a hash of request parameters and return a response
|
25
|
+
# structure.
|
26
|
+
#
|
27
|
+
# See {Client} for more information.
|
28
|
+
#
|
29
|
+
# # Errors
|
30
|
+
#
|
31
|
+
# Errors returned from AWS Transfer for SFTP all
|
32
|
+
# extend {Errors::ServiceError}.
|
33
|
+
#
|
34
|
+
# begin
|
35
|
+
# # do stuff
|
36
|
+
# rescue Aws::Transfer::Errors::ServiceError
|
37
|
+
# # rescues all service API errors
|
38
|
+
# end
|
39
|
+
#
|
40
|
+
# See {Errors} for more information.
|
41
|
+
#
|
42
|
+
# @service
|
43
|
+
module Aws::Transfer
|
44
|
+
|
45
|
+
GEM_VERSION = '1.0.0'
|
46
|
+
|
47
|
+
end
|
@@ -0,0 +1,1067 @@
|
|
1
|
+
# WARNING ABOUT GENERATED CODE
|
2
|
+
#
|
3
|
+
# This file is generated. See the contributing guide for more information:
|
4
|
+
# https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
|
5
|
+
#
|
6
|
+
# WARNING ABOUT GENERATED CODE
|
7
|
+
|
8
|
+
require 'seahorse/client/plugins/content_length.rb'
|
9
|
+
require 'aws-sdk-core/plugins/credentials_configuration.rb'
|
10
|
+
require 'aws-sdk-core/plugins/logging.rb'
|
11
|
+
require 'aws-sdk-core/plugins/param_converter.rb'
|
12
|
+
require 'aws-sdk-core/plugins/param_validator.rb'
|
13
|
+
require 'aws-sdk-core/plugins/user_agent.rb'
|
14
|
+
require 'aws-sdk-core/plugins/helpful_socket_errors.rb'
|
15
|
+
require 'aws-sdk-core/plugins/retry_errors.rb'
|
16
|
+
require 'aws-sdk-core/plugins/global_configuration.rb'
|
17
|
+
require 'aws-sdk-core/plugins/regional_endpoint.rb'
|
18
|
+
require 'aws-sdk-core/plugins/endpoint_discovery.rb'
|
19
|
+
require 'aws-sdk-core/plugins/endpoint_pattern.rb'
|
20
|
+
require 'aws-sdk-core/plugins/response_paging.rb'
|
21
|
+
require 'aws-sdk-core/plugins/stub_responses.rb'
|
22
|
+
require 'aws-sdk-core/plugins/idempotency_token.rb'
|
23
|
+
require 'aws-sdk-core/plugins/jsonvalue_converter.rb'
|
24
|
+
require 'aws-sdk-core/plugins/client_metrics_plugin.rb'
|
25
|
+
require 'aws-sdk-core/plugins/client_metrics_send_plugin.rb'
|
26
|
+
require 'aws-sdk-core/plugins/signature_v4.rb'
|
27
|
+
require 'aws-sdk-core/plugins/protocols/json_rpc.rb'
|
28
|
+
|
29
|
+
Aws::Plugins::GlobalConfiguration.add_identifier(:transfer)
|
30
|
+
|
31
|
+
module Aws::Transfer
|
32
|
+
class Client < Seahorse::Client::Base
|
33
|
+
|
34
|
+
include Aws::ClientStubs
|
35
|
+
|
36
|
+
@identifier = :transfer
|
37
|
+
|
38
|
+
set_api(ClientApi::API)
|
39
|
+
|
40
|
+
add_plugin(Seahorse::Client::Plugins::ContentLength)
|
41
|
+
add_plugin(Aws::Plugins::CredentialsConfiguration)
|
42
|
+
add_plugin(Aws::Plugins::Logging)
|
43
|
+
add_plugin(Aws::Plugins::ParamConverter)
|
44
|
+
add_plugin(Aws::Plugins::ParamValidator)
|
45
|
+
add_plugin(Aws::Plugins::UserAgent)
|
46
|
+
add_plugin(Aws::Plugins::HelpfulSocketErrors)
|
47
|
+
add_plugin(Aws::Plugins::RetryErrors)
|
48
|
+
add_plugin(Aws::Plugins::GlobalConfiguration)
|
49
|
+
add_plugin(Aws::Plugins::RegionalEndpoint)
|
50
|
+
add_plugin(Aws::Plugins::EndpointDiscovery)
|
51
|
+
add_plugin(Aws::Plugins::EndpointPattern)
|
52
|
+
add_plugin(Aws::Plugins::ResponsePaging)
|
53
|
+
add_plugin(Aws::Plugins::StubResponses)
|
54
|
+
add_plugin(Aws::Plugins::IdempotencyToken)
|
55
|
+
add_plugin(Aws::Plugins::JsonvalueConverter)
|
56
|
+
add_plugin(Aws::Plugins::ClientMetricsPlugin)
|
57
|
+
add_plugin(Aws::Plugins::ClientMetricsSendPlugin)
|
58
|
+
add_plugin(Aws::Plugins::SignatureV4)
|
59
|
+
add_plugin(Aws::Plugins::Protocols::JsonRpc)
|
60
|
+
|
61
|
+
# @overload initialize(options)
|
62
|
+
# @param [Hash] options
|
63
|
+
# @option options [required, Aws::CredentialProvider] :credentials
|
64
|
+
# Your AWS credentials. This can be an instance of any one of the
|
65
|
+
# following classes:
|
66
|
+
#
|
67
|
+
# * `Aws::Credentials` - Used for configuring static, non-refreshing
|
68
|
+
# credentials.
|
69
|
+
#
|
70
|
+
# * `Aws::InstanceProfileCredentials` - Used for loading credentials
|
71
|
+
# from an EC2 IMDS on an EC2 instance.
|
72
|
+
#
|
73
|
+
# * `Aws::SharedCredentials` - Used for loading credentials from a
|
74
|
+
# shared file, such as `~/.aws/config`.
|
75
|
+
#
|
76
|
+
# * `Aws::AssumeRoleCredentials` - Used when you need to assume a role.
|
77
|
+
#
|
78
|
+
# When `:credentials` are not configured directly, the following
|
79
|
+
# locations will be searched for credentials:
|
80
|
+
#
|
81
|
+
# * `Aws.config[:credentials]`
|
82
|
+
# * The `:access_key_id`, `:secret_access_key`, and `:session_token` options.
|
83
|
+
# * ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY']
|
84
|
+
# * `~/.aws/credentials`
|
85
|
+
# * `~/.aws/config`
|
86
|
+
# * EC2 IMDS instance profile - When used by default, the timeouts are
|
87
|
+
# very aggressive. Construct and pass an instance of
|
88
|
+
# `Aws::InstanceProfileCredentails` to enable retries and extended
|
89
|
+
# timeouts.
|
90
|
+
#
|
91
|
+
# @option options [required, String] :region
|
92
|
+
# The AWS region to connect to. The configured `:region` is
|
93
|
+
# used to determine the service `:endpoint`. When not passed,
|
94
|
+
# a default `:region` is search for in the following locations:
|
95
|
+
#
|
96
|
+
# * `Aws.config[:region]`
|
97
|
+
# * `ENV['AWS_REGION']`
|
98
|
+
# * `ENV['AMAZON_REGION']`
|
99
|
+
# * `ENV['AWS_DEFAULT_REGION']`
|
100
|
+
# * `~/.aws/credentials`
|
101
|
+
# * `~/.aws/config`
|
102
|
+
#
|
103
|
+
# @option options [String] :access_key_id
|
104
|
+
#
|
105
|
+
# @option options [Boolean] :active_endpoint_cache (false)
|
106
|
+
# When set to `true`, a thread polling for endpoints will be running in
|
107
|
+
# the background every 60 secs (default). Defaults to `false`.
|
108
|
+
#
|
109
|
+
# @option options [Boolean] :client_side_monitoring (false)
|
110
|
+
# When `true`, client-side metrics will be collected for all API requests from
|
111
|
+
# this client.
|
112
|
+
#
|
113
|
+
# @option options [String] :client_side_monitoring_client_id ("")
|
114
|
+
# Allows you to provide an identifier for this client which will be attached to
|
115
|
+
# all generated client side metrics. Defaults to an empty string.
|
116
|
+
#
|
117
|
+
# @option options [Integer] :client_side_monitoring_port (31000)
|
118
|
+
# Required for publishing client metrics. The port that the client side monitoring
|
119
|
+
# agent is running on, where client metrics will be published via UDP.
|
120
|
+
#
|
121
|
+
# @option options [Aws::ClientSideMonitoring::Publisher] :client_side_monitoring_publisher (Aws::ClientSideMonitoring::Publisher)
|
122
|
+
# Allows you to provide a custom client-side monitoring publisher class. By default,
|
123
|
+
# will use the Client Side Monitoring Agent Publisher.
|
124
|
+
#
|
125
|
+
# @option options [Boolean] :convert_params (true)
|
126
|
+
# When `true`, an attempt is made to coerce request parameters into
|
127
|
+
# the required types.
|
128
|
+
#
|
129
|
+
# @option options [Boolean] :disable_host_prefix_injection (false)
|
130
|
+
# Set to true to disable SDK automatically adding host prefix
|
131
|
+
# to default service endpoint when available.
|
132
|
+
#
|
133
|
+
# @option options [String] :endpoint
|
134
|
+
# The client endpoint is normally constructed from the `:region`
|
135
|
+
# option. You should only configure an `:endpoint` when connecting
|
136
|
+
# to test endpoints. This should be avalid HTTP(S) URI.
|
137
|
+
#
|
138
|
+
# @option options [Integer] :endpoint_cache_max_entries (1000)
|
139
|
+
# Used for the maximum size limit of the LRU cache storing endpoints data
|
140
|
+
# for endpoint discovery enabled operations. Defaults to 1000.
|
141
|
+
#
|
142
|
+
# @option options [Integer] :endpoint_cache_max_threads (10)
|
143
|
+
# Used for the maximum threads in use for polling endpoints to be cached, defaults to 10.
|
144
|
+
#
|
145
|
+
# @option options [Integer] :endpoint_cache_poll_interval (60)
|
146
|
+
# When :endpoint_discovery and :active_endpoint_cache is enabled,
|
147
|
+
# Use this option to config the time interval in seconds for making
|
148
|
+
# requests fetching endpoints information. Defaults to 60 sec.
|
149
|
+
#
|
150
|
+
# @option options [Boolean] :endpoint_discovery (false)
|
151
|
+
# When set to `true`, endpoint discovery will be enabled for operations when available. Defaults to `false`.
|
152
|
+
#
|
153
|
+
# @option options [Aws::Log::Formatter] :log_formatter (Aws::Log::Formatter.default)
|
154
|
+
# The log formatter.
|
155
|
+
#
|
156
|
+
# @option options [Symbol] :log_level (:info)
|
157
|
+
# The log level to send messages to the `:logger` at.
|
158
|
+
#
|
159
|
+
# @option options [Logger] :logger
|
160
|
+
# The Logger instance to send log messages to. If this option
|
161
|
+
# is not set, logging will be disabled.
|
162
|
+
#
|
163
|
+
# @option options [String] :profile ("default")
|
164
|
+
# Used when loading credentials from the shared credentials file
|
165
|
+
# at HOME/.aws/credentials. When not specified, 'default' is used.
|
166
|
+
#
|
167
|
+
# @option options [Float] :retry_base_delay (0.3)
|
168
|
+
# The base delay in seconds used by the default backoff function.
|
169
|
+
#
|
170
|
+
# @option options [Symbol] :retry_jitter (:none)
|
171
|
+
# A delay randomiser function used by the default backoff function. Some predefined functions can be referenced by name - :none, :equal, :full, otherwise a Proc that takes and returns a number.
|
172
|
+
#
|
173
|
+
# @see https://www.awsarchitectureblog.com/2015/03/backoff.html
|
174
|
+
#
|
175
|
+
# @option options [Integer] :retry_limit (3)
|
176
|
+
# The maximum number of times to retry failed requests. Only
|
177
|
+
# ~ 500 level server errors and certain ~ 400 level client errors
|
178
|
+
# are retried. Generally, these are throttling errors, data
|
179
|
+
# checksum errors, networking errors, timeout errors and auth
|
180
|
+
# errors from expired credentials.
|
181
|
+
#
|
182
|
+
# @option options [Integer] :retry_max_delay (0)
|
183
|
+
# The maximum number of seconds to delay between retries (0 for no limit) used by the default backoff function.
|
184
|
+
#
|
185
|
+
# @option options [String] :secret_access_key
|
186
|
+
#
|
187
|
+
# @option options [String] :session_token
|
188
|
+
#
|
189
|
+
# @option options [Boolean] :simple_json (false)
|
190
|
+
# Disables request parameter conversion, validation, and formatting.
|
191
|
+
# Also disable response data type conversions. This option is useful
|
192
|
+
# when you want to ensure the highest level of performance by
|
193
|
+
# avoiding overhead of walking request parameters and response data
|
194
|
+
# structures.
|
195
|
+
#
|
196
|
+
# When `:simple_json` is enabled, the request parameters hash must
|
197
|
+
# be formatted exactly as the DynamoDB API expects.
|
198
|
+
#
|
199
|
+
# @option options [Boolean] :stub_responses (false)
|
200
|
+
# Causes the client to return stubbed responses. By default
|
201
|
+
# fake responses are generated and returned. You can specify
|
202
|
+
# the response data to return or errors to raise by calling
|
203
|
+
# {ClientStubs#stub_responses}. See {ClientStubs} for more information.
|
204
|
+
#
|
205
|
+
# ** Please note ** When response stubbing is enabled, no HTTP
|
206
|
+
# requests are made, and retries are disabled.
|
207
|
+
#
|
208
|
+
# @option options [Boolean] :validate_params (true)
|
209
|
+
# When `true`, request parameters are validated before
|
210
|
+
# sending the request.
|
211
|
+
#
|
212
|
+
def initialize(*args)
|
213
|
+
super
|
214
|
+
end
|
215
|
+
|
216
|
+
# @!group API Operations
|
217
|
+
|
218
|
+
# Instantiates an autoscaling virtual server based on Secure File
|
219
|
+
# Transfer Protocol (SFTP) in AWS. The call returns the `ServerId`
|
220
|
+
# property assigned by the service to the newly created server.
|
221
|
+
# Reference this `ServerId` property when you make updates to your
|
222
|
+
# server, or work with users.
|
223
|
+
#
|
224
|
+
# The response returns the `ServerId` value for the newly created
|
225
|
+
# server.
|
226
|
+
#
|
227
|
+
# @option params [Types::IdentityProviderDetails] :identity_provider_details
|
228
|
+
# An array containing all of the information required to call a
|
229
|
+
# customer-supplied authentication API. This parameter is not required
|
230
|
+
# when the `IdentityProviderType` value of server that is created uses
|
231
|
+
# the `SERVICE_MANAGED` authentication method.
|
232
|
+
#
|
233
|
+
# @option params [String] :identity_provider_type
|
234
|
+
# The mode of authentication enabled for this service. The default value
|
235
|
+
# is `SERVICE_MANAGED`, which allows you to store and access SFTP user
|
236
|
+
# credentials within the service. An `IdentityProviderType` value of
|
237
|
+
# `API_GATEWAY` indicates that user authentication requires a call to an
|
238
|
+
# API Gateway endpoint URL provided by you to integrate an identity
|
239
|
+
# provider of your choice.
|
240
|
+
#
|
241
|
+
# @option params [String] :logging_role
|
242
|
+
# A value that allows the service to write your SFTP users’ activity to
|
243
|
+
# your Amazon CloudWatch logs for monitoring and auditing purposes.
|
244
|
+
#
|
245
|
+
# @option params [Array<Types::Tag>] :tags
|
246
|
+
# Key-value pairs that can be used to group and search for servers.
|
247
|
+
#
|
248
|
+
# @return [Types::CreateServerResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
249
|
+
#
|
250
|
+
# * {Types::CreateServerResponse#server_id #server_id} => String
|
251
|
+
#
|
252
|
+
# @example Request syntax with placeholder values
|
253
|
+
#
|
254
|
+
# resp = client.create_server({
|
255
|
+
# identity_provider_details: {
|
256
|
+
# url: "Url",
|
257
|
+
# invocation_role: "Role",
|
258
|
+
# },
|
259
|
+
# identity_provider_type: "SERVICE_MANAGED", # accepts SERVICE_MANAGED, API_GATEWAY
|
260
|
+
# logging_role: "Role",
|
261
|
+
# tags: [
|
262
|
+
# {
|
263
|
+
# key: "TagKey", # required
|
264
|
+
# value: "TagValue", # required
|
265
|
+
# },
|
266
|
+
# ],
|
267
|
+
# })
|
268
|
+
#
|
269
|
+
# @example Response structure
|
270
|
+
#
|
271
|
+
# resp.server_id #=> String
|
272
|
+
#
|
273
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/CreateServer AWS API Documentation
|
274
|
+
#
|
275
|
+
# @overload create_server(params = {})
|
276
|
+
# @param [Hash] params ({})
|
277
|
+
def create_server(params = {}, options = {})
|
278
|
+
req = build_request(:create_server, params)
|
279
|
+
req.send_request(options)
|
280
|
+
end
|
281
|
+
|
282
|
+
# Adds a user and associate them with an existing Secure File Transfer
|
283
|
+
# Protocol (SFTP) server. Using parameters for `CreateUser`, you can
|
284
|
+
# specify the user name, set the home directory, store the user's
|
285
|
+
# public key, and assign the user's AWS Identity and Access Management
|
286
|
+
# (IAM) role. You can also optionally add a scope-down policy, and
|
287
|
+
# assign metadata with tags that can be used to group and search for
|
288
|
+
# users.
|
289
|
+
#
|
290
|
+
# The response returns the `UserName` and `ServerId` values of the new
|
291
|
+
# user for that server.
|
292
|
+
#
|
293
|
+
# @option params [String] :home_directory
|
294
|
+
# The landing directory (folder) for a user when they log in to the
|
295
|
+
# server using their SFTP client. An example is `/home/username `.
|
296
|
+
#
|
297
|
+
# @option params [String] :policy
|
298
|
+
# A scope-down policy for your user so you can use the same IAM role
|
299
|
+
# across multiple users. This policy scopes down user access to portions
|
300
|
+
# of their Amazon S3 bucket. Variables you can use inside this policy
|
301
|
+
# include `$\{Transfer:UserName\}`, `$\{Transfer:HomeDirectory\}`, and
|
302
|
+
# `$\{Transfer:HomeBucket\}`.
|
303
|
+
#
|
304
|
+
# @option params [required, String] :role
|
305
|
+
# The IAM role that controls your user’s access to your Amazon S3
|
306
|
+
# bucket. The policies attached to this role will determine the level of
|
307
|
+
# access you want to provide your users when transferring files into and
|
308
|
+
# out of your Amazon S3 bucket or buckets. The IAM role should also
|
309
|
+
# contain a trust relationship that allows the SFTP server to access
|
310
|
+
# your resources when servicing your SFTP user’s transfer requests.
|
311
|
+
#
|
312
|
+
# @option params [required, String] :server_id
|
313
|
+
# A system-assigned unique identifier for an SFTP server instance. This
|
314
|
+
# is the specific SFTP server that you added your user to.
|
315
|
+
#
|
316
|
+
# @option params [String] :ssh_public_key_body
|
317
|
+
# The public portion of the Secure Shall (SSH) key used to authenticate
|
318
|
+
# the user to the SFTP server.
|
319
|
+
#
|
320
|
+
# @option params [Array<Types::Tag>] :tags
|
321
|
+
# Key-value pairs that can be used to group and search for users. Tags
|
322
|
+
# are metadata attached to users for any purpose.
|
323
|
+
#
|
324
|
+
# @option params [required, String] :user_name
|
325
|
+
# A unique string that identifies a user and is associated with a server
|
326
|
+
# as specified by the `ServerId`.
|
327
|
+
#
|
328
|
+
# @return [Types::CreateUserResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
329
|
+
#
|
330
|
+
# * {Types::CreateUserResponse#server_id #server_id} => String
|
331
|
+
# * {Types::CreateUserResponse#user_name #user_name} => String
|
332
|
+
#
|
333
|
+
# @example Request syntax with placeholder values
|
334
|
+
#
|
335
|
+
# resp = client.create_user({
|
336
|
+
# home_directory: "HomeDirectory",
|
337
|
+
# policy: "Policy",
|
338
|
+
# role: "Role", # required
|
339
|
+
# server_id: "ServerId", # required
|
340
|
+
# ssh_public_key_body: "SshPublicKeyBody",
|
341
|
+
# tags: [
|
342
|
+
# {
|
343
|
+
# key: "TagKey", # required
|
344
|
+
# value: "TagValue", # required
|
345
|
+
# },
|
346
|
+
# ],
|
347
|
+
# user_name: "UserName", # required
|
348
|
+
# })
|
349
|
+
#
|
350
|
+
# @example Response structure
|
351
|
+
#
|
352
|
+
# resp.server_id #=> String
|
353
|
+
# resp.user_name #=> String
|
354
|
+
#
|
355
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/CreateUser AWS API Documentation
|
356
|
+
#
|
357
|
+
# @overload create_user(params = {})
|
358
|
+
# @param [Hash] params ({})
|
359
|
+
def create_user(params = {}, options = {})
|
360
|
+
req = build_request(:create_user, params)
|
361
|
+
req.send_request(options)
|
362
|
+
end
|
363
|
+
|
364
|
+
# Deletes the Secure File Transfer Protocol (SFTP) server that you
|
365
|
+
# specify. If you used `SERVICE_MANAGED` as your `IdentityProviderType`,
|
366
|
+
# you need to delete all users associated with this server before
|
367
|
+
# deleting the server itself
|
368
|
+
#
|
369
|
+
# No response returns from this call.
|
370
|
+
#
|
371
|
+
# @option params [required, String] :server_id
|
372
|
+
# A unique system-assigned identifier for an SFTP server instance.
|
373
|
+
#
|
374
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
375
|
+
#
|
376
|
+
# @example Request syntax with placeholder values
|
377
|
+
#
|
378
|
+
# resp = client.delete_server({
|
379
|
+
# server_id: "ServerId", # required
|
380
|
+
# })
|
381
|
+
#
|
382
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DeleteServer AWS API Documentation
|
383
|
+
#
|
384
|
+
# @overload delete_server(params = {})
|
385
|
+
# @param [Hash] params ({})
|
386
|
+
def delete_server(params = {}, options = {})
|
387
|
+
req = build_request(:delete_server, params)
|
388
|
+
req.send_request(options)
|
389
|
+
end
|
390
|
+
|
391
|
+
# Deletes a user's Secure Shell (SSH) public key.
|
392
|
+
#
|
393
|
+
# No response is returned from this call.
|
394
|
+
#
|
395
|
+
# @option params [required, String] :server_id
|
396
|
+
# A system-assigned unique identifier for a Secure File Transfer
|
397
|
+
# Protocol (SFTP) server instance that has the user assigned to it.
|
398
|
+
#
|
399
|
+
# @option params [required, String] :ssh_public_key_id
|
400
|
+
# A unique identifier used to reference your user’s specific SSH key.
|
401
|
+
#
|
402
|
+
# @option params [required, String] :user_name
|
403
|
+
# A unique string that identifies a user whose public key is being
|
404
|
+
# deleted.
|
405
|
+
#
|
406
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
407
|
+
#
|
408
|
+
# @example Request syntax with placeholder values
|
409
|
+
#
|
410
|
+
# resp = client.delete_ssh_public_key({
|
411
|
+
# server_id: "ServerId", # required
|
412
|
+
# ssh_public_key_id: "SshPublicKeyId", # required
|
413
|
+
# user_name: "UserName", # required
|
414
|
+
# })
|
415
|
+
#
|
416
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DeleteSshPublicKey AWS API Documentation
|
417
|
+
#
|
418
|
+
# @overload delete_ssh_public_key(params = {})
|
419
|
+
# @param [Hash] params ({})
|
420
|
+
def delete_ssh_public_key(params = {}, options = {})
|
421
|
+
req = build_request(:delete_ssh_public_key, params)
|
422
|
+
req.send_request(options)
|
423
|
+
end
|
424
|
+
|
425
|
+
# Deletes the user belonging to the server you specify.
|
426
|
+
#
|
427
|
+
# No response returns from this call.
|
428
|
+
#
|
429
|
+
# <note markdown="1"> When you delete a user from a server, the user's information is lost.
|
430
|
+
#
|
431
|
+
# </note>
|
432
|
+
#
|
433
|
+
# @option params [required, String] :server_id
|
434
|
+
# A system-assigned unique identifier for an SFTP server instance that
|
435
|
+
# has the user assigned to it.
|
436
|
+
#
|
437
|
+
# @option params [required, String] :user_name
|
438
|
+
# A unique string that identifies a user that is being deleted from the
|
439
|
+
# server.
|
440
|
+
#
|
441
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
442
|
+
#
|
443
|
+
# @example Request syntax with placeholder values
|
444
|
+
#
|
445
|
+
# resp = client.delete_user({
|
446
|
+
# server_id: "ServerId", # required
|
447
|
+
# user_name: "UserName", # required
|
448
|
+
# })
|
449
|
+
#
|
450
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DeleteUser AWS API Documentation
|
451
|
+
#
|
452
|
+
# @overload delete_user(params = {})
|
453
|
+
# @param [Hash] params ({})
|
454
|
+
def delete_user(params = {}, options = {})
|
455
|
+
req = build_request(:delete_user, params)
|
456
|
+
req.send_request(options)
|
457
|
+
end
|
458
|
+
|
459
|
+
# Describes the server that you specify by passing the `ServerId`
|
460
|
+
# parameter.
|
461
|
+
#
|
462
|
+
# The response contains a description of the server's properties.
|
463
|
+
#
|
464
|
+
# @option params [required, String] :server_id
|
465
|
+
# A system-assigned unique identifier for an SFTP server.
|
466
|
+
#
|
467
|
+
# @return [Types::DescribeServerResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
468
|
+
#
|
469
|
+
# * {Types::DescribeServerResponse#server #server} => Types::DescribedServer
|
470
|
+
#
|
471
|
+
# @example Request syntax with placeholder values
|
472
|
+
#
|
473
|
+
# resp = client.describe_server({
|
474
|
+
# server_id: "ServerId", # required
|
475
|
+
# })
|
476
|
+
#
|
477
|
+
# @example Response structure
|
478
|
+
#
|
479
|
+
# resp.server.arn #=> String
|
480
|
+
# resp.server.identity_provider_details.url #=> String
|
481
|
+
# resp.server.identity_provider_details.invocation_role #=> String
|
482
|
+
# resp.server.identity_provider_type #=> String, one of "SERVICE_MANAGED", "API_GATEWAY"
|
483
|
+
# resp.server.logging_role #=> String
|
484
|
+
# resp.server.server_id #=> String
|
485
|
+
# resp.server.state #=> String, one of "OFFLINE", "ONLINE", "STARTING", "STOPPING", "START_FAILED", "STOP_FAILED"
|
486
|
+
# resp.server.tags #=> Array
|
487
|
+
# resp.server.tags[0].key #=> String
|
488
|
+
# resp.server.tags[0].value #=> String
|
489
|
+
# resp.server.user_count #=> Integer
|
490
|
+
#
|
491
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DescribeServer AWS API Documentation
|
492
|
+
#
|
493
|
+
# @overload describe_server(params = {})
|
494
|
+
# @param [Hash] params ({})
|
495
|
+
def describe_server(params = {}, options = {})
|
496
|
+
req = build_request(:describe_server, params)
|
497
|
+
req.send_request(options)
|
498
|
+
end
|
499
|
+
|
500
|
+
# Describes the user assigned to a specific server, as identified by its
|
501
|
+
# `ServerId` property.
|
502
|
+
#
|
503
|
+
# The response from this call returns the properties of the user
|
504
|
+
# associated with the `ServerId` value that was specified.
|
505
|
+
#
|
506
|
+
# @option params [required, String] :server_id
|
507
|
+
# A system-assigned unique identifier for an SFTP server that has this
|
508
|
+
# user assigned.
|
509
|
+
#
|
510
|
+
# @option params [required, String] :user_name
|
511
|
+
# The name of the user assigned to one or more servers. User names are
|
512
|
+
# part of the sign-in credentials to use the AWS Transfer service and
|
513
|
+
# perform file transfer tasks.
|
514
|
+
#
|
515
|
+
# @return [Types::DescribeUserResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
516
|
+
#
|
517
|
+
# * {Types::DescribeUserResponse#server_id #server_id} => String
|
518
|
+
# * {Types::DescribeUserResponse#user #user} => Types::DescribedUser
|
519
|
+
#
|
520
|
+
# @example Request syntax with placeholder values
|
521
|
+
#
|
522
|
+
# resp = client.describe_user({
|
523
|
+
# server_id: "ServerId", # required
|
524
|
+
# user_name: "UserName", # required
|
525
|
+
# })
|
526
|
+
#
|
527
|
+
# @example Response structure
|
528
|
+
#
|
529
|
+
# resp.server_id #=> String
|
530
|
+
# resp.user.arn #=> String
|
531
|
+
# resp.user.home_directory #=> String
|
532
|
+
# resp.user.policy #=> String
|
533
|
+
# resp.user.role #=> String
|
534
|
+
# resp.user.ssh_public_keys #=> Array
|
535
|
+
# resp.user.ssh_public_keys[0].date_imported #=> Time
|
536
|
+
# resp.user.ssh_public_keys[0].ssh_public_key_body #=> String
|
537
|
+
# resp.user.ssh_public_keys[0].ssh_public_key_id #=> String
|
538
|
+
# resp.user.tags #=> Array
|
539
|
+
# resp.user.tags[0].key #=> String
|
540
|
+
# resp.user.tags[0].value #=> String
|
541
|
+
# resp.user.user_name #=> String
|
542
|
+
#
|
543
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DescribeUser AWS API Documentation
|
544
|
+
#
|
545
|
+
# @overload describe_user(params = {})
|
546
|
+
# @param [Hash] params ({})
|
547
|
+
def describe_user(params = {}, options = {})
|
548
|
+
req = build_request(:describe_user, params)
|
549
|
+
req.send_request(options)
|
550
|
+
end
|
551
|
+
|
552
|
+
# Adds a Secure Shell (SSH) public key to a user account identified by a
|
553
|
+
# `UserName` value assigned to a specific server, identified by
|
554
|
+
# `ServerId`.
|
555
|
+
#
|
556
|
+
# The response returns the `UserName` value, the `ServerId` value, and
|
557
|
+
# the name of the `SshPublicKeyId`.
|
558
|
+
#
|
559
|
+
# @option params [required, String] :server_id
|
560
|
+
# A system-assigned unique identifier for an SFTP server.
|
561
|
+
#
|
562
|
+
# @option params [required, String] :ssh_public_key_body
|
563
|
+
# The public key portion of an SSH key pair.
|
564
|
+
#
|
565
|
+
# @option params [required, String] :user_name
|
566
|
+
# The name of the user account that is assigned to one or more servers.
|
567
|
+
#
|
568
|
+
# @return [Types::ImportSshPublicKeyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
569
|
+
#
|
570
|
+
# * {Types::ImportSshPublicKeyResponse#server_id #server_id} => String
|
571
|
+
# * {Types::ImportSshPublicKeyResponse#ssh_public_key_id #ssh_public_key_id} => String
|
572
|
+
# * {Types::ImportSshPublicKeyResponse#user_name #user_name} => String
|
573
|
+
#
|
574
|
+
# @example Request syntax with placeholder values
|
575
|
+
#
|
576
|
+
# resp = client.import_ssh_public_key({
|
577
|
+
# server_id: "ServerId", # required
|
578
|
+
# ssh_public_key_body: "SshPublicKeyBody", # required
|
579
|
+
# user_name: "UserName", # required
|
580
|
+
# })
|
581
|
+
#
|
582
|
+
# @example Response structure
|
583
|
+
#
|
584
|
+
# resp.server_id #=> String
|
585
|
+
# resp.ssh_public_key_id #=> String
|
586
|
+
# resp.user_name #=> String
|
587
|
+
#
|
588
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ImportSshPublicKey AWS API Documentation
|
589
|
+
#
|
590
|
+
# @overload import_ssh_public_key(params = {})
|
591
|
+
# @param [Hash] params ({})
|
592
|
+
def import_ssh_public_key(params = {}, options = {})
|
593
|
+
req = build_request(:import_ssh_public_key, params)
|
594
|
+
req.send_request(options)
|
595
|
+
end
|
596
|
+
|
597
|
+
# Lists the Secure File Transfer Protocol (SFTP) servers that are
|
598
|
+
# associated with your AWS account.
|
599
|
+
#
|
600
|
+
# @option params [Integer] :max_results
|
601
|
+
# Specifies the number of servers to return as a response to the
|
602
|
+
# `ListServers` query.
|
603
|
+
#
|
604
|
+
# @option params [String] :next_token
|
605
|
+
# When additional results are obtained from the ListServers command, a
|
606
|
+
# `NextToken` parameter is returned in the output. You can then pass the
|
607
|
+
# `NextToken` parameter in a subsequent command to continue listing
|
608
|
+
# additional servers.
|
609
|
+
#
|
610
|
+
# @return [Types::ListServersResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
611
|
+
#
|
612
|
+
# * {Types::ListServersResponse#next_token #next_token} => String
|
613
|
+
# * {Types::ListServersResponse#servers #servers} => Array<Types::ListedServer>
|
614
|
+
#
|
615
|
+
# @example Request syntax with placeholder values
|
616
|
+
#
|
617
|
+
# resp = client.list_servers({
|
618
|
+
# max_results: 1,
|
619
|
+
# next_token: "NextToken",
|
620
|
+
# })
|
621
|
+
#
|
622
|
+
# @example Response structure
|
623
|
+
#
|
624
|
+
# resp.next_token #=> String
|
625
|
+
# resp.servers #=> Array
|
626
|
+
# resp.servers[0].arn #=> String
|
627
|
+
# resp.servers[0].identity_provider_type #=> String, one of "SERVICE_MANAGED", "API_GATEWAY"
|
628
|
+
# resp.servers[0].logging_role #=> String
|
629
|
+
# resp.servers[0].server_id #=> String
|
630
|
+
# resp.servers[0].state #=> String, one of "OFFLINE", "ONLINE", "STARTING", "STOPPING", "START_FAILED", "STOP_FAILED"
|
631
|
+
# resp.servers[0].user_count #=> Integer
|
632
|
+
#
|
633
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListServers AWS API Documentation
|
634
|
+
#
|
635
|
+
# @overload list_servers(params = {})
|
636
|
+
# @param [Hash] params ({})
|
637
|
+
def list_servers(params = {}, options = {})
|
638
|
+
req = build_request(:list_servers, params)
|
639
|
+
req.send_request(options)
|
640
|
+
end
|
641
|
+
|
642
|
+
# Lists all of the tags associated with the Amazon Resource Number (ARN)
|
643
|
+
# you specify. The resource can be a user, server, or role.
|
644
|
+
#
|
645
|
+
# @option params [required, String] :arn
|
646
|
+
# Requests the tags associated with a particular Amazon Resource Name
|
647
|
+
# (ARN). An ARN is an identifier for a specific AWS resource, such as a
|
648
|
+
# server, user, or role.
|
649
|
+
#
|
650
|
+
# @option params [Integer] :max_results
|
651
|
+
#
|
652
|
+
# @option params [String] :next_token
|
653
|
+
#
|
654
|
+
# @return [Types::ListTagsForResourceResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
655
|
+
#
|
656
|
+
# * {Types::ListTagsForResourceResponse#arn #arn} => String
|
657
|
+
# * {Types::ListTagsForResourceResponse#next_token #next_token} => String
|
658
|
+
# * {Types::ListTagsForResourceResponse#tags #tags} => Array<Types::Tag>
|
659
|
+
#
|
660
|
+
# @example Request syntax with placeholder values
|
661
|
+
#
|
662
|
+
# resp = client.list_tags_for_resource({
|
663
|
+
# arn: "Arn", # required
|
664
|
+
# max_results: 1,
|
665
|
+
# next_token: "NextToken",
|
666
|
+
# })
|
667
|
+
#
|
668
|
+
# @example Response structure
|
669
|
+
#
|
670
|
+
# resp.arn #=> String
|
671
|
+
# resp.next_token #=> String
|
672
|
+
# resp.tags #=> Array
|
673
|
+
# resp.tags[0].key #=> String
|
674
|
+
# resp.tags[0].value #=> String
|
675
|
+
#
|
676
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListTagsForResource AWS API Documentation
|
677
|
+
#
|
678
|
+
# @overload list_tags_for_resource(params = {})
|
679
|
+
# @param [Hash] params ({})
|
680
|
+
def list_tags_for_resource(params = {}, options = {})
|
681
|
+
req = build_request(:list_tags_for_resource, params)
|
682
|
+
req.send_request(options)
|
683
|
+
end
|
684
|
+
|
685
|
+
# Lists the users for the server that you specify by passing the
|
686
|
+
# `ServerId` parameter.
|
687
|
+
#
|
688
|
+
# @option params [Integer] :max_results
|
689
|
+
# Specifies the number of users to return as a response to the
|
690
|
+
# `ListUsers` request.
|
691
|
+
#
|
692
|
+
# @option params [String] :next_token
|
693
|
+
# When you can get additional results from the `ListUsers`ListUsers
|
694
|
+
# call, a `NextToken` parameter is returned in the output. You can then
|
695
|
+
# pass in a subsequent command the `NextToken` parameter to continue
|
696
|
+
# listing additional users.
|
697
|
+
#
|
698
|
+
# @option params [required, String] :server_id
|
699
|
+
# A system-assigned unique identifier for a Secure File Transfer
|
700
|
+
# Protocol (SFTP) server that has users are assigned to it.
|
701
|
+
#
|
702
|
+
# @return [Types::ListUsersResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
703
|
+
#
|
704
|
+
# * {Types::ListUsersResponse#next_token #next_token} => String
|
705
|
+
# * {Types::ListUsersResponse#server_id #server_id} => String
|
706
|
+
# * {Types::ListUsersResponse#users #users} => Array<Types::ListedUser>
|
707
|
+
#
|
708
|
+
# @example Request syntax with placeholder values
|
709
|
+
#
|
710
|
+
# resp = client.list_users({
|
711
|
+
# max_results: 1,
|
712
|
+
# next_token: "NextToken",
|
713
|
+
# server_id: "ServerId", # required
|
714
|
+
# })
|
715
|
+
#
|
716
|
+
# @example Response structure
|
717
|
+
#
|
718
|
+
# resp.next_token #=> String
|
719
|
+
# resp.server_id #=> String
|
720
|
+
# resp.users #=> Array
|
721
|
+
# resp.users[0].arn #=> String
|
722
|
+
# resp.users[0].home_directory #=> String
|
723
|
+
# resp.users[0].role #=> String
|
724
|
+
# resp.users[0].ssh_public_key_count #=> Integer
|
725
|
+
# resp.users[0].user_name #=> String
|
726
|
+
#
|
727
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListUsers AWS API Documentation
|
728
|
+
#
|
729
|
+
# @overload list_users(params = {})
|
730
|
+
# @param [Hash] params ({})
|
731
|
+
def list_users(params = {}, options = {})
|
732
|
+
req = build_request(:list_users, params)
|
733
|
+
req.send_request(options)
|
734
|
+
end
|
735
|
+
|
736
|
+
# Changes the state of a Secure File Transfer Protocol (SFTP) server
|
737
|
+
# from `OFFLINE` to `ONLINE`. It has no impact on an SFTP server that is
|
738
|
+
# already `ONLINE`. An `ONLINE` server can accept and process file
|
739
|
+
# transfer jobs.
|
740
|
+
#
|
741
|
+
# The state of `STARTING` indicates that the server is in an
|
742
|
+
# intermediate state, either not fully able to respond, or not fully
|
743
|
+
# online. The values of `START_FAILED` can indicate an error condition.
|
744
|
+
#
|
745
|
+
# No response is returned from this call.
|
746
|
+
#
|
747
|
+
# @option params [required, String] :server_id
|
748
|
+
# A system-assigned unique identifier for an SFTP server that you start.
|
749
|
+
#
|
750
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
751
|
+
#
|
752
|
+
# @example Request syntax with placeholder values
|
753
|
+
#
|
754
|
+
# resp = client.start_server({
|
755
|
+
# server_id: "ServerId", # required
|
756
|
+
# })
|
757
|
+
#
|
758
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/StartServer AWS API Documentation
|
759
|
+
#
|
760
|
+
# @overload start_server(params = {})
|
761
|
+
# @param [Hash] params ({})
|
762
|
+
def start_server(params = {}, options = {})
|
763
|
+
req = build_request(:start_server, params)
|
764
|
+
req.send_request(options)
|
765
|
+
end
|
766
|
+
|
767
|
+
# Changes the state of an SFTP server from `ONLINE` to `OFFLINE`. An
|
768
|
+
# `OFFLINE` server cannot accept and process file transfer jobs.
|
769
|
+
# Information tied to your server such as server and user properties are
|
770
|
+
# not affected by stopping your server. Stopping a server will not
|
771
|
+
# reduce or impact your Secure File Transfer Protocol (SFTP) endpoint
|
772
|
+
# billing.
|
773
|
+
#
|
774
|
+
# The states of `STOPPING` indicates that the server is in an
|
775
|
+
# intermediate state, either not fully able to respond, or not fully
|
776
|
+
# offline. The values of `STOP_FAILED` can indicate an error condition.
|
777
|
+
#
|
778
|
+
# No response is returned from this call.
|
779
|
+
#
|
780
|
+
# @option params [required, String] :server_id
|
781
|
+
# A system-assigned unique identifier for an SFTP server that you
|
782
|
+
# stopped.
|
783
|
+
#
|
784
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
785
|
+
#
|
786
|
+
# @example Request syntax with placeholder values
|
787
|
+
#
|
788
|
+
# resp = client.stop_server({
|
789
|
+
# server_id: "ServerId", # required
|
790
|
+
# })
|
791
|
+
#
|
792
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/StopServer AWS API Documentation
|
793
|
+
#
|
794
|
+
# @overload stop_server(params = {})
|
795
|
+
# @param [Hash] params ({})
|
796
|
+
def stop_server(params = {}, options = {})
|
797
|
+
req = build_request(:stop_server, params)
|
798
|
+
req.send_request(options)
|
799
|
+
end
|
800
|
+
|
801
|
+
# Attaches a key-value pair to a resource, as identified by its Amazon
|
802
|
+
# Resource Name (ARN). Resources are users, servers, roles, and other
|
803
|
+
# entities.
|
804
|
+
#
|
805
|
+
# There is no response returned from this call.
|
806
|
+
#
|
807
|
+
# @option params [required, String] :arn
|
808
|
+
# An Amazon Resource Name (ARN) for a specific AWS resource, such as a
|
809
|
+
# server, user, or role.
|
810
|
+
#
|
811
|
+
# @option params [required, Array<Types::Tag>] :tags
|
812
|
+
# Key-value pairs assigned to ARNs that you can use to group and search
|
813
|
+
# for resources by type. You can attach this metadata to user accounts
|
814
|
+
# for any purpose.
|
815
|
+
#
|
816
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
817
|
+
#
|
818
|
+
# @example Request syntax with placeholder values
|
819
|
+
#
|
820
|
+
# resp = client.tag_resource({
|
821
|
+
# arn: "Arn", # required
|
822
|
+
# tags: [ # required
|
823
|
+
# {
|
824
|
+
# key: "TagKey", # required
|
825
|
+
# value: "TagValue", # required
|
826
|
+
# },
|
827
|
+
# ],
|
828
|
+
# })
|
829
|
+
#
|
830
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/TagResource AWS API Documentation
|
831
|
+
#
|
832
|
+
# @overload tag_resource(params = {})
|
833
|
+
# @param [Hash] params ({})
|
834
|
+
def tag_resource(params = {}, options = {})
|
835
|
+
req = build_request(:tag_resource, params)
|
836
|
+
req.send_request(options)
|
837
|
+
end
|
838
|
+
|
839
|
+
# If the `IdentityProviderType` of the server is `API_Gateway`, tests
|
840
|
+
# whether your API Gateway is set up successfully. We highly recommend
|
841
|
+
# that you call this method to test your authentication method as soon
|
842
|
+
# as you create your server. By doing so, you can troubleshoot issues
|
843
|
+
# with the API Gateway integration to ensure that your users can
|
844
|
+
# successfully use the service.
|
845
|
+
#
|
846
|
+
# @option params [required, String] :server_id
|
847
|
+
# A system assigned identifier for a specific server. That server's
|
848
|
+
# user authentication method is tested with a user name and password.
|
849
|
+
#
|
850
|
+
# @option params [required, String] :user_name
|
851
|
+
# This request parameter is name of the user account to be tested.
|
852
|
+
#
|
853
|
+
# @option params [String] :user_password
|
854
|
+
# The password of the user account to be tested.
|
855
|
+
#
|
856
|
+
# @return [Types::TestIdentityProviderResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
857
|
+
#
|
858
|
+
# * {Types::TestIdentityProviderResponse#message #message} => String
|
859
|
+
# * {Types::TestIdentityProviderResponse#status_code #status_code} => Integer
|
860
|
+
# * {Types::TestIdentityProviderResponse#url #url} => String
|
861
|
+
#
|
862
|
+
# @example Request syntax with placeholder values
|
863
|
+
#
|
864
|
+
# resp = client.test_identity_provider({
|
865
|
+
# server_id: "ServerId", # required
|
866
|
+
# user_name: "UserName", # required
|
867
|
+
# user_password: "UserPassword",
|
868
|
+
# })
|
869
|
+
#
|
870
|
+
# @example Response structure
|
871
|
+
#
|
872
|
+
# resp.message #=> String
|
873
|
+
# resp.status_code #=> Integer
|
874
|
+
# resp.url #=> String
|
875
|
+
#
|
876
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/TestIdentityProvider AWS API Documentation
|
877
|
+
#
|
878
|
+
# @overload test_identity_provider(params = {})
|
879
|
+
# @param [Hash] params ({})
|
880
|
+
def test_identity_provider(params = {}, options = {})
|
881
|
+
req = build_request(:test_identity_provider, params)
|
882
|
+
req.send_request(options)
|
883
|
+
end
|
884
|
+
|
885
|
+
# Detaches a key-value pair from a resource, as identified by its Amazon
|
886
|
+
# Resource Name (ARN). Resources are users, servers, roles, and other
|
887
|
+
# entities.
|
888
|
+
#
|
889
|
+
# No response is returned from this call.
|
890
|
+
#
|
891
|
+
# @option params [required, String] :arn
|
892
|
+
# This is the value of the resource that will have the tag removed. An
|
893
|
+
# Amazon Resource Name (ARN) is an identifier for a specific AWS
|
894
|
+
# resource, such as a server, user, or role.
|
895
|
+
#
|
896
|
+
# @option params [required, Array<String>] :tag_keys
|
897
|
+
# TagKeys are key-value pairs assigned to ARNs that can be used to group
|
898
|
+
# and search for resources by type. This metadata can be attached to
|
899
|
+
# resources for any purpose.
|
900
|
+
#
|
901
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
902
|
+
#
|
903
|
+
# @example Request syntax with placeholder values
|
904
|
+
#
|
905
|
+
# resp = client.untag_resource({
|
906
|
+
# arn: "Arn", # required
|
907
|
+
# tag_keys: ["TagKey"], # required
|
908
|
+
# })
|
909
|
+
#
|
910
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/UntagResource AWS API Documentation
|
911
|
+
#
|
912
|
+
# @overload untag_resource(params = {})
|
913
|
+
# @param [Hash] params ({})
|
914
|
+
def untag_resource(params = {}, options = {})
|
915
|
+
req = build_request(:untag_resource, params)
|
916
|
+
req.send_request(options)
|
917
|
+
end
|
918
|
+
|
919
|
+
# Updates the server properties after that server has been created.
|
920
|
+
#
|
921
|
+
# The `UpdateServer` call returns the `ServerId` of the Secure File
|
922
|
+
# Transfer Protocol (SFTP) server you updated.
|
923
|
+
#
|
924
|
+
# @option params [Types::IdentityProviderDetails] :identity_provider_details
|
925
|
+
# This response parameter is an array containing all of the information
|
926
|
+
# required to call a customer's authentication API method.
|
927
|
+
#
|
928
|
+
# @option params [String] :logging_role
|
929
|
+
# Changes the AWS Identity and Access Management (IAM) role that allows
|
930
|
+
# Amazon S3 events to be logged in Amazon CloudWatch, turning logging on
|
931
|
+
# or off.
|
932
|
+
#
|
933
|
+
# @option params [required, String] :server_id
|
934
|
+
# A system-assigned unique identifier for an SFTP server instance that
|
935
|
+
# the user account is assigned to.
|
936
|
+
#
|
937
|
+
# @return [Types::UpdateServerResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
938
|
+
#
|
939
|
+
# * {Types::UpdateServerResponse#server_id #server_id} => String
|
940
|
+
#
|
941
|
+
# @example Request syntax with placeholder values
|
942
|
+
#
|
943
|
+
# resp = client.update_server({
|
944
|
+
# identity_provider_details: {
|
945
|
+
# url: "Url",
|
946
|
+
# invocation_role: "Role",
|
947
|
+
# },
|
948
|
+
# logging_role: "NullableRole",
|
949
|
+
# server_id: "ServerId", # required
|
950
|
+
# })
|
951
|
+
#
|
952
|
+
# @example Response structure
|
953
|
+
#
|
954
|
+
# resp.server_id #=> String
|
955
|
+
#
|
956
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/UpdateServer AWS API Documentation
|
957
|
+
#
|
958
|
+
# @overload update_server(params = {})
|
959
|
+
# @param [Hash] params ({})
|
960
|
+
def update_server(params = {}, options = {})
|
961
|
+
req = build_request(:update_server, params)
|
962
|
+
req.send_request(options)
|
963
|
+
end
|
964
|
+
|
965
|
+
# Assigns new properties to a user. Parameters you pass modify any or
|
966
|
+
# all of the following: the home directory, role, and policy for the
|
967
|
+
# `UserName` and `ServerId` you specify.
|
968
|
+
#
|
969
|
+
# The response returns the `ServerId` and the `UserName` for the updated
|
970
|
+
# user.
|
971
|
+
#
|
972
|
+
# @option params [String] :home_directory
|
973
|
+
# The HomeDirectory parameter specifies the landing directory (folder)
|
974
|
+
# for a user when they log in to the server using their client. An
|
975
|
+
# example would be: `/home/username `.
|
976
|
+
#
|
977
|
+
# @option params [String] :policy
|
978
|
+
# Allows you to supply a scope-down policy for your user so you can use
|
979
|
+
# the same AWS Identity and Access Management (IAM) role across multiple
|
980
|
+
# users. The policy scopes down users access to portions of your Amazon
|
981
|
+
# S3 bucket. Variables you can use inside this policy include
|
982
|
+
# `$\{Transfer:UserName\}`, `$\{Transfer:HomeDirectory\}`, and
|
983
|
+
# `$\{Transfer:HomeBucket\}`.
|
984
|
+
#
|
985
|
+
# @option params [String] :role
|
986
|
+
# The IAM role that controls your user’s access to your Amazon S3
|
987
|
+
# bucket. The policies attached to this role will determine the level of
|
988
|
+
# access you want to provide your users when transferring files into and
|
989
|
+
# out of your Amazon S3 bucket or buckets. The IAM role should also
|
990
|
+
# contain a trust relationship that allows the Secure File Transfer
|
991
|
+
# Protocol (SFTP) server to access your resources when servicing your
|
992
|
+
# SFTP user’s transfer requests.
|
993
|
+
#
|
994
|
+
# @option params [required, String] :server_id
|
995
|
+
# A system-assigned unique identifier for an SFTP server instance that
|
996
|
+
# the user account is assigned to.
|
997
|
+
#
|
998
|
+
# @option params [required, String] :user_name
|
999
|
+
# A unique string that identifies a user and is associated with a server
|
1000
|
+
# as specified by the ServerId. This is the string that will be used by
|
1001
|
+
# your user when they log in to your SFTP server.
|
1002
|
+
#
|
1003
|
+
# @return [Types::UpdateUserResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1004
|
+
#
|
1005
|
+
# * {Types::UpdateUserResponse#server_id #server_id} => String
|
1006
|
+
# * {Types::UpdateUserResponse#user_name #user_name} => String
|
1007
|
+
#
|
1008
|
+
# @example Request syntax with placeholder values
|
1009
|
+
#
|
1010
|
+
# resp = client.update_user({
|
1011
|
+
# home_directory: "HomeDirectory",
|
1012
|
+
# policy: "Policy",
|
1013
|
+
# role: "Role",
|
1014
|
+
# server_id: "ServerId", # required
|
1015
|
+
# user_name: "UserName", # required
|
1016
|
+
# })
|
1017
|
+
#
|
1018
|
+
# @example Response structure
|
1019
|
+
#
|
1020
|
+
# resp.server_id #=> String
|
1021
|
+
# resp.user_name #=> String
|
1022
|
+
#
|
1023
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/UpdateUser AWS API Documentation
|
1024
|
+
#
|
1025
|
+
# @overload update_user(params = {})
|
1026
|
+
# @param [Hash] params ({})
|
1027
|
+
def update_user(params = {}, options = {})
|
1028
|
+
req = build_request(:update_user, params)
|
1029
|
+
req.send_request(options)
|
1030
|
+
end
|
1031
|
+
|
1032
|
+
# @!endgroup
|
1033
|
+
|
1034
|
+
# @param params ({})
|
1035
|
+
# @api private
|
1036
|
+
def build_request(operation_name, params = {})
|
1037
|
+
handlers = @handlers.for(operation_name)
|
1038
|
+
context = Seahorse::Client::RequestContext.new(
|
1039
|
+
operation_name: operation_name,
|
1040
|
+
operation: config.api.operation(operation_name),
|
1041
|
+
client: self,
|
1042
|
+
params: params,
|
1043
|
+
config: config)
|
1044
|
+
context[:gem_name] = 'aws-sdk-transfer'
|
1045
|
+
context[:gem_version] = '1.0.0'
|
1046
|
+
Seahorse::Client::Request.new(handlers, context)
|
1047
|
+
end
|
1048
|
+
|
1049
|
+
# @api private
|
1050
|
+
# @deprecated
|
1051
|
+
def waiter_names
|
1052
|
+
[]
|
1053
|
+
end
|
1054
|
+
|
1055
|
+
class << self
|
1056
|
+
|
1057
|
+
# @api private
|
1058
|
+
attr_reader :identifier
|
1059
|
+
|
1060
|
+
# @api private
|
1061
|
+
def errors_module
|
1062
|
+
Errors
|
1063
|
+
end
|
1064
|
+
|
1065
|
+
end
|
1066
|
+
end
|
1067
|
+
end
|