aws-sdk-iam 1.77.0 → 1.79.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -63,7 +63,9 @@ module Aws::IAM
63
63
  # [1]: http://wikipedia.org/wiki/regex
64
64
  # @return [EmptyStructure]
65
65
  def change_password(options = {})
66
- resp = @client.change_password(options)
66
+ resp = Aws::Plugins::UserAgent.feature('resource') do
67
+ @client.change_password(options)
68
+ end
67
69
  resp.data
68
70
  end
69
71
 
@@ -86,7 +88,9 @@ module Aws::IAM
86
88
  # [1]: http://wikipedia.org/wiki/regex
87
89
  # @return [EmptyStructure]
88
90
  def create_account_alias(options = {})
89
- resp = @client.create_account_alias(options)
91
+ resp = Aws::Plugins::UserAgent.feature('resource') do
92
+ @client.create_account_alias(options)
93
+ end
90
94
  resp.data
91
95
  end
92
96
 
@@ -189,7 +193,9 @@ module Aws::IAM
189
193
  # </note>
190
194
  # @return [AccountPasswordPolicy]
191
195
  def create_account_password_policy(options = {})
192
- @client.update_account_password_policy(options)
196
+ Aws::Plugins::UserAgent.feature('resource') do
197
+ @client.update_account_password_policy(options)
198
+ end
193
199
  AccountPasswordPolicy.new(client: @client)
194
200
  end
195
201
 
@@ -227,7 +233,9 @@ module Aws::IAM
227
233
  # create resources named both "MyResource" and "myresource".
228
234
  # @return [Group]
229
235
  def create_group(options = {})
230
- resp = @client.create_group(options)
236
+ resp = Aws::Plugins::UserAgent.feature('resource') do
237
+ @client.create_group(options)
238
+ end
231
239
  Group.new(
232
240
  name: options[:group_name],
233
241
  data: resp.data.group,
@@ -294,7 +302,9 @@ module Aws::IAM
294
302
  # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_tags.html
295
303
  # @return [InstanceProfile]
296
304
  def create_instance_profile(options = {})
297
- resp = @client.create_instance_profile(options)
305
+ resp = Aws::Plugins::UserAgent.feature('resource') do
306
+ @client.create_instance_profile(options)
307
+ end
298
308
  InstanceProfile.new(
299
309
  name: options[:instance_profile_name],
300
310
  data: resp.data.instance_profile,
@@ -407,7 +417,9 @@ module Aws::IAM
407
417
  # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_tags.html
408
418
  # @return [Policy]
409
419
  def create_policy(options = {})
410
- resp = @client.create_policy(options)
420
+ resp = Aws::Plugins::UserAgent.feature('resource') do
421
+ @client.create_policy(options)
422
+ end
411
423
  Policy.new(
412
424
  arn: resp.data.policy.arn,
413
425
  client: @client
@@ -547,7 +559,9 @@ module Aws::IAM
547
559
  # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_tags.html
548
560
  # @return [Role]
549
561
  def create_role(options = {})
550
- resp = @client.create_role(options)
562
+ resp = Aws::Plugins::UserAgent.feature('resource') do
563
+ @client.create_role(options)
564
+ end
551
565
  Role.new(
552
566
  name: options[:role_name],
553
567
  data: resp.data.role,
@@ -610,7 +624,9 @@ module Aws::IAM
610
624
  # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_tags.html
611
625
  # @return [SamlProvider]
612
626
  def create_saml_provider(options = {})
613
- resp = @client.create_saml_provider(options)
627
+ resp = Aws::Plugins::UserAgent.feature('resource') do
628
+ @client.create_saml_provider(options)
629
+ end
614
630
  SamlProvider.new(
615
631
  arn: resp.data.saml_provider_arn,
616
632
  client: @client
@@ -740,7 +756,9 @@ module Aws::IAM
740
756
  # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_tags.html
741
757
  # @return [ServerCertificate]
742
758
  def create_server_certificate(options = {})
743
- @client.upload_server_certificate(options)
759
+ Aws::Plugins::UserAgent.feature('resource') do
760
+ @client.upload_server_certificate(options)
761
+ end
744
762
  ServerCertificate.new(
745
763
  name: options[:server_certificate_name],
746
764
  client: @client
@@ -785,7 +803,9 @@ module Aws::IAM
785
803
  # [1]: http://wikipedia.org/wiki/regex
786
804
  # @return [SigningCertificate]
787
805
  def create_signing_certificate(options = {})
788
- resp = @client.upload_signing_certificate(options)
806
+ resp = Aws::Plugins::UserAgent.feature('resource') do
807
+ @client.upload_signing_certificate(options)
808
+ end
789
809
  SigningCertificate.new(
790
810
  id: resp.data.certificate.certificate_id,
791
811
  data: resp.data.certificate,
@@ -865,7 +885,9 @@ module Aws::IAM
865
885
  # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_tags.html
866
886
  # @return [User]
867
887
  def create_user(options = {})
868
- resp = @client.create_user(options)
888
+ resp = Aws::Plugins::UserAgent.feature('resource') do
889
+ @client.create_user(options)
890
+ end
869
891
  User.new(
870
892
  name: options[:user_name],
871
893
  data: resp.data.user,
@@ -933,7 +955,9 @@ module Aws::IAM
933
955
  # [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_tags.html
934
956
  # @return [VirtualMfaDevice]
935
957
  def create_virtual_mfa_device(options = {})
936
- resp = @client.create_virtual_mfa_device(options)
958
+ resp = Aws::Plugins::UserAgent.feature('resource') do
959
+ @client.create_virtual_mfa_device(options)
960
+ end
937
961
  VirtualMfaDevice.new(
938
962
  serial_number: resp.data.virtual_mfa_device.serial_number,
939
963
  data: resp.data.virtual_mfa_device,
@@ -992,7 +1016,9 @@ module Aws::IAM
992
1016
  # @return [Group::Collection]
993
1017
  def groups(options = {})
994
1018
  batches = Enumerator.new do |y|
995
- resp = @client.list_groups(options)
1019
+ resp = Aws::Plugins::UserAgent.feature('resource') do
1020
+ @client.list_groups(options)
1021
+ end
996
1022
  resp.each_page do |page|
997
1023
  batch = []
998
1024
  page.data.groups.each do |g|
@@ -1043,7 +1069,9 @@ module Aws::IAM
1043
1069
  # @return [InstanceProfile::Collection]
1044
1070
  def instance_profiles(options = {})
1045
1071
  batches = Enumerator.new do |y|
1046
- resp = @client.list_instance_profiles(options)
1072
+ resp = Aws::Plugins::UserAgent.feature('resource') do
1073
+ @client.list_instance_profiles(options)
1074
+ end
1047
1075
  resp.each_page do |page|
1048
1076
  batch = []
1049
1077
  page.data.instance_profiles.each do |i|
@@ -1110,7 +1138,9 @@ module Aws::IAM
1110
1138
  # @return [Policy::Collection]
1111
1139
  def policies(options = {})
1112
1140
  batches = Enumerator.new do |y|
1113
- resp = @client.list_policies(options)
1141
+ resp = Aws::Plugins::UserAgent.feature('resource') do
1142
+ @client.list_policies(options)
1143
+ end
1114
1144
  resp.each_page do |page|
1115
1145
  batch = []
1116
1146
  page.data.policies.each do |p|
@@ -1169,7 +1199,9 @@ module Aws::IAM
1169
1199
  # @return [Role::Collection]
1170
1200
  def roles(options = {})
1171
1201
  batches = Enumerator.new do |y|
1172
- resp = @client.list_roles(options)
1202
+ resp = Aws::Plugins::UserAgent.feature('resource') do
1203
+ @client.list_roles(options)
1204
+ end
1173
1205
  resp.each_page do |page|
1174
1206
  batch = []
1175
1207
  page.data.roles.each do |r|
@@ -1202,7 +1234,9 @@ module Aws::IAM
1202
1234
  def saml_providers(options = {})
1203
1235
  batches = Enumerator.new do |y|
1204
1236
  batch = []
1205
- resp = @client.list_saml_providers(options)
1237
+ resp = Aws::Plugins::UserAgent.feature('resource') do
1238
+ @client.list_saml_providers(options)
1239
+ end
1206
1240
  resp.data.saml_provider_list.each do |s|
1207
1241
  batch << SamlProvider.new(
1208
1242
  arn: s.arn,
@@ -1249,7 +1283,9 @@ module Aws::IAM
1249
1283
  # @return [ServerCertificate::Collection]
1250
1284
  def server_certificates(options = {})
1251
1285
  batches = Enumerator.new do |y|
1252
- resp = @client.list_server_certificates(options)
1286
+ resp = Aws::Plugins::UserAgent.feature('resource') do
1287
+ @client.list_server_certificates(options)
1288
+ end
1253
1289
  resp.each_page do |page|
1254
1290
  batch = []
1255
1291
  page.data.server_certificate_metadata_list.each do |s|
@@ -1298,7 +1334,9 @@ module Aws::IAM
1298
1334
  # @return [User::Collection]
1299
1335
  def users(options = {})
1300
1336
  batches = Enumerator.new do |y|
1301
- resp = @client.list_users(options)
1337
+ resp = Aws::Plugins::UserAgent.feature('resource') do
1338
+ @client.list_users(options)
1339
+ end
1302
1340
  resp.each_page do |page|
1303
1341
  batch = []
1304
1342
  page.data.users.each do |u|
@@ -1336,7 +1374,9 @@ module Aws::IAM
1336
1374
  # @return [VirtualMfaDevice::Collection]
1337
1375
  def virtual_mfa_devices(options = {})
1338
1376
  batches = Enumerator.new do |y|
1339
- resp = @client.list_virtual_mfa_devices(options)
1377
+ resp = Aws::Plugins::UserAgent.feature('resource') do
1378
+ @client.list_virtual_mfa_devices(options)
1379
+ end
1340
1380
  resp.each_page do |page|
1341
1381
  batch = []
1342
1382
  page.data.virtual_mfa_devices.each do |v|
@@ -157,7 +157,9 @@ module Aws::IAM
157
157
  #
158
158
  # @return [self]
159
159
  def load
160
- resp = @client.get_role(role_name: @name)
160
+ resp = Aws::Plugins::UserAgent.feature('resource') do
161
+ @client.get_role(role_name: @name)
162
+ end
161
163
  @data = resp.role
162
164
  self
163
165
  end
@@ -272,7 +274,9 @@ module Aws::IAM
272
274
  :retry
273
275
  end
274
276
  end
275
- Aws::Waiters::Waiter.new(options).wait({})
277
+ Aws::Plugins::UserAgent.feature('resource') do
278
+ Aws::Waiters::Waiter.new(options).wait({})
279
+ end
276
280
  end
277
281
 
278
282
  # @!group Actions
@@ -295,7 +299,9 @@ module Aws::IAM
295
299
  # @return [EmptyStructure]
296
300
  def attach_policy(options = {})
297
301
  options = options.merge(role_name: @name)
298
- resp = @client.attach_role_policy(options)
302
+ resp = Aws::Plugins::UserAgent.feature('resource') do
303
+ @client.attach_role_policy(options)
304
+ end
299
305
  resp.data
300
306
  end
301
307
 
@@ -306,7 +312,9 @@ module Aws::IAM
306
312
  # @return [EmptyStructure]
307
313
  def delete(options = {})
308
314
  options = options.merge(role_name: @name)
309
- resp = @client.delete_role(options)
315
+ resp = Aws::Plugins::UserAgent.feature('resource') do
316
+ @client.delete_role(options)
317
+ end
310
318
  resp.data
311
319
  end
312
320
 
@@ -328,7 +336,9 @@ module Aws::IAM
328
336
  # @return [EmptyStructure]
329
337
  def detach_policy(options = {})
330
338
  options = options.merge(role_name: @name)
331
- resp = @client.detach_role_policy(options)
339
+ resp = Aws::Plugins::UserAgent.feature('resource') do
340
+ @client.detach_role_policy(options)
341
+ end
332
342
  resp.data
333
343
  end
334
344
 
@@ -367,7 +377,9 @@ module Aws::IAM
367
377
  def attached_policies(options = {})
368
378
  batches = Enumerator.new do |y|
369
379
  options = options.merge(role_name: @name)
370
- resp = @client.list_attached_role_policies(options)
380
+ resp = Aws::Plugins::UserAgent.feature('resource') do
381
+ @client.list_attached_role_policies(options)
382
+ end
371
383
  resp.each_page do |page|
372
384
  batch = []
373
385
  page.data.attached_policies.each do |a|
@@ -390,7 +402,9 @@ module Aws::IAM
390
402
  def instance_profiles(options = {})
391
403
  batches = Enumerator.new do |y|
392
404
  options = options.merge(role_name: @name)
393
- resp = @client.list_instance_profiles_for_role(options)
405
+ resp = Aws::Plugins::UserAgent.feature('resource') do
406
+ @client.list_instance_profiles_for_role(options)
407
+ end
394
408
  resp.each_page do |page|
395
409
  batch = []
396
410
  page.data.instance_profiles.each do |i|
@@ -414,7 +428,9 @@ module Aws::IAM
414
428
  def policies(options = {})
415
429
  batches = Enumerator.new do |y|
416
430
  options = options.merge(role_name: @name)
417
- resp = @client.list_role_policies(options)
431
+ resp = Aws::Plugins::UserAgent.feature('resource') do
432
+ @client.list_role_policies(options)
433
+ end
418
434
  resp.each_page do |page|
419
435
  batch = []
420
436
  page.data.policy_names.each do |p|
@@ -68,10 +68,12 @@ module Aws::IAM
68
68
  #
69
69
  # @return [self]
70
70
  def load
71
- resp = @client.get_role_policy(
71
+ resp = Aws::Plugins::UserAgent.feature('resource') do
72
+ @client.get_role_policy(
72
73
  role_name: @role_name,
73
74
  policy_name: @name
74
75
  )
76
+ end
75
77
  @data = resp.data
76
78
  self
77
79
  end
@@ -186,7 +188,9 @@ module Aws::IAM
186
188
  :retry
187
189
  end
188
190
  end
189
- Aws::Waiters::Waiter.new(options).wait({})
191
+ Aws::Plugins::UserAgent.feature('resource') do
192
+ Aws::Waiters::Waiter.new(options).wait({})
193
+ end
190
194
  end
191
195
 
192
196
  # @!group Actions
@@ -201,7 +205,9 @@ module Aws::IAM
201
205
  role_name: @role_name,
202
206
  policy_name: @name
203
207
  )
204
- resp = @client.delete_role_policy(options)
208
+ resp = Aws::Plugins::UserAgent.feature('resource') do
209
+ @client.delete_role_policy(options)
210
+ end
205
211
  resp.data
206
212
  end
207
213
 
@@ -240,7 +246,9 @@ module Aws::IAM
240
246
  role_name: @role_name,
241
247
  policy_name: @name
242
248
  )
243
- resp = @client.put_role_policy(options)
249
+ resp = Aws::Plugins::UserAgent.feature('resource') do
250
+ @client.put_role_policy(options)
251
+ end
244
252
  resp.data
245
253
  end
246
254
 
@@ -79,7 +79,9 @@ module Aws::IAM
79
79
  #
80
80
  # @return [self]
81
81
  def load
82
- resp = @client.get_saml_provider(saml_provider_arn: @arn)
82
+ resp = Aws::Plugins::UserAgent.feature('resource') do
83
+ @client.get_saml_provider(saml_provider_arn: @arn)
84
+ end
83
85
  @data = resp.data
84
86
  self
85
87
  end
@@ -194,7 +196,9 @@ module Aws::IAM
194
196
  :retry
195
197
  end
196
198
  end
197
- Aws::Waiters::Waiter.new(options).wait({})
199
+ Aws::Plugins::UserAgent.feature('resource') do
200
+ Aws::Waiters::Waiter.new(options).wait({})
201
+ end
198
202
  end
199
203
 
200
204
  # @!group Actions
@@ -206,7 +210,9 @@ module Aws::IAM
206
210
  # @return [EmptyStructure]
207
211
  def delete(options = {})
208
212
  options = options.merge(saml_provider_arn: @arn)
209
- resp = @client.delete_saml_provider(options)
213
+ resp = Aws::Plugins::UserAgent.feature('resource') do
214
+ @client.delete_saml_provider(options)
215
+ end
210
216
  resp.data
211
217
  end
212
218
 
@@ -226,7 +232,9 @@ module Aws::IAM
226
232
  # @return [Types::UpdateSAMLProviderResponse]
227
233
  def update(options = {})
228
234
  options = options.merge(saml_provider_arn: @arn)
229
- resp = @client.update_saml_provider(options)
235
+ resp = Aws::Plugins::UserAgent.feature('resource') do
236
+ @client.update_saml_provider(options)
237
+ end
230
238
  resp.data
231
239
  end
232
240
 
@@ -79,7 +79,9 @@ module Aws::IAM
79
79
  #
80
80
  # @return [self]
81
81
  def load
82
- resp = @client.get_server_certificate(server_certificate_name: @name)
82
+ resp = Aws::Plugins::UserAgent.feature('resource') do
83
+ @client.get_server_certificate(server_certificate_name: @name)
84
+ end
83
85
  @data = resp.server_certificate
84
86
  self
85
87
  end
@@ -194,7 +196,9 @@ module Aws::IAM
194
196
  :retry
195
197
  end
196
198
  end
197
- Aws::Waiters::Waiter.new(options).wait({})
199
+ Aws::Plugins::UserAgent.feature('resource') do
200
+ Aws::Waiters::Waiter.new(options).wait({})
201
+ end
198
202
  end
199
203
 
200
204
  # @!group Actions
@@ -206,7 +210,9 @@ module Aws::IAM
206
210
  # @return [EmptyStructure]
207
211
  def delete(options = {})
208
212
  options = options.merge(server_certificate_name: @name)
209
- resp = @client.delete_server_certificate(options)
213
+ resp = Aws::Plugins::UserAgent.feature('resource') do
214
+ @client.delete_server_certificate(options)
215
+ end
210
216
  resp.data
211
217
  end
212
218
 
@@ -247,7 +253,9 @@ module Aws::IAM
247
253
  # @return [ServerCertificate]
248
254
  def update(options = {})
249
255
  options = options.merge(server_certificate_name: @name)
250
- @client.update_server_certificate(options)
256
+ Aws::Plugins::UserAgent.feature('resource') do
257
+ @client.update_server_certificate(options)
258
+ end
251
259
  ServerCertificate.new(
252
260
  name: options[:new_server_certificate_name],
253
261
  client: @client
@@ -186,7 +186,9 @@ module Aws::IAM
186
186
  :retry
187
187
  end
188
188
  end
189
- Aws::Waiters::Waiter.new(options).wait({})
189
+ Aws::Plugins::UserAgent.feature('resource') do
190
+ Aws::Waiters::Waiter.new(options).wait({})
191
+ end
190
192
  end
191
193
 
192
194
  # @!group Actions
@@ -202,7 +204,9 @@ module Aws::IAM
202
204
  certificate_id: @id,
203
205
  status: "Active"
204
206
  )
205
- resp = @client.update_signing_certificate(options)
207
+ resp = Aws::Plugins::UserAgent.feature('resource') do
208
+ @client.update_signing_certificate(options)
209
+ end
206
210
  resp.data
207
211
  end
208
212
 
@@ -217,7 +221,9 @@ module Aws::IAM
217
221
  certificate_id: @id,
218
222
  status: "Inactive"
219
223
  )
220
- resp = @client.update_signing_certificate(options)
224
+ resp = Aws::Plugins::UserAgent.feature('resource') do
225
+ @client.update_signing_certificate(options)
226
+ end
221
227
  resp.data
222
228
  end
223
229
 
@@ -231,7 +237,9 @@ module Aws::IAM
231
237
  user_name: @user_name,
232
238
  certificate_id: @id
233
239
  )
234
- resp = @client.delete_signing_certificate(options)
240
+ resp = Aws::Plugins::UserAgent.feature('resource') do
241
+ @client.delete_signing_certificate(options)
242
+ end
235
243
  resp.data
236
244
  end
237
245
 
@@ -11835,7 +11835,7 @@ module Aws::IAM
11835
11835
  #
11836
11836
  # @!attribute [rw] base_32_string_seed
11837
11837
  # The base32 seed defined as specified in [RFC3548][1]. The
11838
- # `Base32StringSeed` is base64-encoded.
11838
+ # `Base32StringSeed` is base32-encoded.
11839
11839
  #
11840
11840
  #
11841
11841
  #