aws-sdk-sns 1.38.0 → 1.46.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,7 +3,7 @@
3
3
  # WARNING ABOUT GENERATED CODE
4
4
  #
5
5
  # This file is generated. See the contributing guide for more information:
6
- # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
7
7
  #
8
8
  # WARNING ABOUT GENERATED CODE
9
9
 
@@ -27,11 +27,15 @@ module Aws::SNS
27
27
  CreatePlatformApplicationInput = Shapes::StructureShape.new(name: 'CreatePlatformApplicationInput')
28
28
  CreatePlatformApplicationResponse = Shapes::StructureShape.new(name: 'CreatePlatformApplicationResponse')
29
29
  CreatePlatformEndpointInput = Shapes::StructureShape.new(name: 'CreatePlatformEndpointInput')
30
+ CreateSMSSandboxPhoneNumberInput = Shapes::StructureShape.new(name: 'CreateSMSSandboxPhoneNumberInput')
31
+ CreateSMSSandboxPhoneNumberResult = Shapes::StructureShape.new(name: 'CreateSMSSandboxPhoneNumberResult')
30
32
  CreateTopicInput = Shapes::StructureShape.new(name: 'CreateTopicInput')
31
33
  CreateTopicResponse = Shapes::StructureShape.new(name: 'CreateTopicResponse')
32
34
  DelegatesList = Shapes::ListShape.new(name: 'DelegatesList')
33
35
  DeleteEndpointInput = Shapes::StructureShape.new(name: 'DeleteEndpointInput')
34
36
  DeletePlatformApplicationInput = Shapes::StructureShape.new(name: 'DeletePlatformApplicationInput')
37
+ DeleteSMSSandboxPhoneNumberInput = Shapes::StructureShape.new(name: 'DeleteSMSSandboxPhoneNumberInput')
38
+ DeleteSMSSandboxPhoneNumberResult = Shapes::StructureShape.new(name: 'DeleteSMSSandboxPhoneNumberResult')
35
39
  DeleteTopicInput = Shapes::StructureShape.new(name: 'DeleteTopicInput')
36
40
  Endpoint = Shapes::StructureShape.new(name: 'Endpoint')
37
41
  EndpointDisabledException = Shapes::StructureShape.new(name: 'EndpointDisabledException')
@@ -42,6 +46,8 @@ module Aws::SNS
42
46
  GetPlatformApplicationAttributesResponse = Shapes::StructureShape.new(name: 'GetPlatformApplicationAttributesResponse')
43
47
  GetSMSAttributesInput = Shapes::StructureShape.new(name: 'GetSMSAttributesInput')
44
48
  GetSMSAttributesResponse = Shapes::StructureShape.new(name: 'GetSMSAttributesResponse')
49
+ GetSMSSandboxAccountStatusInput = Shapes::StructureShape.new(name: 'GetSMSSandboxAccountStatusInput')
50
+ GetSMSSandboxAccountStatusResult = Shapes::StructureShape.new(name: 'GetSMSSandboxAccountStatusResult')
45
51
  GetSubscriptionAttributesInput = Shapes::StructureShape.new(name: 'GetSubscriptionAttributesInput')
46
52
  GetSubscriptionAttributesResponse = Shapes::StructureShape.new(name: 'GetSubscriptionAttributesResponse')
47
53
  GetTopicAttributesInput = Shapes::StructureShape.new(name: 'GetTopicAttributesInput')
@@ -50,20 +56,26 @@ module Aws::SNS
50
56
  InvalidParameterException = Shapes::StructureShape.new(name: 'InvalidParameterException')
51
57
  InvalidParameterValueException = Shapes::StructureShape.new(name: 'InvalidParameterValueException')
52
58
  InvalidSecurityException = Shapes::StructureShape.new(name: 'InvalidSecurityException')
59
+ Iso2CountryCode = Shapes::StringShape.new(name: 'Iso2CountryCode')
53
60
  KMSAccessDeniedException = Shapes::StructureShape.new(name: 'KMSAccessDeniedException')
54
61
  KMSDisabledException = Shapes::StructureShape.new(name: 'KMSDisabledException')
55
62
  KMSInvalidStateException = Shapes::StructureShape.new(name: 'KMSInvalidStateException')
56
63
  KMSNotFoundException = Shapes::StructureShape.new(name: 'KMSNotFoundException')
57
64
  KMSOptInRequired = Shapes::StructureShape.new(name: 'KMSOptInRequired')
58
65
  KMSThrottlingException = Shapes::StructureShape.new(name: 'KMSThrottlingException')
66
+ LanguageCodeString = Shapes::StringShape.new(name: 'LanguageCodeString')
59
67
  ListEndpointsByPlatformApplicationInput = Shapes::StructureShape.new(name: 'ListEndpointsByPlatformApplicationInput')
60
68
  ListEndpointsByPlatformApplicationResponse = Shapes::StructureShape.new(name: 'ListEndpointsByPlatformApplicationResponse')
61
69
  ListOfEndpoints = Shapes::ListShape.new(name: 'ListOfEndpoints')
62
70
  ListOfPlatformApplications = Shapes::ListShape.new(name: 'ListOfPlatformApplications')
71
+ ListOriginationNumbersRequest = Shapes::StructureShape.new(name: 'ListOriginationNumbersRequest')
72
+ ListOriginationNumbersResult = Shapes::StructureShape.new(name: 'ListOriginationNumbersResult')
63
73
  ListPhoneNumbersOptedOutInput = Shapes::StructureShape.new(name: 'ListPhoneNumbersOptedOutInput')
64
74
  ListPhoneNumbersOptedOutResponse = Shapes::StructureShape.new(name: 'ListPhoneNumbersOptedOutResponse')
65
75
  ListPlatformApplicationsInput = Shapes::StructureShape.new(name: 'ListPlatformApplicationsInput')
66
76
  ListPlatformApplicationsResponse = Shapes::StructureShape.new(name: 'ListPlatformApplicationsResponse')
77
+ ListSMSSandboxPhoneNumbersInput = Shapes::StructureShape.new(name: 'ListSMSSandboxPhoneNumbersInput')
78
+ ListSMSSandboxPhoneNumbersResult = Shapes::StructureShape.new(name: 'ListSMSSandboxPhoneNumbersResult')
67
79
  ListString = Shapes::ListShape.new(name: 'ListString')
68
80
  ListSubscriptionsByTopicInput = Shapes::StructureShape.new(name: 'ListSubscriptionsByTopicInput')
69
81
  ListSubscriptionsByTopicResponse = Shapes::StructureShape.new(name: 'ListSubscriptionsByTopicResponse')
@@ -74,19 +86,32 @@ module Aws::SNS
74
86
  ListTopicsInput = Shapes::StructureShape.new(name: 'ListTopicsInput')
75
87
  ListTopicsResponse = Shapes::StructureShape.new(name: 'ListTopicsResponse')
76
88
  MapStringToString = Shapes::MapShape.new(name: 'MapStringToString')
89
+ MaxItems = Shapes::IntegerShape.new(name: 'MaxItems')
90
+ MaxItemsListOriginationNumbers = Shapes::IntegerShape.new(name: 'MaxItemsListOriginationNumbers')
77
91
  MessageAttributeMap = Shapes::MapShape.new(name: 'MessageAttributeMap')
78
92
  MessageAttributeValue = Shapes::StructureShape.new(name: 'MessageAttributeValue')
79
93
  NotFoundException = Shapes::StructureShape.new(name: 'NotFoundException')
94
+ NumberCapability = Shapes::StringShape.new(name: 'NumberCapability')
95
+ NumberCapabilityList = Shapes::ListShape.new(name: 'NumberCapabilityList')
96
+ OTPCode = Shapes::StringShape.new(name: 'OTPCode')
80
97
  OptInPhoneNumberInput = Shapes::StructureShape.new(name: 'OptInPhoneNumberInput')
81
98
  OptInPhoneNumberResponse = Shapes::StructureShape.new(name: 'OptInPhoneNumberResponse')
99
+ OptedOutException = Shapes::StructureShape.new(name: 'OptedOutException')
82
100
  PhoneNumber = Shapes::StringShape.new(name: 'PhoneNumber')
101
+ PhoneNumberInformation = Shapes::StructureShape.new(name: 'PhoneNumberInformation')
102
+ PhoneNumberInformationList = Shapes::ListShape.new(name: 'PhoneNumberInformationList')
83
103
  PhoneNumberList = Shapes::ListShape.new(name: 'PhoneNumberList')
104
+ PhoneNumberString = Shapes::StringShape.new(name: 'PhoneNumberString')
84
105
  PlatformApplication = Shapes::StructureShape.new(name: 'PlatformApplication')
85
106
  PlatformApplicationDisabledException = Shapes::StructureShape.new(name: 'PlatformApplicationDisabledException')
86
107
  PublishInput = Shapes::StructureShape.new(name: 'PublishInput')
87
108
  PublishResponse = Shapes::StructureShape.new(name: 'PublishResponse')
88
109
  RemovePermissionInput = Shapes::StructureShape.new(name: 'RemovePermissionInput')
89
110
  ResourceNotFoundException = Shapes::StructureShape.new(name: 'ResourceNotFoundException')
111
+ RouteType = Shapes::StringShape.new(name: 'RouteType')
112
+ SMSSandboxPhoneNumber = Shapes::StructureShape.new(name: 'SMSSandboxPhoneNumber')
113
+ SMSSandboxPhoneNumberList = Shapes::ListShape.new(name: 'SMSSandboxPhoneNumberList')
114
+ SMSSandboxPhoneNumberVerificationStatus = Shapes::StringShape.new(name: 'SMSSandboxPhoneNumberVerificationStatus')
90
115
  SetEndpointAttributesInput = Shapes::StructureShape.new(name: 'SetEndpointAttributesInput')
91
116
  SetPlatformApplicationAttributesInput = Shapes::StructureShape.new(name: 'SetPlatformApplicationAttributesInput')
92
117
  SetSMSAttributesInput = Shapes::StructureShape.new(name: 'SetSMSAttributesInput')
@@ -111,6 +136,7 @@ module Aws::SNS
111
136
  TagResourceResponse = Shapes::StructureShape.new(name: 'TagResourceResponse')
112
137
  TagValue = Shapes::StringShape.new(name: 'TagValue')
113
138
  ThrottledException = Shapes::StructureShape.new(name: 'ThrottledException')
139
+ Timestamp = Shapes::TimestampShape.new(name: 'Timestamp')
114
140
  Topic = Shapes::StructureShape.new(name: 'Topic')
115
141
  TopicAttributesMap = Shapes::MapShape.new(name: 'TopicAttributesMap')
116
142
  TopicLimitExceededException = Shapes::StructureShape.new(name: 'TopicLimitExceededException')
@@ -118,6 +144,11 @@ module Aws::SNS
118
144
  UnsubscribeInput = Shapes::StructureShape.new(name: 'UnsubscribeInput')
119
145
  UntagResourceRequest = Shapes::StructureShape.new(name: 'UntagResourceRequest')
120
146
  UntagResourceResponse = Shapes::StructureShape.new(name: 'UntagResourceResponse')
147
+ UserErrorException = Shapes::StructureShape.new(name: 'UserErrorException')
148
+ ValidationException = Shapes::StructureShape.new(name: 'ValidationException')
149
+ VerificationException = Shapes::StructureShape.new(name: 'VerificationException')
150
+ VerifySMSSandboxPhoneNumberInput = Shapes::StructureShape.new(name: 'VerifySMSSandboxPhoneNumberInput')
151
+ VerifySMSSandboxPhoneNumberResult = Shapes::StructureShape.new(name: 'VerifySMSSandboxPhoneNumberResult')
121
152
  account = Shapes::StringShape.new(name: 'account')
122
153
  action = Shapes::StringShape.new(name: 'action')
123
154
  attributeName = Shapes::StringShape.new(name: 'attributeName')
@@ -184,6 +215,12 @@ module Aws::SNS
184
215
  CreatePlatformEndpointInput.add_member(:attributes, Shapes::ShapeRef.new(shape: MapStringToString, location_name: "Attributes"))
185
216
  CreatePlatformEndpointInput.struct_class = Types::CreatePlatformEndpointInput
186
217
 
218
+ CreateSMSSandboxPhoneNumberInput.add_member(:phone_number, Shapes::ShapeRef.new(shape: PhoneNumberString, required: true, location_name: "PhoneNumber"))
219
+ CreateSMSSandboxPhoneNumberInput.add_member(:language_code, Shapes::ShapeRef.new(shape: LanguageCodeString, location_name: "LanguageCode"))
220
+ CreateSMSSandboxPhoneNumberInput.struct_class = Types::CreateSMSSandboxPhoneNumberInput
221
+
222
+ CreateSMSSandboxPhoneNumberResult.struct_class = Types::CreateSMSSandboxPhoneNumberResult
223
+
187
224
  CreateTopicInput.add_member(:name, Shapes::ShapeRef.new(shape: topicName, required: true, location_name: "Name"))
188
225
  CreateTopicInput.add_member(:attributes, Shapes::ShapeRef.new(shape: TopicAttributesMap, location_name: "Attributes"))
189
226
  CreateTopicInput.add_member(:tags, Shapes::ShapeRef.new(shape: TagList, location_name: "Tags"))
@@ -200,6 +237,11 @@ module Aws::SNS
200
237
  DeletePlatformApplicationInput.add_member(:platform_application_arn, Shapes::ShapeRef.new(shape: String, required: true, location_name: "PlatformApplicationArn"))
201
238
  DeletePlatformApplicationInput.struct_class = Types::DeletePlatformApplicationInput
202
239
 
240
+ DeleteSMSSandboxPhoneNumberInput.add_member(:phone_number, Shapes::ShapeRef.new(shape: PhoneNumberString, required: true, location_name: "PhoneNumber"))
241
+ DeleteSMSSandboxPhoneNumberInput.struct_class = Types::DeleteSMSSandboxPhoneNumberInput
242
+
243
+ DeleteSMSSandboxPhoneNumberResult.struct_class = Types::DeleteSMSSandboxPhoneNumberResult
244
+
203
245
  DeleteTopicInput.add_member(:topic_arn, Shapes::ShapeRef.new(shape: topicARN, required: true, location_name: "TopicArn"))
204
246
  DeleteTopicInput.struct_class = Types::DeleteTopicInput
205
247
 
@@ -231,6 +273,11 @@ module Aws::SNS
231
273
  GetSMSAttributesResponse.add_member(:attributes, Shapes::ShapeRef.new(shape: MapStringToString, location_name: "attributes"))
232
274
  GetSMSAttributesResponse.struct_class = Types::GetSMSAttributesResponse
233
275
 
276
+ GetSMSSandboxAccountStatusInput.struct_class = Types::GetSMSSandboxAccountStatusInput
277
+
278
+ GetSMSSandboxAccountStatusResult.add_member(:is_in_sandbox, Shapes::ShapeRef.new(shape: boolean, required: true, location_name: "IsInSandbox"))
279
+ GetSMSSandboxAccountStatusResult.struct_class = Types::GetSMSSandboxAccountStatusResult
280
+
234
281
  GetSubscriptionAttributesInput.add_member(:subscription_arn, Shapes::ShapeRef.new(shape: subscriptionARN, required: true, location_name: "SubscriptionArn"))
235
282
  GetSubscriptionAttributesInput.struct_class = Types::GetSubscriptionAttributesInput
236
283
 
@@ -285,6 +332,14 @@ module Aws::SNS
285
332
 
286
333
  ListOfPlatformApplications.member = Shapes::ShapeRef.new(shape: PlatformApplication)
287
334
 
335
+ ListOriginationNumbersRequest.add_member(:next_token, Shapes::ShapeRef.new(shape: nextToken, location_name: "NextToken"))
336
+ ListOriginationNumbersRequest.add_member(:max_results, Shapes::ShapeRef.new(shape: MaxItemsListOriginationNumbers, location_name: "MaxResults"))
337
+ ListOriginationNumbersRequest.struct_class = Types::ListOriginationNumbersRequest
338
+
339
+ ListOriginationNumbersResult.add_member(:next_token, Shapes::ShapeRef.new(shape: nextToken, location_name: "NextToken"))
340
+ ListOriginationNumbersResult.add_member(:phone_numbers, Shapes::ShapeRef.new(shape: PhoneNumberInformationList, location_name: "PhoneNumbers"))
341
+ ListOriginationNumbersResult.struct_class = Types::ListOriginationNumbersResult
342
+
288
343
  ListPhoneNumbersOptedOutInput.add_member(:next_token, Shapes::ShapeRef.new(shape: string, location_name: "nextToken"))
289
344
  ListPhoneNumbersOptedOutInput.struct_class = Types::ListPhoneNumbersOptedOutInput
290
345
 
@@ -299,6 +354,14 @@ module Aws::SNS
299
354
  ListPlatformApplicationsResponse.add_member(:next_token, Shapes::ShapeRef.new(shape: String, location_name: "NextToken"))
300
355
  ListPlatformApplicationsResponse.struct_class = Types::ListPlatformApplicationsResponse
301
356
 
357
+ ListSMSSandboxPhoneNumbersInput.add_member(:next_token, Shapes::ShapeRef.new(shape: nextToken, location_name: "NextToken"))
358
+ ListSMSSandboxPhoneNumbersInput.add_member(:max_results, Shapes::ShapeRef.new(shape: MaxItems, location_name: "MaxResults"))
359
+ ListSMSSandboxPhoneNumbersInput.struct_class = Types::ListSMSSandboxPhoneNumbersInput
360
+
361
+ ListSMSSandboxPhoneNumbersResult.add_member(:phone_numbers, Shapes::ShapeRef.new(shape: SMSSandboxPhoneNumberList, required: true, location_name: "PhoneNumbers"))
362
+ ListSMSSandboxPhoneNumbersResult.add_member(:next_token, Shapes::ShapeRef.new(shape: string, location_name: "NextToken"))
363
+ ListSMSSandboxPhoneNumbersResult.struct_class = Types::ListSMSSandboxPhoneNumbersResult
364
+
302
365
  ListString.member = Shapes::ShapeRef.new(shape: String)
303
366
 
304
367
  ListSubscriptionsByTopicInput.add_member(:topic_arn, Shapes::ShapeRef.new(shape: topicARN, required: true, location_name: "TopicArn"))
@@ -343,11 +406,26 @@ module Aws::SNS
343
406
  NotFoundException.add_member(:message, Shapes::ShapeRef.new(shape: string, location_name: "message"))
344
407
  NotFoundException.struct_class = Types::NotFoundException
345
408
 
409
+ NumberCapabilityList.member = Shapes::ShapeRef.new(shape: NumberCapability)
410
+
346
411
  OptInPhoneNumberInput.add_member(:phone_number, Shapes::ShapeRef.new(shape: PhoneNumber, required: true, location_name: "phoneNumber"))
347
412
  OptInPhoneNumberInput.struct_class = Types::OptInPhoneNumberInput
348
413
 
349
414
  OptInPhoneNumberResponse.struct_class = Types::OptInPhoneNumberResponse
350
415
 
416
+ OptedOutException.add_member(:message, Shapes::ShapeRef.new(shape: string, location_name: "message"))
417
+ OptedOutException.struct_class = Types::OptedOutException
418
+
419
+ PhoneNumberInformation.add_member(:created_at, Shapes::ShapeRef.new(shape: Timestamp, location_name: "CreatedAt"))
420
+ PhoneNumberInformation.add_member(:phone_number, Shapes::ShapeRef.new(shape: String, location_name: "PhoneNumber"))
421
+ PhoneNumberInformation.add_member(:status, Shapes::ShapeRef.new(shape: String, location_name: "Status"))
422
+ PhoneNumberInformation.add_member(:iso_2_country_code, Shapes::ShapeRef.new(shape: Iso2CountryCode, location_name: "Iso2CountryCode"))
423
+ PhoneNumberInformation.add_member(:route_type, Shapes::ShapeRef.new(shape: RouteType, location_name: "RouteType"))
424
+ PhoneNumberInformation.add_member(:number_capabilities, Shapes::ShapeRef.new(shape: NumberCapabilityList, location_name: "NumberCapabilities"))
425
+ PhoneNumberInformation.struct_class = Types::PhoneNumberInformation
426
+
427
+ PhoneNumberInformationList.member = Shapes::ShapeRef.new(shape: PhoneNumberInformation)
428
+
351
429
  PhoneNumberList.member = Shapes::ShapeRef.new(shape: PhoneNumber)
352
430
 
353
431
  PlatformApplication.add_member(:platform_application_arn, Shapes::ShapeRef.new(shape: String, location_name: "PlatformApplicationArn"))
@@ -379,6 +457,12 @@ module Aws::SNS
379
457
  ResourceNotFoundException.add_member(:message, Shapes::ShapeRef.new(shape: string, location_name: "message"))
380
458
  ResourceNotFoundException.struct_class = Types::ResourceNotFoundException
381
459
 
460
+ SMSSandboxPhoneNumber.add_member(:phone_number, Shapes::ShapeRef.new(shape: PhoneNumberString, location_name: "PhoneNumber"))
461
+ SMSSandboxPhoneNumber.add_member(:status, Shapes::ShapeRef.new(shape: SMSSandboxPhoneNumberVerificationStatus, location_name: "Status"))
462
+ SMSSandboxPhoneNumber.struct_class = Types::SMSSandboxPhoneNumber
463
+
464
+ SMSSandboxPhoneNumberList.member = Shapes::ShapeRef.new(shape: SMSSandboxPhoneNumber)
465
+
382
466
  SetEndpointAttributesInput.add_member(:endpoint_arn, Shapes::ShapeRef.new(shape: String, required: true, location_name: "EndpointArn"))
383
467
  SetEndpointAttributesInput.add_member(:attributes, Shapes::ShapeRef.new(shape: MapStringToString, required: true, location_name: "Attributes"))
384
468
  SetEndpointAttributesInput.struct_class = Types::SetEndpointAttributesInput
@@ -473,6 +557,22 @@ module Aws::SNS
473
557
 
474
558
  UntagResourceResponse.struct_class = Types::UntagResourceResponse
475
559
 
560
+ UserErrorException.add_member(:message, Shapes::ShapeRef.new(shape: string, location_name: "message"))
561
+ UserErrorException.struct_class = Types::UserErrorException
562
+
563
+ ValidationException.add_member(:message, Shapes::ShapeRef.new(shape: string, required: true, location_name: "Message"))
564
+ ValidationException.struct_class = Types::ValidationException
565
+
566
+ VerificationException.add_member(:message, Shapes::ShapeRef.new(shape: string, required: true, location_name: "Message"))
567
+ VerificationException.add_member(:status, Shapes::ShapeRef.new(shape: string, required: true, location_name: "Status"))
568
+ VerificationException.struct_class = Types::VerificationException
569
+
570
+ VerifySMSSandboxPhoneNumberInput.add_member(:phone_number, Shapes::ShapeRef.new(shape: PhoneNumberString, required: true, location_name: "PhoneNumber"))
571
+ VerifySMSSandboxPhoneNumberInput.add_member(:one_time_password, Shapes::ShapeRef.new(shape: OTPCode, required: true, location_name: "OneTimePassword"))
572
+ VerifySMSSandboxPhoneNumberInput.struct_class = Types::VerifySMSSandboxPhoneNumberInput
573
+
574
+ VerifySMSSandboxPhoneNumberResult.struct_class = Types::VerifySMSSandboxPhoneNumberResult
575
+
476
576
 
477
577
  # @api private
478
578
  API = Seahorse::Model::Api.new.tap do |api|
@@ -552,6 +652,20 @@ module Aws::SNS
552
652
  o.errors << Shapes::ShapeRef.new(shape: NotFoundException)
553
653
  end)
554
654
 
655
+ api.add_operation(:create_sms_sandbox_phone_number, Seahorse::Model::Operation.new.tap do |o|
656
+ o.name = "CreateSMSSandboxPhoneNumber"
657
+ o.http_method = "POST"
658
+ o.http_request_uri = "/"
659
+ o.input = Shapes::ShapeRef.new(shape: CreateSMSSandboxPhoneNumberInput)
660
+ o.output = Shapes::ShapeRef.new(shape: CreateSMSSandboxPhoneNumberResult)
661
+ o.errors << Shapes::ShapeRef.new(shape: AuthorizationErrorException)
662
+ o.errors << Shapes::ShapeRef.new(shape: InternalErrorException)
663
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
664
+ o.errors << Shapes::ShapeRef.new(shape: OptedOutException)
665
+ o.errors << Shapes::ShapeRef.new(shape: UserErrorException)
666
+ o.errors << Shapes::ShapeRef.new(shape: ThrottledException)
667
+ end)
668
+
555
669
  api.add_operation(:create_topic, Seahorse::Model::Operation.new.tap do |o|
556
670
  o.name = "CreateTopic"
557
671
  o.http_method = "POST"
@@ -591,6 +705,20 @@ module Aws::SNS
591
705
  o.errors << Shapes::ShapeRef.new(shape: AuthorizationErrorException)
592
706
  end)
593
707
 
708
+ api.add_operation(:delete_sms_sandbox_phone_number, Seahorse::Model::Operation.new.tap do |o|
709
+ o.name = "DeleteSMSSandboxPhoneNumber"
710
+ o.http_method = "POST"
711
+ o.http_request_uri = "/"
712
+ o.input = Shapes::ShapeRef.new(shape: DeleteSMSSandboxPhoneNumberInput)
713
+ o.output = Shapes::ShapeRef.new(shape: DeleteSMSSandboxPhoneNumberResult)
714
+ o.errors << Shapes::ShapeRef.new(shape: AuthorizationErrorException)
715
+ o.errors << Shapes::ShapeRef.new(shape: InternalErrorException)
716
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
717
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
718
+ o.errors << Shapes::ShapeRef.new(shape: UserErrorException)
719
+ o.errors << Shapes::ShapeRef.new(shape: ThrottledException)
720
+ end)
721
+
594
722
  api.add_operation(:delete_topic, Seahorse::Model::Operation.new.tap do |o|
595
723
  o.name = "DeleteTopic"
596
724
  o.http_method = "POST"
@@ -642,6 +770,17 @@ module Aws::SNS
642
770
  o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
643
771
  end)
644
772
 
773
+ api.add_operation(:get_sms_sandbox_account_status, Seahorse::Model::Operation.new.tap do |o|
774
+ o.name = "GetSMSSandboxAccountStatus"
775
+ o.http_method = "POST"
776
+ o.http_request_uri = "/"
777
+ o.input = Shapes::ShapeRef.new(shape: GetSMSSandboxAccountStatusInput)
778
+ o.output = Shapes::ShapeRef.new(shape: GetSMSSandboxAccountStatusResult)
779
+ o.errors << Shapes::ShapeRef.new(shape: AuthorizationErrorException)
780
+ o.errors << Shapes::ShapeRef.new(shape: InternalErrorException)
781
+ o.errors << Shapes::ShapeRef.new(shape: ThrottledException)
782
+ end)
783
+
645
784
  api.add_operation(:get_subscription_attributes, Seahorse::Model::Operation.new.tap do |o|
646
785
  o.name = "GetSubscriptionAttributes"
647
786
  o.http_method = "POST"
@@ -684,6 +823,25 @@ module Aws::SNS
684
823
  )
685
824
  end)
686
825
 
826
+ api.add_operation(:list_origination_numbers, Seahorse::Model::Operation.new.tap do |o|
827
+ o.name = "ListOriginationNumbers"
828
+ o.http_method = "POST"
829
+ o.http_request_uri = "/"
830
+ o.input = Shapes::ShapeRef.new(shape: ListOriginationNumbersRequest)
831
+ o.output = Shapes::ShapeRef.new(shape: ListOriginationNumbersResult)
832
+ o.errors << Shapes::ShapeRef.new(shape: InternalErrorException)
833
+ o.errors << Shapes::ShapeRef.new(shape: AuthorizationErrorException)
834
+ o.errors << Shapes::ShapeRef.new(shape: ThrottledException)
835
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
836
+ o.errors << Shapes::ShapeRef.new(shape: ValidationException)
837
+ o[:pager] = Aws::Pager.new(
838
+ limit_key: "max_results",
839
+ tokens: {
840
+ "next_token" => "next_token"
841
+ }
842
+ )
843
+ end)
844
+
687
845
  api.add_operation(:list_phone_numbers_opted_out, Seahorse::Model::Operation.new.tap do |o|
688
846
  o.name = "ListPhoneNumbersOptedOut"
689
847
  o.http_method = "POST"
@@ -694,6 +852,11 @@ module Aws::SNS
694
852
  o.errors << Shapes::ShapeRef.new(shape: InternalErrorException)
695
853
  o.errors << Shapes::ShapeRef.new(shape: AuthorizationErrorException)
696
854
  o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
855
+ o[:pager] = Aws::Pager.new(
856
+ tokens: {
857
+ "next_token" => "next_token"
858
+ }
859
+ )
697
860
  end)
698
861
 
699
862
  api.add_operation(:list_platform_applications, Seahorse::Model::Operation.new.tap do |o|
@@ -712,6 +875,25 @@ module Aws::SNS
712
875
  )
713
876
  end)
714
877
 
878
+ api.add_operation(:list_sms_sandbox_phone_numbers, Seahorse::Model::Operation.new.tap do |o|
879
+ o.name = "ListSMSSandboxPhoneNumbers"
880
+ o.http_method = "POST"
881
+ o.http_request_uri = "/"
882
+ o.input = Shapes::ShapeRef.new(shape: ListSMSSandboxPhoneNumbersInput)
883
+ o.output = Shapes::ShapeRef.new(shape: ListSMSSandboxPhoneNumbersResult)
884
+ o.errors << Shapes::ShapeRef.new(shape: AuthorizationErrorException)
885
+ o.errors << Shapes::ShapeRef.new(shape: InternalErrorException)
886
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
887
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
888
+ o.errors << Shapes::ShapeRef.new(shape: ThrottledException)
889
+ o[:pager] = Aws::Pager.new(
890
+ limit_key: "max_results",
891
+ tokens: {
892
+ "next_token" => "next_token"
893
+ }
894
+ )
895
+ end)
896
+
715
897
  api.add_operation(:list_subscriptions, Seahorse::Model::Operation.new.tap do |o|
716
898
  o.name = "ListSubscriptions"
717
899
  o.http_method = "POST"
@@ -939,6 +1121,20 @@ module Aws::SNS
939
1121
  o.errors << Shapes::ShapeRef.new(shape: AuthorizationErrorException)
940
1122
  o.errors << Shapes::ShapeRef.new(shape: ConcurrentAccessException)
941
1123
  end)
1124
+
1125
+ api.add_operation(:verify_sms_sandbox_phone_number, Seahorse::Model::Operation.new.tap do |o|
1126
+ o.name = "VerifySMSSandboxPhoneNumber"
1127
+ o.http_method = "POST"
1128
+ o.http_request_uri = "/"
1129
+ o.input = Shapes::ShapeRef.new(shape: VerifySMSSandboxPhoneNumberInput)
1130
+ o.output = Shapes::ShapeRef.new(shape: VerifySMSSandboxPhoneNumberResult)
1131
+ o.errors << Shapes::ShapeRef.new(shape: AuthorizationErrorException)
1132
+ o.errors << Shapes::ShapeRef.new(shape: InternalErrorException)
1133
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
1134
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
1135
+ o.errors << Shapes::ShapeRef.new(shape: VerificationException)
1136
+ o.errors << Shapes::ShapeRef.new(shape: ThrottledException)
1137
+ end)
942
1138
  end
943
1139
 
944
1140
  end
@@ -3,7 +3,7 @@
3
3
  # WARNING ABOUT GENERATED CODE
4
4
  #
5
5
  # This file is generated. See the contributing guide for more information:
6
- # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
7
7
  #
8
8
  # WARNING ABOUT GENERATED CODE
9
9
 
@@ -42,6 +42,7 @@ module Aws::SNS
42
42
  # * {KMSOptInRequired}
43
43
  # * {KMSThrottlingException}
44
44
  # * {NotFoundException}
45
+ # * {OptedOutException}
45
46
  # * {PlatformApplicationDisabledException}
46
47
  # * {ResourceNotFoundException}
47
48
  # * {StaleTagException}
@@ -50,6 +51,9 @@ module Aws::SNS
50
51
  # * {TagPolicyException}
51
52
  # * {ThrottledException}
52
53
  # * {TopicLimitExceededException}
54
+ # * {UserErrorException}
55
+ # * {ValidationException}
56
+ # * {VerificationException}
53
57
  #
54
58
  # Additionally, error classes are dynamically generated for service errors based on the error code
55
59
  # if they are not defined above.
@@ -282,6 +286,21 @@ module Aws::SNS
282
286
  end
283
287
  end
284
288
 
289
+ class OptedOutException < ServiceError
290
+
291
+ # @param [Seahorse::Client::RequestContext] context
292
+ # @param [String] message
293
+ # @param [Aws::SNS::Types::OptedOutException] data
294
+ def initialize(context, message, data = Aws::EmptyStructure.new)
295
+ super(context, message, data)
296
+ end
297
+
298
+ # @return [String]
299
+ def message
300
+ @message || @data[:message]
301
+ end
302
+ end
303
+
285
304
  class PlatformApplicationDisabledException < ServiceError
286
305
 
287
306
  # @param [Seahorse::Client::RequestContext] context
@@ -402,5 +421,55 @@ module Aws::SNS
402
421
  end
403
422
  end
404
423
 
424
+ class UserErrorException < ServiceError
425
+
426
+ # @param [Seahorse::Client::RequestContext] context
427
+ # @param [String] message
428
+ # @param [Aws::SNS::Types::UserErrorException] data
429
+ def initialize(context, message, data = Aws::EmptyStructure.new)
430
+ super(context, message, data)
431
+ end
432
+
433
+ # @return [String]
434
+ def message
435
+ @message || @data[:message]
436
+ end
437
+ end
438
+
439
+ class ValidationException < ServiceError
440
+
441
+ # @param [Seahorse::Client::RequestContext] context
442
+ # @param [String] message
443
+ # @param [Aws::SNS::Types::ValidationException] data
444
+ def initialize(context, message, data = Aws::EmptyStructure.new)
445
+ super(context, message, data)
446
+ end
447
+
448
+ # @return [String]
449
+ def message
450
+ @message || @data[:message]
451
+ end
452
+ end
453
+
454
+ class VerificationException < ServiceError
455
+
456
+ # @param [Seahorse::Client::RequestContext] context
457
+ # @param [String] message
458
+ # @param [Aws::SNS::Types::VerificationException] data
459
+ def initialize(context, message, data = Aws::EmptyStructure.new)
460
+ super(context, message, data)
461
+ end
462
+
463
+ # @return [String]
464
+ def message
465
+ @message || @data[:message]
466
+ end
467
+
468
+ # @return [String]
469
+ def status
470
+ @data[:status]
471
+ end
472
+ end
473
+
405
474
  end
406
475
  end
@@ -123,7 +123,9 @@ module Aws
123
123
 
124
124
  def download_pem(uri)
125
125
  verify_uri!(uri)
126
- https_get(uri)
126
+ pem = https_get(uri)
127
+ verify_pem_format!(pem)
128
+ pem
127
129
  end
128
130
 
129
131
  def verify_uri!(uri)
@@ -153,6 +155,14 @@ module Aws
153
155
  end
154
156
  end
155
157
 
158
+ def verify_pem_format!(pem)
159
+ cert_regex = /\A[\s]*-----BEGIN [A-Z]+-----\n[A-Za-z\d+\/\n]+[=]{0,2}\n-----END [A-Z]+-----[\s]*\Z/
160
+ unless pem =~ cert_regex
161
+ msg = 'The certificate does not match expected X509 PEM format.'
162
+ raise VerificationError, msg
163
+ end
164
+ end
165
+
156
166
  def https_get(uri, failed_attempts = 0)
157
167
  args = []
158
168
  args << uri.host
@@ -3,7 +3,7 @@
3
3
  # WARNING ABOUT GENERATED CODE
4
4
  #
5
5
  # This file is generated. See the contributing guide for more information:
6
- # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
7
7
  #
8
8
  # WARNING ABOUT GENERATED CODE
9
9
 
@@ -3,7 +3,7 @@
3
3
  # WARNING ABOUT GENERATED CODE
4
4
  #
5
5
  # This file is generated. See the contributing guide for more information:
6
- # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
7
7
  #
8
8
  # WARNING ABOUT GENERATED CODE
9
9
 
@@ -3,7 +3,7 @@
3
3
  # WARNING ABOUT GENERATED CODE
4
4
  #
5
5
  # This file is generated. See the contributing guide for more information:
6
- # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
7
7
  #
8
8
  # WARNING ABOUT GENERATED CODE
9
9
 
@@ -54,7 +54,7 @@ module Aws::SNS
54
54
  # APNS (Apple Push Notification Service), APNS\_SANDBOX, and GCM
55
55
  # (Firebase Cloud Messaging).
56
56
  # @option options [required, Hash<String,String>] :attributes
57
- # For a list of attributes, see [SetPlatformApplicationAttributes][1]
57
+ # For a list of attributes, see [SetPlatformApplicationAttributes][1].
58
58
  #
59
59
  #
60
60
  #
@@ -109,12 +109,12 @@ module Aws::SNS
109
109
  # * `Policy` – The policy that defines who can access your topic. By
110
110
  # default, only the topic owner can publish or subscribe to the topic.
111
111
  #
112
- # The following attribute applies only to [server-side-encryption][1]\:
112
+ # The following attribute applies only to [server-side encryption][1]\:
113
113
  #
114
- # * `KmsMasterKeyId` – The ID of an AWS-managed customer master key
115
- # (CMK) for Amazon SNS or a custom CMK. For more information, see [Key
116
- # Terms][2]. For more examples, see [KeyId][3] in the *AWS Key
117
- # Management Service API Reference*.
114
+ # * `KmsMasterKeyId` – The ID of an Amazon Web Services managed customer
115
+ # master key (CMK) for Amazon SNS or a custom CMK. For more
116
+ # information, see [Key Terms][2]. For more examples, see [KeyId][3]
117
+ # in the *Key Management Service API Reference*.
118
118
  #
119
119
  # ^
120
120
  #
@@ -135,8 +135,8 @@ module Aws::SNS
135
135
  # the body of the message (but not the attributes of the message).
136
136
  #
137
137
  # (Optional) To override the generated value, you can specify a
138
- # value for the the `MessageDeduplicationId` parameter for the
139
- # `Publish` action.
138
+ # value for the `MessageDeduplicationId` parameter for the `Publish`
139
+ # action.
140
140
  #
141
141
  #
142
142
  #
@@ -3,7 +3,7 @@
3
3
  # WARNING ABOUT GENERATED CODE
4
4
  #
5
5
  # This file is generated. See the contributing guide for more information:
6
- # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
7
7
  #
8
8
  # WARNING ABOUT GENERATED CODE
9
9
 
@@ -51,7 +51,7 @@ module Aws::SNS
51
51
  # subscription. For more information, see [Amazon SNS Message
52
52
  # Filtering][1] in the *Amazon SNS Developer Guide*.
53
53
  #
54
- # * `Owner` – The AWS account ID of the subscription's owner.
54
+ # * `Owner` – The account ID of the subscription's owner.
55
55
  #
56
56
  # * `PendingConfirmation` – `true` if the subscription hasn't been
57
57
  # confirmed. To confirm a pending subscription, call the
@@ -90,7 +90,7 @@ module Aws::SNS
90
90
  #
91
91
  #
92
92
  # [1]: https://docs.aws.amazon.com/sns/latest/dg/sns-message-filtering.html
93
- # [2]: https://docs.aws.amazon.com/sns/latest/dg/sns-kinesis-subscriber.html
93
+ # [2]: https://docs.aws.amazon.com/sns/latest/dg/sns-firehose-as-subscriber.html
94
94
  # @return [Hash<String,String>]
95
95
  def attributes
96
96
  data[:attributes]
@@ -193,7 +193,7 @@ module Aws::SNS
193
193
  #
194
194
  #
195
195
  #
196
- # [1]: https://docs.aws.amazon.com/sns/latest/dg/sns-kinesis-subscriber.html
196
+ # [1]: https://docs.aws.amazon.com/sns/latest/dg/sns-firehose-as-subscriber.html
197
197
  # @option options [String] :attribute_value
198
198
  # The new value for the attribute in JSON format.
199
199
  # @return [EmptyStructure]