twilio-ruby 7.10.7 → 7.11.1
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.
- checksums.yaml +4 -4
- data/.github/workflows/test-and-deploy.yml +43 -67
- data/.gitignore +0 -1
- data/CHANGES.md +46 -0
- data/Gemfile +2 -0
- data/Gemfile.lock +154 -0
- data/README.md +3 -3
- data/Rakefile +1 -1
- data/lib/twilio-ruby/rest/accounts/v1/auth_token_promotion.rb +25 -6
- data/lib/twilio-ruby/rest/accounts/v1/secondary_auth_token.rb +48 -12
- data/lib/twilio-ruby/rest/api/v2010/account/call.rb +6 -0
- data/lib/twilio-ruby/rest/api/v2010/account/conference/participant.rb +56 -2
- data/lib/twilio-ruby/rest/client.rb +0 -5
- data/lib/twilio-ruby/rest/content/v1/content/approval_create.rb +11 -1
- data/lib/twilio-ruby/rest/conversations/v1/conversation/message.rb +10 -10
- data/lib/twilio-ruby/rest/conversations/v1/service/conversation/message.rb +10 -10
- data/lib/twilio-ruby/rest/conversations/v2/action.rb +2 -2
- data/lib/twilio-ruby/rest/conversations/v2/communication.rb +43 -21
- data/lib/twilio-ruby/rest/conversations/v2/configuration.rb +59 -21
- data/lib/twilio-ruby/rest/conversations/v2/conversation.rb +28 -28
- data/lib/twilio-ruby/rest/conversations/v2/operation.rb +10 -10
- data/lib/twilio-ruby/rest/conversations/v2/participant.rb +58 -58
- data/lib/twilio-ruby/rest/conversations/v2.rb +45 -45
- data/lib/twilio-ruby/rest/iam/v1/new_api_key.rb +2 -2
- data/lib/twilio-ruby/rest/iam/v1/o_auth_app.rb +15 -2
- data/lib/twilio-ruby/rest/iam_base.rb +6 -1
- data/lib/twilio-ruby/rest/insights/v1/call/call_summary.rb +7 -0
- data/lib/twilio-ruby/rest/insights/v1/call/event.rb +7 -0
- data/lib/twilio-ruby/rest/insights/v1/call_summaries.rb +7 -0
- data/lib/twilio-ruby/rest/insights/v3/metadata.rb +1 -1
- data/lib/twilio-ruby/rest/insights/v3/query.rb +1 -1
- data/lib/twilio-ruby/rest/insights/v3.rb +1 -1
- data/lib/twilio-ruby/rest/intelligence/v3/conversation.rb +8 -8
- data/lib/twilio-ruby/rest/intelligence/v3/rule_execution.rb +502 -0
- data/lib/twilio-ruby/rest/intelligence/v3.rb +6 -0
- data/lib/twilio-ruby/rest/knowledge/v2/chunk.rb +28 -0
- data/lib/twilio-ruby/rest/knowledge/v2/knowledge.rb +38 -0
- data/lib/twilio-ruby/rest/knowledge/v2/search.rb +8 -117
- data/lib/twilio-ruby/rest/knowledge/v2.rb +1 -2
- data/lib/twilio-ruby/rest/memory/v1/bulk.rb +9 -118
- data/lib/twilio-ruby/rest/memory/v1/conversation_summary.rb +13 -5
- data/lib/twilio-ruby/rest/memory/v1/data_mapping.rb +6 -12
- data/lib/twilio-ruby/rest/memory/v1/identifier.rb +1 -1
- data/lib/twilio-ruby/rest/memory/v1/identity_resolution_setting.rb +11 -132
- data/lib/twilio-ruby/rest/memory/v1/import.rb +28 -5
- data/lib/twilio-ruby/rest/memory/v1/lookup.rb +1 -1
- data/lib/twilio-ruby/rest/memory/v1/observation.rb +70 -18
- data/lib/twilio-ruby/rest/memory/v1/operation.rb +1 -1
- data/lib/twilio-ruby/rest/memory/v1/profile.rb +2 -2
- data/lib/twilio-ruby/rest/memory/v1/recall.rb +1 -1
- data/lib/twilio-ruby/rest/memory/v1/revision.rb +1 -1
- data/lib/twilio-ruby/rest/memory/v1/store.rb +1 -1
- data/lib/twilio-ruby/rest/memory/v1/trait.rb +1 -1
- data/lib/twilio-ruby/rest/memory/v1/trait_group.rb +56 -6
- data/lib/twilio-ruby/rest/memory/v1.rb +3 -46
- data/lib/twilio-ruby/rest/messaging/v1/brand_registration.rb +0 -18
- data/lib/twilio-ruby/rest/messaging/v2/channels_sender.rb +23 -4
- data/lib/twilio-ruby/rest/messaging/v3/typing_indicator.rb +4 -4
- data/lib/twilio-ruby/rest/numbers/v1/sms_verification.rb +231 -0
- data/lib/twilio-ruby/rest/numbers/v1/sms_verification_check.rb +238 -0
- data/lib/twilio-ruby/rest/numbers/v1/voice_verification.rb +245 -0
- data/lib/twilio-ruby/rest/numbers/v1/voice_verification_check.rb +224 -0
- data/lib/twilio-ruby/rest/numbers/v1.rb +24 -0
- data/lib/twilio-ruby/rest/{assistants/v1/session.rb → numbers/v2/caller_id.rb} +141 -127
- data/lib/twilio-ruby/rest/numbers/v2.rb +16 -0
- data/lib/twilio-ruby/rest/oauth/v2/authorize.rb +14 -2
- data/lib/twilio-ruby/rest/oauth/v2/oauth_authorization_server.rb +259 -0
- data/lib/twilio-ruby/rest/oauth/v2/token.rb +8 -2
- data/lib/twilio-ruby/rest/preview_iam/versionless/organization.rb +0 -19
- data/lib/twilio-ruby/rest/routes/v3/phone_number.rb +465 -0
- data/lib/twilio-ruby/rest/routes/v3.rb +50 -0
- data/lib/twilio-ruby/rest/routes_base.rb +6 -1
- data/lib/twilio-ruby/rest/trusthub/v1/a2p_brand_registration.rb +330 -0
- data/lib/twilio-ruby/rest/trusthub/v1/a2p_brand_registration_embedded_session.rb +233 -0
- data/lib/twilio-ruby/rest/trusthub/v1/a2p_campaign_registration.rb +321 -0
- data/lib/twilio-ruby/rest/trusthub/v1/a2p_campaign_registration_embedded_session.rb +233 -0
- data/lib/twilio-ruby/rest/trusthub/v1/customer_profiles_provisional_copy.rb +445 -0
- data/lib/twilio-ruby/rest/trusthub/v1/trust_products_provisional_copy.rb +445 -0
- data/lib/twilio-ruby/rest/trusthub/v1.rb +74 -0
- data/lib/twilio-ruby/rest/voice/v2/account_default_configuration.rb +556 -0
- data/lib/twilio-ruby/rest/voice/v2/configuration/default.rb +356 -0
- data/lib/twilio-ruby/rest/voice/v2/configuration.rb +412 -0
- data/lib/twilio-ruby/rest/voice/v2/recording.rb +616 -0
- data/lib/twilio-ruby/rest/voice/v2/transcription.rb +591 -0
- data/lib/twilio-ruby/rest/voice/v2/type.rb +518 -0
- data/lib/twilio-ruby/rest/voice/v2.rb +141 -0
- data/lib/twilio-ruby/rest/voice_base.rb +5 -0
- data/lib/twilio-ruby/twiml/voice_response.rb +6 -68
- data/lib/twilio-ruby/version.rb +1 -1
- data/twilio-ruby.gemspec +1 -1
- metadata +33 -21
- data/lib/twilio-ruby/rest/assistants/v1/assistant/assistants_knowledge.rb +0 -558
- data/lib/twilio-ruby/rest/assistants/v1/assistant/assistants_tool.rb +0 -558
- data/lib/twilio-ruby/rest/assistants/v1/assistant/feedback.rb +0 -431
- data/lib/twilio-ruby/rest/assistants/v1/assistant/message.rb +0 -296
- data/lib/twilio-ruby/rest/assistants/v1/assistant.rb +0 -927
- data/lib/twilio-ruby/rest/assistants/v1/knowledge/chunk.rb +0 -325
- data/lib/twilio-ruby/rest/assistants/v1/knowledge/knowledge_status.rb +0 -349
- data/lib/twilio-ruby/rest/assistants/v1/knowledge.rb +0 -871
- data/lib/twilio-ruby/rest/assistants/v1/policy.rb +0 -364
- data/lib/twilio-ruby/rest/assistants/v1/session/message.rb +0 -360
- data/lib/twilio-ruby/rest/assistants/v1/tool.rb +0 -847
- data/lib/twilio-ruby/rest/assistants/v1.rb +0 -104
- data/lib/twilio-ruby/rest/assistants.rb +0 -6
- data/lib/twilio-ruby/rest/assistants_base.rb +0 -38
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
# | |_|_| | |___ | |__| |__| | | | |__] |___ | \| |___ | \ | | | |__| | \
|
|
6
6
|
#
|
|
7
7
|
# Twilio Memory API
|
|
8
|
-
# APIs for managing memory stores, profiles,
|
|
8
|
+
# APIs for managing memory stores, profiles, and conversational intelligence capabilities.
|
|
9
9
|
#
|
|
10
10
|
# NOTE: This class is auto generated by OpenAPI Generator.
|
|
11
11
|
# https://openapi-generator.tech
|
|
@@ -38,17 +38,20 @@ module Twilio
|
|
|
38
38
|
class TraitDefinition
|
|
39
39
|
# @param [data_type]: [String] Data type of the Trait, such as STRING, NUMBER, BOOLEAN, ARRAY. For DELETE operations in PATCH requests, set this to an empty string (\"\") to mark the trait for deletion.
|
|
40
40
|
# @param [description]: [String] Description of the Trait, providing additional context or information.
|
|
41
|
+
# @param [validation_rule]: [ValidationRule]
|
|
41
42
|
# @param [id_type_promotion]: [String] The name of the identifier type to promote the trait value to, such as ''email'', ''phone'', ''user_id'', etc. This allows the trait to be mapped to an identifier in Identity Resolution. The identifier type should be configured in the Identity Resolution Settings.
|
|
42
|
-
attr_accessor :data_type, :description, :id_type_promotion
|
|
43
|
+
attr_accessor :data_type, :description, :validation_rule, :id_type_promotion
|
|
43
44
|
def initialize(payload)
|
|
44
45
|
@data_type = payload["data_type"]
|
|
45
46
|
@description = payload["description"]
|
|
47
|
+
@validation_rule = payload["validation_rule"]
|
|
46
48
|
@id_type_promotion = payload["id_type_promotion"]
|
|
47
49
|
end
|
|
48
50
|
def to_json(options = {})
|
|
49
51
|
{
|
|
50
52
|
"dataType": @data_type,
|
|
51
53
|
"description": @description,
|
|
54
|
+
"validationRule": @validation_rule,
|
|
52
55
|
"idTypePromotion": @id_type_promotion,
|
|
53
56
|
}.to_json(options)
|
|
54
57
|
end
|
|
@@ -57,7 +60,7 @@ module Twilio
|
|
|
57
60
|
class TraitGroupRequest
|
|
58
61
|
# @param [display_name]: [String] Unique name of the Trait Group
|
|
59
62
|
# @param [description]: [String] description of the Trait Group
|
|
60
|
-
# @param [traits]: [Hash<String,
|
|
63
|
+
# @param [traits]: [Hash<String, TraitGroupRequestTraits>] Map of traits belonging to this Trait Group, keyed by trait name.
|
|
61
64
|
attr_accessor :display_name, :description, :traits
|
|
62
65
|
def initialize(payload)
|
|
63
66
|
@display_name = payload["display_name"]
|
|
@@ -73,6 +76,28 @@ module Twilio
|
|
|
73
76
|
end
|
|
74
77
|
end
|
|
75
78
|
|
|
79
|
+
class TraitGroupRequestTraits
|
|
80
|
+
# @param [data_type]: [String] Data type of the Trait, such as STRING, NUMBER, BOOLEAN, ARRAY. For DELETE operations in PATCH requests, set this to an empty string (\"\") to mark the trait for deletion.
|
|
81
|
+
# @param [description]: [String] Description of the Trait, providing additional context or information.
|
|
82
|
+
# @param [validation_rule]: [ValidationRule]
|
|
83
|
+
# @param [id_type_promotion]: [String] The name of the identifier type to promote the trait value to, such as ''email'', ''phone'', ''user_id'', etc. This allows the trait to be mapped to an identifier in Identity Resolution. The identifier type should be configured in the Identity Resolution Settings.
|
|
84
|
+
attr_accessor :data_type, :description, :validation_rule, :id_type_promotion
|
|
85
|
+
def initialize(payload)
|
|
86
|
+
@data_type = payload["data_type"]
|
|
87
|
+
@description = payload["description"]
|
|
88
|
+
@validation_rule = payload["validation_rule"]
|
|
89
|
+
@id_type_promotion = payload["id_type_promotion"]
|
|
90
|
+
end
|
|
91
|
+
def to_json(options = {})
|
|
92
|
+
{
|
|
93
|
+
"dataType": @data_type,
|
|
94
|
+
"description": @description,
|
|
95
|
+
"validationRule": @validation_rule,
|
|
96
|
+
"idTypePromotion": @id_type_promotion,
|
|
97
|
+
}.to_json(options)
|
|
98
|
+
end
|
|
99
|
+
end
|
|
100
|
+
|
|
76
101
|
class ValidationRule
|
|
77
102
|
# @param [pattern]: [String] Regex pattern (max 1000 chars)
|
|
78
103
|
# @param [min_length]: [Integer] Minimum string length
|
|
@@ -127,17 +152,20 @@ module Twilio
|
|
|
127
152
|
class TraitDefinition
|
|
128
153
|
# @param [data_type]: [String] Data type of the Trait, such as STRING, NUMBER, BOOLEAN, ARRAY. For DELETE operations in PATCH requests, set this to an empty string (\"\") to mark the trait for deletion.
|
|
129
154
|
# @param [description]: [String] Description of the Trait, providing additional context or information.
|
|
155
|
+
# @param [validation_rule]: [ValidationRule]
|
|
130
156
|
# @param [id_type_promotion]: [String] The name of the identifier type to promote the trait value to, such as ''email'', ''phone'', ''user_id'', etc. This allows the trait to be mapped to an identifier in Identity Resolution. The identifier type should be configured in the Identity Resolution Settings.
|
|
131
|
-
attr_accessor :data_type, :description, :id_type_promotion
|
|
157
|
+
attr_accessor :data_type, :description, :validation_rule, :id_type_promotion
|
|
132
158
|
def initialize(payload)
|
|
133
159
|
@data_type = payload["data_type"]
|
|
134
160
|
@description = payload["description"]
|
|
161
|
+
@validation_rule = payload["validation_rule"]
|
|
135
162
|
@id_type_promotion = payload["id_type_promotion"]
|
|
136
163
|
end
|
|
137
164
|
def to_json(options = {})
|
|
138
165
|
{
|
|
139
166
|
"dataType": @data_type,
|
|
140
167
|
"description": @description,
|
|
168
|
+
"validationRule": @validation_rule,
|
|
141
169
|
"idTypePromotion": @id_type_promotion,
|
|
142
170
|
}.to_json(options)
|
|
143
171
|
end
|
|
@@ -146,7 +174,7 @@ module Twilio
|
|
|
146
174
|
class TraitGroupRequest
|
|
147
175
|
# @param [display_name]: [String] Unique name of the Trait Group
|
|
148
176
|
# @param [description]: [String] description of the Trait Group
|
|
149
|
-
# @param [traits]: [Hash<String,
|
|
177
|
+
# @param [traits]: [Hash<String, TraitGroupRequestTraits>] Map of traits belonging to this Trait Group, keyed by trait name.
|
|
150
178
|
attr_accessor :display_name, :description, :traits
|
|
151
179
|
def initialize(payload)
|
|
152
180
|
@display_name = payload["display_name"]
|
|
@@ -162,6 +190,28 @@ module Twilio
|
|
|
162
190
|
end
|
|
163
191
|
end
|
|
164
192
|
|
|
193
|
+
class TraitGroupRequestTraits
|
|
194
|
+
# @param [data_type]: [String] Data type of the Trait, such as STRING, NUMBER, BOOLEAN, ARRAY. For DELETE operations in PATCH requests, set this to an empty string (\"\") to mark the trait for deletion.
|
|
195
|
+
# @param [description]: [String] Description of the Trait, providing additional context or information.
|
|
196
|
+
# @param [validation_rule]: [ValidationRule]
|
|
197
|
+
# @param [id_type_promotion]: [String] The name of the identifier type to promote the trait value to, such as ''email'', ''phone'', ''user_id'', etc. This allows the trait to be mapped to an identifier in Identity Resolution. The identifier type should be configured in the Identity Resolution Settings.
|
|
198
|
+
attr_accessor :data_type, :description, :validation_rule, :id_type_promotion
|
|
199
|
+
def initialize(payload)
|
|
200
|
+
@data_type = payload["data_type"]
|
|
201
|
+
@description = payload["description"]
|
|
202
|
+
@validation_rule = payload["validation_rule"]
|
|
203
|
+
@id_type_promotion = payload["id_type_promotion"]
|
|
204
|
+
end
|
|
205
|
+
def to_json(options = {})
|
|
206
|
+
{
|
|
207
|
+
"dataType": @data_type,
|
|
208
|
+
"description": @description,
|
|
209
|
+
"validationRule": @validation_rule,
|
|
210
|
+
"idTypePromotion": @id_type_promotion,
|
|
211
|
+
}.to_json(options)
|
|
212
|
+
end
|
|
213
|
+
end
|
|
214
|
+
|
|
165
215
|
class ValidationRule
|
|
166
216
|
# @param [pattern]: [String] Regex pattern (max 1000 chars)
|
|
167
217
|
# @param [min_length]: [Integer] Minimum string length
|
|
@@ -826,7 +876,7 @@ module Twilio
|
|
|
826
876
|
end
|
|
827
877
|
|
|
828
878
|
##
|
|
829
|
-
# @return [Hash<String,
|
|
879
|
+
# @return [Hash<String, TraitGroupCoreTraits>] Map of traits that are part of this Trait Group, where the key is the trait name and the value is the trait's definition.
|
|
830
880
|
def traits
|
|
831
881
|
@properties['traits']
|
|
832
882
|
end
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
# | |_|_| | |___ | |__| |__| | | | |__] |___ | \| |___ | \ | | | |__| | \
|
|
6
6
|
#
|
|
7
7
|
# Twilio Memory API
|
|
8
|
-
# APIs for managing memory stores, profiles,
|
|
8
|
+
# APIs for managing memory stores, profiles, and conversational intelligence capabilities.
|
|
9
9
|
#
|
|
10
10
|
# NOTE: This class is auto generated by OpenAPI Generator.
|
|
11
11
|
# https://openapi-generator.tech
|
|
@@ -24,7 +24,6 @@ module Twilio
|
|
|
24
24
|
@bulk = nil
|
|
25
25
|
@conversation_summaries = nil
|
|
26
26
|
@data_mappings = nil
|
|
27
|
-
@events = nil
|
|
28
27
|
@identifiers = nil
|
|
29
28
|
@identity_resolution_settings = nil
|
|
30
29
|
@imports = nil
|
|
@@ -41,7 +40,6 @@ module Twilio
|
|
|
41
40
|
|
|
42
41
|
##
|
|
43
42
|
# @param [String] store_id A unique Memory Store ID using Twilio Type ID (TTID) format
|
|
44
|
-
# @return [Twilio::REST::Memory::V1::BulkContext] if storeId was passed.
|
|
45
43
|
# @return [Twilio::REST::Memory::V1::BulkList]
|
|
46
44
|
def bulk(store_id=:unset)
|
|
47
45
|
if store_id.nil?
|
|
@@ -51,7 +49,7 @@ module Twilio
|
|
|
51
49
|
if store_id == :unset
|
|
52
50
|
@bulk ||= BulkList.new self
|
|
53
51
|
else
|
|
54
|
-
|
|
52
|
+
BulkList.new(self, store_id: store_id)
|
|
55
53
|
end
|
|
56
54
|
end
|
|
57
55
|
##
|
|
@@ -101,46 +99,6 @@ module Twilio
|
|
|
101
99
|
end
|
|
102
100
|
end
|
|
103
101
|
##
|
|
104
|
-
# @param [String] store_id The storeId identifier
|
|
105
|
-
# @param [String] profile_id The profileId identifier
|
|
106
|
-
# @return [Twilio::REST::Memory::V1::EventList]
|
|
107
|
-
def events(store_id=:unset, profile_id=:unset)
|
|
108
|
-
if store_id.nil?
|
|
109
|
-
raise ArgumentError, 'store_id cannot be nil'
|
|
110
|
-
end
|
|
111
|
-
if profile_id.nil?
|
|
112
|
-
raise ArgumentError, 'profile_id cannot be nil'
|
|
113
|
-
end
|
|
114
|
-
|
|
115
|
-
if store_id == :unset && profile_id == :unset
|
|
116
|
-
@events ||= EventList.new self
|
|
117
|
-
elsif store_id != :unset && profile_id == :unset
|
|
118
|
-
EventList.new(self, store_id: store_id)
|
|
119
|
-
else
|
|
120
|
-
EventList.new(self, store_id: store_id, profile_id: profile_id)
|
|
121
|
-
end
|
|
122
|
-
end
|
|
123
|
-
##
|
|
124
|
-
# @param [String] store_id The storeId identifier
|
|
125
|
-
# @param [String] profile_id The profileId identifier
|
|
126
|
-
# @return [Twilio::REST::Memory::V1::EventList]
|
|
127
|
-
def events(store_id=:unset, profile_id=:unset)
|
|
128
|
-
if store_id.nil?
|
|
129
|
-
raise ArgumentError, 'store_id cannot be nil'
|
|
130
|
-
end
|
|
131
|
-
if profile_id.nil?
|
|
132
|
-
raise ArgumentError, 'profile_id cannot be nil'
|
|
133
|
-
end
|
|
134
|
-
|
|
135
|
-
if store_id == :unset && profile_id == :unset
|
|
136
|
-
@events ||= EventList.new self
|
|
137
|
-
elsif store_id != :unset && profile_id == :unset
|
|
138
|
-
EventList.new(self, store_id: store_id)
|
|
139
|
-
else
|
|
140
|
-
EventList.new(self, store_id: store_id, profile_id: profile_id)
|
|
141
|
-
end
|
|
142
|
-
end
|
|
143
|
-
##
|
|
144
102
|
# @param [String] store_id A unique Memory Store ID using Twilio Type ID (TTID) format
|
|
145
103
|
# @param [String] profile_id The unique identifier for the profile using Twilio Type ID (TTID) format.
|
|
146
104
|
# @param [String] id_type
|
|
@@ -167,7 +125,6 @@ module Twilio
|
|
|
167
125
|
end
|
|
168
126
|
##
|
|
169
127
|
# @param [String] store_id A unique Memory Store ID using Twilio Type ID (TTID) format
|
|
170
|
-
# @return [Twilio::REST::Memory::V1::IdentityResolutionSettingContext] if storeId was passed.
|
|
171
128
|
# @return [Twilio::REST::Memory::V1::IdentityResolutionSettingList]
|
|
172
129
|
def identity_resolution_settings(store_id=:unset)
|
|
173
130
|
if store_id.nil?
|
|
@@ -177,7 +134,7 @@ module Twilio
|
|
|
177
134
|
if store_id == :unset
|
|
178
135
|
@identity_resolution_settings ||= IdentityResolutionSettingList.new self
|
|
179
136
|
else
|
|
180
|
-
|
|
137
|
+
IdentityResolutionSettingList.new(self, store_id: store_id)
|
|
181
138
|
end
|
|
182
139
|
end
|
|
183
140
|
##
|
|
@@ -255,7 +255,6 @@ module Twilio
|
|
|
255
255
|
# Dependents
|
|
256
256
|
@brand_registration_otps = nil
|
|
257
257
|
@brand_vettings = nil
|
|
258
|
-
@brand_registration2_fa = nil
|
|
259
258
|
end
|
|
260
259
|
##
|
|
261
260
|
# Fetch the BrandRegistrationInstance
|
|
@@ -375,16 +374,6 @@ module Twilio
|
|
|
375
374
|
|
|
376
375
|
@brand_vettings
|
|
377
376
|
end
|
|
378
|
-
##
|
|
379
|
-
# Access the brand_registration2_fa
|
|
380
|
-
# @return [BrandRegistration2FaList]
|
|
381
|
-
# @return [BrandRegistration2FaContext]
|
|
382
|
-
def brand_registration2_fa
|
|
383
|
-
BrandRegistration2FaContext.new(
|
|
384
|
-
@version,
|
|
385
|
-
@solution[:sid]
|
|
386
|
-
)
|
|
387
|
-
end
|
|
388
377
|
|
|
389
378
|
##
|
|
390
379
|
# Provide a user friendly representation
|
|
@@ -748,13 +737,6 @@ module Twilio
|
|
|
748
737
|
context.brand_vettings
|
|
749
738
|
end
|
|
750
739
|
|
|
751
|
-
##
|
|
752
|
-
# Access the brand_registration2_fa
|
|
753
|
-
# @return [brand_registration2_fa] brand_registration2_fa
|
|
754
|
-
def brand_registration2_fa
|
|
755
|
-
context.brand_registration2_fa
|
|
756
|
-
end
|
|
757
|
-
|
|
758
740
|
##
|
|
759
741
|
# Provide a user friendly representation
|
|
760
742
|
def to_s
|
|
@@ -121,12 +121,14 @@ module Twilio
|
|
|
121
121
|
|
|
122
122
|
class MessagingV2ChannelsSenderRequestsCreate
|
|
123
123
|
# @param [sender_id]: [String] The ID of the sender in `whatsapp:<E.164_PHONE_NUMBER>` format.
|
|
124
|
+
# @param [friendly_name]: [String] Optional display label for the sender in the Twilio Console.
|
|
124
125
|
# @param [configuration]: [ChannelsSenderList.MessagingV2ChannelsSenderConfiguration]
|
|
125
126
|
# @param [webhook]: [ChannelsSenderList.MessagingV2ChannelsSenderWebhook]
|
|
126
127
|
# @param [profile]: [ChannelsSenderList.MessagingV2ChannelsSenderProfile]
|
|
127
|
-
attr_accessor :sender_id, :configuration, :webhook, :profile
|
|
128
|
+
attr_accessor :sender_id, :friendly_name, :configuration, :webhook, :profile
|
|
128
129
|
def initialize(payload)
|
|
129
130
|
@sender_id = payload["sender_id"]
|
|
131
|
+
@friendly_name = payload["friendly_name"]
|
|
130
132
|
@configuration = payload["configuration"]
|
|
131
133
|
@webhook = payload["webhook"]
|
|
132
134
|
@profile = payload["profile"]
|
|
@@ -134,6 +136,7 @@ module Twilio
|
|
|
134
136
|
def to_json(options = {})
|
|
135
137
|
{
|
|
136
138
|
"sender_id": @sender_id,
|
|
139
|
+
"friendly_name": @friendly_name,
|
|
137
140
|
"configuration": @configuration,
|
|
138
141
|
"webhook": @webhook,
|
|
139
142
|
"profile": @profile,
|
|
@@ -142,17 +145,20 @@ module Twilio
|
|
|
142
145
|
end
|
|
143
146
|
|
|
144
147
|
class MessagingV2ChannelsSenderRequestsUpdate
|
|
148
|
+
# @param [friendly_name]: [String] Optional display label for the sender in the Twilio Console.
|
|
145
149
|
# @param [configuration]: [ChannelsSenderList.MessagingV2ChannelsSenderConfiguration]
|
|
146
150
|
# @param [webhook]: [ChannelsSenderList.MessagingV2ChannelsSenderWebhook]
|
|
147
151
|
# @param [profile]: [ChannelsSenderList.MessagingV2ChannelsSenderProfile]
|
|
148
|
-
attr_accessor :configuration, :webhook, :profile
|
|
152
|
+
attr_accessor :friendly_name, :configuration, :webhook, :profile
|
|
149
153
|
def initialize(payload)
|
|
154
|
+
@friendly_name = payload["friendly_name"]
|
|
150
155
|
@configuration = payload["configuration"]
|
|
151
156
|
@webhook = payload["webhook"]
|
|
152
157
|
@profile = payload["profile"]
|
|
153
158
|
end
|
|
154
159
|
def to_json(options = {})
|
|
155
160
|
{
|
|
161
|
+
"friendly_name": @friendly_name,
|
|
156
162
|
"configuration": @configuration,
|
|
157
163
|
"webhook": @webhook,
|
|
158
164
|
"profile": @profile,
|
|
@@ -301,12 +307,14 @@ module Twilio
|
|
|
301
307
|
|
|
302
308
|
class MessagingV2ChannelsSenderRequestsCreate
|
|
303
309
|
# @param [sender_id]: [String] The ID of the sender in `whatsapp:<E.164_PHONE_NUMBER>` format.
|
|
310
|
+
# @param [friendly_name]: [String] Optional display label for the sender in the Twilio Console.
|
|
304
311
|
# @param [configuration]: [ChannelsSenderList.MessagingV2ChannelsSenderConfiguration]
|
|
305
312
|
# @param [webhook]: [ChannelsSenderList.MessagingV2ChannelsSenderWebhook]
|
|
306
313
|
# @param [profile]: [ChannelsSenderList.MessagingV2ChannelsSenderProfile]
|
|
307
|
-
attr_accessor :sender_id, :configuration, :webhook, :profile
|
|
314
|
+
attr_accessor :sender_id, :friendly_name, :configuration, :webhook, :profile
|
|
308
315
|
def initialize(payload)
|
|
309
316
|
@sender_id = payload["sender_id"]
|
|
317
|
+
@friendly_name = payload["friendly_name"]
|
|
310
318
|
@configuration = payload["configuration"]
|
|
311
319
|
@webhook = payload["webhook"]
|
|
312
320
|
@profile = payload["profile"]
|
|
@@ -314,6 +322,7 @@ module Twilio
|
|
|
314
322
|
def to_json(options = {})
|
|
315
323
|
{
|
|
316
324
|
"sender_id": @sender_id,
|
|
325
|
+
"friendly_name": @friendly_name,
|
|
317
326
|
"configuration": @configuration,
|
|
318
327
|
"webhook": @webhook,
|
|
319
328
|
"profile": @profile,
|
|
@@ -322,17 +331,20 @@ module Twilio
|
|
|
322
331
|
end
|
|
323
332
|
|
|
324
333
|
class MessagingV2ChannelsSenderRequestsUpdate
|
|
334
|
+
# @param [friendly_name]: [String] Optional display label for the sender in the Twilio Console.
|
|
325
335
|
# @param [configuration]: [ChannelsSenderList.MessagingV2ChannelsSenderConfiguration]
|
|
326
336
|
# @param [webhook]: [ChannelsSenderList.MessagingV2ChannelsSenderWebhook]
|
|
327
337
|
# @param [profile]: [ChannelsSenderList.MessagingV2ChannelsSenderProfile]
|
|
328
|
-
attr_accessor :configuration, :webhook, :profile
|
|
338
|
+
attr_accessor :friendly_name, :configuration, :webhook, :profile
|
|
329
339
|
def initialize(payload)
|
|
340
|
+
@friendly_name = payload["friendly_name"]
|
|
330
341
|
@configuration = payload["configuration"]
|
|
331
342
|
@webhook = payload["webhook"]
|
|
332
343
|
@profile = payload["profile"]
|
|
333
344
|
end
|
|
334
345
|
def to_json(options = {})
|
|
335
346
|
{
|
|
347
|
+
"friendly_name": @friendly_name,
|
|
336
348
|
"configuration": @configuration,
|
|
337
349
|
"webhook": @webhook,
|
|
338
350
|
"profile": @profile,
|
|
@@ -883,6 +895,7 @@ module Twilio
|
|
|
883
895
|
'sid' => payload['sid'],
|
|
884
896
|
'status' => payload['status'],
|
|
885
897
|
'sender_id' => payload['sender_id'],
|
|
898
|
+
'friendly_name' => payload['friendly_name'],
|
|
886
899
|
'configuration' => payload['configuration'],
|
|
887
900
|
'webhook' => payload['webhook'],
|
|
888
901
|
'profile' => payload['profile'],
|
|
@@ -926,6 +939,12 @@ module Twilio
|
|
|
926
939
|
@properties['sender_id']
|
|
927
940
|
end
|
|
928
941
|
|
|
942
|
+
##
|
|
943
|
+
# @return [String] Optional display label for the sender in the Twilio Console.
|
|
944
|
+
def friendly_name
|
|
945
|
+
@properties['friendly_name']
|
|
946
|
+
end
|
|
947
|
+
|
|
929
948
|
##
|
|
930
949
|
# @return [MessagingV2ChannelsSenderConfiguration]
|
|
931
950
|
def configuration
|
|
@@ -20,11 +20,11 @@ module Twilio
|
|
|
20
20
|
class TypingIndicatorList < ListResource
|
|
21
21
|
|
|
22
22
|
class TypingIndicatorRequest
|
|
23
|
-
# @param [channel]: [String] The messaging channel. Must be \"
|
|
23
|
+
# @param [channel]: [String] The messaging channel. Must be \"RCS\".
|
|
24
24
|
# @param [message_id]: [String] The SID of a recent inbound message from the recipient. Must be an SM or MM SID format.
|
|
25
|
-
# @param [from]: [String] The
|
|
26
|
-
# @param [to]: [String] The
|
|
27
|
-
# @param [event]: [String] The type of typing event. \"START\"
|
|
25
|
+
# @param [from]: [String] The RCS agent identifier of the sender (business).
|
|
26
|
+
# @param [to]: [String] The RCS recipient identifier in E.164 format prefixed with \"rcs:\".
|
|
27
|
+
# @param [event]: [String] The type of typing event. Currently only \"START\" is supported for RCS, indicating the agent began typing. Defaults to \"START\".
|
|
28
28
|
attr_accessor :channel, :message_id, :from, :to, :event
|
|
29
29
|
def initialize(payload)
|
|
30
30
|
@channel = payload["channel"]
|
|
@@ -0,0 +1,231 @@
|
|
|
1
|
+
##
|
|
2
|
+
# This code was generated by
|
|
3
|
+
# ___ _ _ _ _ _ _ ____ ____ ____ _ ____ ____ _ _ ____ ____ ____ ___ __ __
|
|
4
|
+
# | | | | | | | | | __ | | |__| | __ | __ |___ |\ | |___ |__/ |__| | | | |__/
|
|
5
|
+
# | |_|_| | |___ | |__| |__| | | | |__] |___ | \| |___ | \ | | | |__| | \
|
|
6
|
+
#
|
|
7
|
+
# Twilio - Numbers
|
|
8
|
+
# This is the public Twilio REST API.
|
|
9
|
+
#
|
|
10
|
+
# NOTE: This class is auto generated by OpenAPI Generator.
|
|
11
|
+
# https://openapi-generator.tech
|
|
12
|
+
# Do not edit the class manually.
|
|
13
|
+
#
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
module Twilio
|
|
17
|
+
module REST
|
|
18
|
+
class Numbers < NumbersBase
|
|
19
|
+
class V1 < Version
|
|
20
|
+
class SmsVerificationList < ListResource
|
|
21
|
+
|
|
22
|
+
##
|
|
23
|
+
# Initialize the SmsVerificationList
|
|
24
|
+
# @param [Version] version Version that contains the resource
|
|
25
|
+
# @return [SmsVerificationList] SmsVerificationList
|
|
26
|
+
def initialize(version)
|
|
27
|
+
super(version)
|
|
28
|
+
|
|
29
|
+
# Path Solution
|
|
30
|
+
@solution = { }
|
|
31
|
+
@uri = "/CallerIds/SmsVerifications"
|
|
32
|
+
|
|
33
|
+
end
|
|
34
|
+
##
|
|
35
|
+
# Create the SmsVerificationInstance
|
|
36
|
+
# @return [SmsVerificationInstance] Created SmsVerificationInstance
|
|
37
|
+
def create
|
|
38
|
+
|
|
39
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
payload = @version.create('POST', @uri, headers: headers)
|
|
46
|
+
SmsVerificationInstance.new(
|
|
47
|
+
@version,
|
|
48
|
+
payload,
|
|
49
|
+
)
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
##
|
|
53
|
+
# Create the SmsVerificationInstanceMetadata
|
|
54
|
+
# @return [SmsVerificationInstance] Created SmsVerificationInstance
|
|
55
|
+
def create_with_metadata
|
|
56
|
+
|
|
57
|
+
headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
response = @version.create_with_metadata('POST', @uri, headers: headers)
|
|
64
|
+
sms_verification_instance = SmsVerificationInstance.new(
|
|
65
|
+
@version,
|
|
66
|
+
response.body,
|
|
67
|
+
)
|
|
68
|
+
SmsVerificationInstanceMetadata.new(
|
|
69
|
+
@version,
|
|
70
|
+
sms_verification_instance,
|
|
71
|
+
response.headers,
|
|
72
|
+
response.status_code
|
|
73
|
+
)
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
# Provide a user friendly representation
|
|
80
|
+
def to_s
|
|
81
|
+
'#<Twilio.Numbers.V1.SmsVerificationList>'
|
|
82
|
+
end
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
class SmsVerificationPage < Page
|
|
86
|
+
##
|
|
87
|
+
# Initialize the SmsVerificationPage
|
|
88
|
+
# @param [Version] version Version that contains the resource
|
|
89
|
+
# @param [Response] response Response from the API
|
|
90
|
+
# @param [Hash] solution Path solution for the resource
|
|
91
|
+
# @return [SmsVerificationPage] SmsVerificationPage
|
|
92
|
+
def initialize(version, response, solution)
|
|
93
|
+
super(version, response)
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
# Path Solution
|
|
97
|
+
@solution = solution
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
##
|
|
101
|
+
# Build an instance of SmsVerificationInstance
|
|
102
|
+
# @param [Hash] payload Payload response from the API
|
|
103
|
+
# @return [SmsVerificationInstance] SmsVerificationInstance
|
|
104
|
+
def get_instance(payload)
|
|
105
|
+
SmsVerificationInstance.new(@version, payload)
|
|
106
|
+
end
|
|
107
|
+
|
|
108
|
+
##
|
|
109
|
+
# Provide a user friendly representation
|
|
110
|
+
def to_s
|
|
111
|
+
'<Twilio.Numbers.V1.SmsVerificationPage>'
|
|
112
|
+
end
|
|
113
|
+
end
|
|
114
|
+
|
|
115
|
+
class SmsVerificationPageMetadata < PageMetadata
|
|
116
|
+
attr_reader :sms_verification_page
|
|
117
|
+
|
|
118
|
+
def initialize(version, response, solution, limit)
|
|
119
|
+
super(version, response)
|
|
120
|
+
@sms_verification_page = []
|
|
121
|
+
@limit = limit
|
|
122
|
+
key = get_key(response.body)
|
|
123
|
+
records = 0
|
|
124
|
+
while( limit != :unset && records < limit )
|
|
125
|
+
@sms_verification_page << SmsVerificationListResponse.new(version, @payload, key, limit - records)
|
|
126
|
+
@payload = self.next_page
|
|
127
|
+
break unless @payload
|
|
128
|
+
records += (@payload.body[key] || []).size
|
|
129
|
+
end
|
|
130
|
+
# Path Solution
|
|
131
|
+
@solution = solution
|
|
132
|
+
end
|
|
133
|
+
|
|
134
|
+
def each
|
|
135
|
+
@sms_verification_page.each do |record|
|
|
136
|
+
yield record
|
|
137
|
+
end
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
def to_s
|
|
141
|
+
'<Twilio::REST::Numbers::V1PageMetadata>';
|
|
142
|
+
end
|
|
143
|
+
end
|
|
144
|
+
class SmsVerificationListResponse < InstanceListResource
|
|
145
|
+
|
|
146
|
+
# @param [Array<SmsVerificationInstance>] instance
|
|
147
|
+
# @param [Hash{String => Object}] headers
|
|
148
|
+
# @param [Integer] status_code
|
|
149
|
+
def initialize(version, payload, key, limit = :unset)
|
|
150
|
+
data_list = payload.body[key] || []
|
|
151
|
+
if limit != :unset
|
|
152
|
+
data_list = data_list[0, limit]
|
|
153
|
+
end
|
|
154
|
+
@sms_verification = data_list.map do |data|
|
|
155
|
+
SmsVerificationInstance.new(version, data)
|
|
156
|
+
end
|
|
157
|
+
@headers = payload.headers
|
|
158
|
+
@status_code = payload.status_code
|
|
159
|
+
end
|
|
160
|
+
|
|
161
|
+
def sms_verification
|
|
162
|
+
@sms_verification
|
|
163
|
+
end
|
|
164
|
+
|
|
165
|
+
def headers
|
|
166
|
+
@headers
|
|
167
|
+
end
|
|
168
|
+
|
|
169
|
+
def status_code
|
|
170
|
+
@status_code
|
|
171
|
+
end
|
|
172
|
+
end
|
|
173
|
+
|
|
174
|
+
class SmsVerificationInstance < InstanceResource
|
|
175
|
+
##
|
|
176
|
+
# Initialize the SmsVerificationInstance
|
|
177
|
+
# @param [Version] version Version that contains the resource
|
|
178
|
+
# @param [Hash] payload payload that contains response from Twilio
|
|
179
|
+
# @param [String] account_sid The SID of the
|
|
180
|
+
# {Account}[https://www.twilio.com/docs/iam/api/account] that created this SmsVerification
|
|
181
|
+
# resource.
|
|
182
|
+
# @param [String] sid The SID of the Call resource to fetch.
|
|
183
|
+
# @return [SmsVerificationInstance] SmsVerificationInstance
|
|
184
|
+
def initialize(version, payload )
|
|
185
|
+
super(version)
|
|
186
|
+
|
|
187
|
+
|
|
188
|
+
# Marshaled Properties
|
|
189
|
+
@properties = {
|
|
190
|
+
'to' => payload['to'],
|
|
191
|
+
'verification_sid' => payload['verification_sid'],
|
|
192
|
+
'send_code_attempts' => payload['send_code_attempts'],
|
|
193
|
+
}
|
|
194
|
+
end
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
##
|
|
198
|
+
# @return [String] The phone number being verified in E.164 format.
|
|
199
|
+
def to
|
|
200
|
+
@properties['to']
|
|
201
|
+
end
|
|
202
|
+
|
|
203
|
+
##
|
|
204
|
+
# @return [String] The unique SID of this verification resource.
|
|
205
|
+
def verification_sid
|
|
206
|
+
@properties['verification_sid']
|
|
207
|
+
end
|
|
208
|
+
|
|
209
|
+
##
|
|
210
|
+
# @return [Array<NumbersV1SmsVerificationSendCodeAttempts>] An array of verification attempt objects.
|
|
211
|
+
def send_code_attempts
|
|
212
|
+
@properties['send_code_attempts']
|
|
213
|
+
end
|
|
214
|
+
|
|
215
|
+
##
|
|
216
|
+
# Provide a user friendly representation
|
|
217
|
+
def to_s
|
|
218
|
+
"<Twilio.Numbers.V1.SmsVerificationInstance>"
|
|
219
|
+
end
|
|
220
|
+
|
|
221
|
+
##
|
|
222
|
+
# Provide a detailed, user friendly representation
|
|
223
|
+
def inspect
|
|
224
|
+
"<Twilio.Numbers.V1.SmsVerificationInstance>"
|
|
225
|
+
end
|
|
226
|
+
end
|
|
227
|
+
|
|
228
|
+
end
|
|
229
|
+
end
|
|
230
|
+
end
|
|
231
|
+
end
|