twilio-ruby 7.4.1 → 7.4.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ea2a68b28f89cfa0d94441cdb2186788d204b32f
4
- data.tar.gz: f5470c7e0c59b5a40f94d5f29eb282679a52e7ba
3
+ metadata.gz: 7d6689c97fcad14e96b7d77b508bffcb02e1df1d
4
+ data.tar.gz: 9dcf43a9e8af38ecadf3ac8cf10b0503e4b1bec7
5
5
  SHA512:
6
- metadata.gz: 26eb27adf397cac990ecc4d9d7e06c6fe1d082a643b9c7500b5a3ff44bbdfb658262e60a9d4f567e5b55c3e2e1533f950f341f15886e31694f45777778191d7c
7
- data.tar.gz: caf42a2e6814d6d343dba45b8c17623f2bdc887910bbec35ae041bfb5f142d4ba93a2c4c53d369b1e0c92f5c32a3cd053d309866225a9820f6ab826a1de4b32e
6
+ metadata.gz: 7e7b44610e849d581c114a13bc001a8057511f68dca0f06fcdda057c4b19ab2ee23f1d34e0dd9078d12e89992081a742866d470e010ec0fd12ef73abe1d96fdf
7
+ data.tar.gz: aaeb5e71c902dd442b63eca4ee1ebc94a236cbb3f9d5710ff77c8a14c8a044d28cacb249a4aac0e5e295d458aa586a4936051c0d83b0c640a166dd71673b35a9
@@ -0,0 +1,69 @@
1
+ name: Bug report
2
+ description: Report a bug with the twilio-ruby helper library.
3
+ title: "[BUG] Describe the issue briefly"
4
+ labels: "type: bug"
5
+ body:
6
+ - type: markdown
7
+ attributes:
8
+ value: |
9
+ Thank you for reporting a bug in the twilio-ruby helper library. Please provide the details below to help us investigate and resolve the issue.
10
+
11
+ - type: textarea
12
+ attributes:
13
+ label: Describe the bug
14
+ description: Provide a clear and concise description of the issue.
15
+ placeholder: A clear and concise description of the bug.
16
+ validations:
17
+ required: true
18
+
19
+ - type: textarea
20
+ attributes:
21
+ label: Code snippet
22
+ description: Provide the code snippet that reproduces the issue.
23
+ placeholder: "```\n// Code snippet here\n```"
24
+ validations:
25
+ required: true
26
+
27
+ - type: textarea
28
+ attributes:
29
+ label: Actual behavior
30
+ description: Describe what actually happened.
31
+ placeholder: A description of the actual behavior.
32
+ validations:
33
+ required: true
34
+
35
+ - type: textarea
36
+ attributes:
37
+ label: Expected behavior
38
+ description: Describe what you expected to happen.
39
+ placeholder: A description of the expected outcome.
40
+ validations:
41
+ required: true
42
+
43
+ - type: input
44
+ attributes:
45
+ label: twilio-ruby version
46
+ description: Specify the version of the twilio-ruby helper library you are using.
47
+ placeholder: e.g., 7.4.1
48
+ validations:
49
+ required: true
50
+
51
+ - type: input
52
+ attributes:
53
+ label: Ruby version
54
+ description: Specify the version of Ruby you are using.
55
+ placeholder: e.g., 2.7.2
56
+ validations:
57
+ required: true
58
+
59
+ - type: textarea
60
+ attributes:
61
+ label: Logs or error messages
62
+ description: Provide relevant logs or error messages (if any).
63
+ placeholder: "Error: Something went wrong..."
64
+
65
+ - type: textarea
66
+ attributes:
67
+ label: Additional context
68
+ description: Add any other context about the problem here.
69
+ placeholder: Any additional
data/CHANGES.md CHANGED
@@ -1,6 +1,34 @@
1
1
  twilio-ruby changelog
2
2
  =====================
3
3
 
4
+ [2025-01-28] Version 7.4.3
5
+ --------------------------
6
+ **Library - Chore**
7
+ - [PR #740](https://github.com/twilio/twilio-ruby/pull/740): added bug report issue template. Thanks to [@sbansla](https://github.com/sbansla)!
8
+
9
+ **Api**
10
+ - Add open-api file tag to `conference/call recordings` and `recording_transcriptions`.
11
+
12
+ **Events**
13
+ - Add support for subaccount subscriptions (beta)
14
+
15
+ **Insights**
16
+ - add new region to conference APIs
17
+
18
+ **Lookups**
19
+ - Add new `parnter_sub_id` query parameter to the lookup request
20
+
21
+
22
+ [2025-01-13] Version 7.4.2
23
+ --------------------------
24
+ **Library - Chore**
25
+ - [PR #739](https://github.com/twilio/twilio-ruby/pull/739): add ostruct and benchmark in gemfile. Thanks to [@tiwarishubham635](https://github.com/tiwarishubham635)!
26
+ - [PR #738](https://github.com/twilio/twilio-ruby/pull/738): add ostruct in gemfile. Thanks to [@tiwarishubham635](https://github.com/tiwarishubham635)!
27
+
28
+ **Messaging**
29
+ - Adds validity period Default value in service resource documentation
30
+
31
+
4
32
  [2025-01-09] Version 7.4.1
5
33
  --------------------------
6
34
  **Library - Chore**
data/Gemfile CHANGED
@@ -3,4 +3,6 @@ gem 'simplecov', require: false, group: :test
3
3
  gemspec
4
4
 
5
5
  gem "base64"
6
+ gem "benchmark"
7
+ gem "ostruct"
6
8
  gem "rexml"
data/README.md CHANGED
@@ -39,13 +39,13 @@ This library supports the following Ruby implementations:
39
39
  To install using [Bundler][bundler] grab the latest stable version:
40
40
 
41
41
  ```ruby
42
- gem 'twilio-ruby', '~> 7.4.1'
42
+ gem 'twilio-ruby', '~> 7.4.3'
43
43
  ```
44
44
 
45
45
  To manually install `twilio-ruby` via [Rubygems][rubygems] simply gem install:
46
46
 
47
47
  ```bash
48
- gem install twilio-ruby -v 7.4.1
48
+ gem install twilio-ruby -v 7.4.3
49
49
  ```
50
50
 
51
51
  To build and install the development branch yourself from the latest source:
@@ -48,7 +48,7 @@ module Twilio
48
48
  # @param [String] speech_model Recognition model used by the transcription engine, among those supported by the provider
49
49
  # @param [String] hints A Phrase contains words and phrase \\\"hints\\\" so that the speech recognition engine is more likely to recognize them.
50
50
  # @param [Boolean] enable_automatic_punctuation The provider will add punctuation to recognition result
51
- # @param [String] intelligence_service The SID or the unique name of the [Voice Intelligence Service](https://www.twilio.com/docs/voice/intelligence/api/service-resource) to process the transcription.
51
+ # @param [String] intelligence_service The SID of the [Voice Intelligence Service](https://www.twilio.com/docs/voice/intelligence/api/service-resource) for persisting transcripts and running post-call Language Operators .
52
52
  # @return [TranscriptionInstance] Created TranscriptionInstance
53
53
  def create(
54
54
  name: :unset,
@@ -444,6 +444,25 @@ module Twilio
444
444
  end
445
445
  end
446
446
 
447
+ class TwilioSchedule
448
+ # @param [id]: [String]
449
+ # @param [title]: [String]
450
+ # @param [time_slots]: [String]
451
+ attr_accessor :id, :title, :time_slots
452
+ def initialize(payload)
453
+ @id = payload["id"]
454
+ @title = payload["title"]
455
+ @time_slots = payload["time_slots"]
456
+ end
457
+ def to_json(options = {})
458
+ {
459
+ "id": @id,
460
+ "title": @title,
461
+ "timeSlots": @time_slots,
462
+ }.to_json(options)
463
+ end
464
+ end
465
+
447
466
  class TwilioText
448
467
  # @param [body]: [String]
449
468
  attr_accessor :body
@@ -468,9 +487,10 @@ module Twilio
468
487
  # @param [twilio_catalog]: [ContentList.TwilioCatalog]
469
488
  # @param [twilio_carousel]: [ContentList.TwilioCarousel]
470
489
  # @param [twilio_flows]: [ContentList.TwilioFlows]
490
+ # @param [twilio_schedule]: [ContentList.TwilioSchedule]
471
491
  # @param [whatsapp_card]: [ContentList.WhatsappCard]
472
492
  # @param [whatsapp_authentication]: [ContentList.WhatsappAuthentication]
473
- attr_accessor :twilio_text, :twilio_media, :twilio_location, :twilio_list_picker, :twilio_call_to_action, :twilio_quick_reply, :twilio_card, :twilio_catalog, :twilio_carousel, :twilio_flows, :whatsapp_card, :whatsapp_authentication
493
+ attr_accessor :twilio_text, :twilio_media, :twilio_location, :twilio_list_picker, :twilio_call_to_action, :twilio_quick_reply, :twilio_card, :twilio_catalog, :twilio_carousel, :twilio_flows, :twilio_schedule, :whatsapp_card, :whatsapp_authentication
474
494
  def initialize(payload)
475
495
  @twilio_text = payload["twilio_text"]
476
496
  @twilio_media = payload["twilio_media"]
@@ -482,6 +502,7 @@ module Twilio
482
502
  @twilio_catalog = payload["twilio_catalog"]
483
503
  @twilio_carousel = payload["twilio_carousel"]
484
504
  @twilio_flows = payload["twilio_flows"]
505
+ @twilio_schedule = payload["twilio_schedule"]
485
506
  @whatsapp_card = payload["whatsapp_card"]
486
507
  @whatsapp_authentication = payload["whatsapp_authentication"]
487
508
  end
@@ -497,6 +518,7 @@ module Twilio
497
518
  "twilio/catalog": @twilio_catalog,
498
519
  "twilio/carousel": @twilio_carousel,
499
520
  "twilio/flows": @twilio_flows,
521
+ "twilio/schedule": @twilio_schedule,
500
522
  "whatsapp/card": @whatsapp_card,
501
523
  "whatsapp/authentication": @whatsapp_authentication,
502
524
  }.to_json(options)
@@ -77,7 +77,7 @@ module Twilio
77
77
  ##
78
78
  # Update the WebhookInstance
79
79
  # @param [String] method The HTTP method to be used when sending a webhook request.
80
- # @param [Array[String]] filters The list of webhook event triggers that are enabled for this Service: `onMessageAdded`, `onMessageUpdated`, `onMessageRemoved`, `onConversationUpdated`, `onConversationRemoved`, `onParticipantAdded`, `onParticipantUpdated`, `onParticipantRemoved`
80
+ # @param [Array[String]] filters The list of webhook event triggers that are enabled for this Service: `onMessageAdded`, `onMessageUpdated`, `onMessageRemoved`, `onMessageAdd`, `onMessageUpdate`, `onMessageRemove`, `onConversationUpdated`, `onConversationRemoved`, `onConversationAdd`, `onConversationAdded`, `onConversationRemove`, `onConversationUpdate`, `onConversationStateUpdated`, `onParticipantAdded`, `onParticipantUpdated`, `onParticipantRemoved`, `onParticipantAdd`, `onParticipantRemove`, `onParticipantUpdate`, `onDeliveryUpdated`, `onUserAdded`, `onUserUpdate`, `onUserUpdated`
81
81
  # @param [String] pre_webhook_url The absolute url the pre-event webhook request should be sent to.
82
82
  # @param [String] post_webhook_url The absolute url the post-event webhook request should be sent to.
83
83
  # @param [Target] target
@@ -208,7 +208,7 @@ module Twilio
208
208
  end
209
209
 
210
210
  ##
211
- # @return [Array<String>] The list of webhook event triggers that are enabled for this Service: `onMessageAdded`, `onMessageUpdated`, `onMessageRemoved`, `onConversationUpdated`, `onConversationRemoved`, `onParticipantAdded`, `onParticipantUpdated`, `onParticipantRemoved`
211
+ # @return [Array<String>] The list of webhook event triggers that are enabled for this Service: `onMessageAdded`, `onMessageUpdated`, `onMessageRemoved`, `onMessageAdd`, `onMessageUpdate`, `onMessageRemove`, `onConversationUpdated`, `onConversationRemoved`, `onConversationAdd`, `onConversationAdded`, `onConversationRemove`, `onConversationUpdate`, `onConversationStateUpdated`, `onParticipantAdded`, `onParticipantUpdated`, `onParticipantRemoved`, `onParticipantAdd`, `onParticipantRemove`, `onParticipantUpdate`, `onDeliveryUpdated`, `onUserAdded`, `onUserUpdate`, `onUserUpdated`
212
212
  def filters
213
213
  @properties['filters']
214
214
  end
@@ -248,7 +248,7 @@ module Twilio
248
248
  ##
249
249
  # Update the WebhookInstance
250
250
  # @param [String] method The HTTP method to be used when sending a webhook request.
251
- # @param [Array[String]] filters The list of webhook event triggers that are enabled for this Service: `onMessageAdded`, `onMessageUpdated`, `onMessageRemoved`, `onConversationUpdated`, `onConversationRemoved`, `onParticipantAdded`, `onParticipantUpdated`, `onParticipantRemoved`
251
+ # @param [Array[String]] filters The list of webhook event triggers that are enabled for this Service: `onMessageAdded`, `onMessageUpdated`, `onMessageRemoved`, `onMessageAdd`, `onMessageUpdate`, `onMessageRemove`, `onConversationUpdated`, `onConversationRemoved`, `onConversationAdd`, `onConversationAdded`, `onConversationRemove`, `onConversationUpdate`, `onConversationStateUpdated`, `onParticipantAdded`, `onParticipantUpdated`, `onParticipantRemoved`, `onParticipantAdd`, `onParticipantRemove`, `onParticipantUpdate`, `onDeliveryUpdated`, `onUserAdded`, `onUserUpdate`, `onUserUpdated`
252
252
  # @param [String] pre_webhook_url The absolute url the pre-event webhook request should be sent to.
253
253
  # @param [String] post_webhook_url The absolute url the post-event webhook request should be sent to.
254
254
  # @param [Target] target
@@ -35,17 +35,20 @@ module Twilio
35
35
  # @param [String] description A human readable description for the Subscription **This value should not contain PII.**
36
36
  # @param [String] sink_sid The SID of the sink that events selected by this subscription should be sent to. Sink must be active for the subscription to be created.
37
37
  # @param [Array[Hash]] types An array of objects containing the subscribed Event Types
38
+ # @param [Boolean] receive_events_from_subaccounts Receive events from all children accounts in the parent account subscription.
38
39
  # @return [SubscriptionInstance] Created SubscriptionInstance
39
40
  def create(
40
41
  description: nil,
41
42
  sink_sid: nil,
42
- types: nil
43
+ types: nil,
44
+ receive_events_from_subaccounts: :unset
43
45
  )
44
46
 
45
47
  data = Twilio::Values.of({
46
48
  'Description' => description,
47
49
  'SinkSid' => sink_sid,
48
50
  'Types' => Twilio.serialize_list(types) { |e| Twilio.serialize_object(e) },
51
+ 'ReceiveEventsFromSubaccounts' => receive_events_from_subaccounts,
49
52
  })
50
53
 
51
54
  headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
@@ -215,15 +218,18 @@ module Twilio
215
218
  # Update the SubscriptionInstance
216
219
  # @param [String] description A human readable description for the Subscription.
217
220
  # @param [String] sink_sid The SID of the sink that events selected by this subscription should be sent to. Sink must be active for the subscription to be created.
221
+ # @param [Boolean] receive_events_from_subaccounts Receive events from all children accounts in the parent account subscription.
218
222
  # @return [SubscriptionInstance] Updated SubscriptionInstance
219
223
  def update(
220
224
  description: :unset,
221
- sink_sid: :unset
225
+ sink_sid: :unset,
226
+ receive_events_from_subaccounts: :unset
222
227
  )
223
228
 
224
229
  data = Twilio::Values.of({
225
230
  'Description' => description,
226
231
  'SinkSid' => sink_sid,
232
+ 'ReceiveEventsFromSubaccounts' => receive_events_from_subaccounts,
227
233
  })
228
234
 
229
235
  headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
@@ -326,6 +332,7 @@ module Twilio
326
332
  'sink_sid' => payload['sink_sid'],
327
333
  'url' => payload['url'],
328
334
  'links' => payload['links'],
335
+ 'receive_events_from_subaccounts' => payload['receive_events_from_subaccounts'],
329
336
  }
330
337
 
331
338
  # Context
@@ -392,6 +399,12 @@ module Twilio
392
399
  @properties['links']
393
400
  end
394
401
 
402
+ ##
403
+ # @return [Boolean] Receive events from all children accounts in the parent account subscription.
404
+ def receive_events_from_subaccounts
405
+ @properties['receive_events_from_subaccounts']
406
+ end
407
+
395
408
  ##
396
409
  # Delete the SubscriptionInstance
397
410
  # @return [Boolean] True if delete succeeds, false otherwise
@@ -412,15 +425,18 @@ module Twilio
412
425
  # Update the SubscriptionInstance
413
426
  # @param [String] description A human readable description for the Subscription.
414
427
  # @param [String] sink_sid The SID of the sink that events selected by this subscription should be sent to. Sink must be active for the subscription to be created.
428
+ # @param [Boolean] receive_events_from_subaccounts Receive events from all children accounts in the parent account subscription.
415
429
  # @return [SubscriptionInstance] Updated SubscriptionInstance
416
430
  def update(
417
431
  description: :unset,
418
- sink_sid: :unset
432
+ sink_sid: :unset,
433
+ receive_events_from_subaccounts: :unset
419
434
  )
420
435
 
421
436
  context.update(
422
437
  description: description,
423
438
  sink_sid: sink_sid,
439
+ receive_events_from_subaccounts: receive_events_from_subaccounts,
424
440
  )
425
441
  end
426
442
 
@@ -71,6 +71,7 @@ module Twilio
71
71
  # @param [String] date_of_birth User’s date of birth, in YYYYMMDD format. This query parameter is only used (optionally) for identity_match package requests.
72
72
  # @param [String] last_verified_date The date you obtained consent to call or text the end-user of the phone number or a date on which you are reasonably certain that the end-user could still be reached at that number. This query parameter is only used (optionally) for reassigned_number package requests.
73
73
  # @param [String] verification_sid The unique identifier associated with a verification process through verify API. This query parameter is only used (optionally) for pre_fill package requests.
74
+ # @param [String] partner_sub_id The optional partnerSubId parameter to provide context for your sub-accounts, tenantIDs, sender IDs or other segmentation, enhancing the accuracy of the risk analysis.
74
75
  # @return [PhoneNumberInstance] Fetched PhoneNumberInstance
75
76
  def fetch(
76
77
  fields: :unset,
@@ -86,7 +87,8 @@ module Twilio
86
87
  national_id: :unset,
87
88
  date_of_birth: :unset,
88
89
  last_verified_date: :unset,
89
- verification_sid: :unset
90
+ verification_sid: :unset,
91
+ partner_sub_id: :unset
90
92
  )
91
93
 
92
94
  params = Twilio::Values.of({
@@ -104,6 +106,7 @@ module Twilio
104
106
  'DateOfBirth' => date_of_birth,
105
107
  'LastVerifiedDate' => last_verified_date,
106
108
  'VerificationSid' => verification_sid,
109
+ 'PartnerSubId' => partner_sub_id,
107
110
  })
108
111
  headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
109
112
 
@@ -331,6 +334,7 @@ module Twilio
331
334
  # @param [String] date_of_birth User’s date of birth, in YYYYMMDD format. This query parameter is only used (optionally) for identity_match package requests.
332
335
  # @param [String] last_verified_date The date you obtained consent to call or text the end-user of the phone number or a date on which you are reasonably certain that the end-user could still be reached at that number. This query parameter is only used (optionally) for reassigned_number package requests.
333
336
  # @param [String] verification_sid The unique identifier associated with a verification process through verify API. This query parameter is only used (optionally) for pre_fill package requests.
337
+ # @param [String] partner_sub_id The optional partnerSubId parameter to provide context for your sub-accounts, tenantIDs, sender IDs or other segmentation, enhancing the accuracy of the risk analysis.
334
338
  # @return [PhoneNumberInstance] Fetched PhoneNumberInstance
335
339
  def fetch(
336
340
  fields: :unset,
@@ -346,7 +350,8 @@ module Twilio
346
350
  national_id: :unset,
347
351
  date_of_birth: :unset,
348
352
  last_verified_date: :unset,
349
- verification_sid: :unset
353
+ verification_sid: :unset,
354
+ partner_sub_id: :unset
350
355
  )
351
356
 
352
357
  context.fetch(
@@ -364,6 +369,7 @@ module Twilio
364
369
  date_of_birth: date_of_birth,
365
370
  last_verified_date: last_verified_date,
366
371
  verification_sid: verification_sid,
372
+ partner_sub_id: partner_sub_id,
367
373
  )
368
374
  end
369
375
 
@@ -0,0 +1,221 @@
1
+ ##
2
+ # This code was generated by
3
+ # ___ _ _ _ _ _ _ ____ ____ ____ _ ____ ____ _ _ ____ ____ ____ ___ __ __
4
+ # | | | | | | | | | __ | | |__| | __ | __ |___ |\ | |___ |__/ |__| | | | |__/
5
+ # | |_|_| | |___ | |__| |__| | | | |__] |___ | \| |___ | \ | | | |__| | \
6
+ #
7
+ # Twilio - Marketplace
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 Marketplace < MarketplaceBase
19
+ class V1 < Version
20
+ class ModuleDataList < ListResource
21
+
22
+ ##
23
+ # Initialize the ModuleDataList
24
+ # @param [Version] version Version that contains the resource
25
+ # @return [ModuleDataList] ModuleDataList
26
+ def initialize(version)
27
+ super(version)
28
+ # Path Solution
29
+ @solution = { }
30
+ @uri = "/Listings"
31
+
32
+ end
33
+ ##
34
+ # Create the ModuleDataInstance
35
+ # @param [String] module_info A JSON object containing essential attributes that define a Listing.
36
+ # @param [String] configuration A JSON object for providing Listing-specific configuration. Contains button setup, notification URL, and more.
37
+ # @return [ModuleDataInstance] Created ModuleDataInstance
38
+ def create(
39
+ module_info: :unset,
40
+ configuration: :unset
41
+ )
42
+
43
+ data = Twilio::Values.of({
44
+ 'ModuleInfo' => module_info,
45
+ 'Configuration' => configuration,
46
+ })
47
+
48
+ headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
49
+
50
+
51
+
52
+
53
+
54
+ payload = @version.create('POST', @uri, data: data, headers: headers)
55
+ ModuleDataInstance.new(
56
+ @version,
57
+ payload,
58
+ )
59
+ end
60
+
61
+ ##
62
+ # Fetch the ModuleDataInstance
63
+ # @return [ModuleDataInstance] Fetched ModuleDataInstance
64
+ def fetch
65
+
66
+ headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
67
+
68
+
69
+
70
+
71
+
72
+ payload = @version.fetch('GET', @uri, headers: headers)
73
+ ModuleDataInstance.new(
74
+ @version,
75
+ payload,
76
+ )
77
+ end
78
+
79
+
80
+
81
+
82
+ # Provide a user friendly representation
83
+ def to_s
84
+ '#<Twilio.Marketplace.V1.ModuleDataList>'
85
+ end
86
+ end
87
+
88
+ class ModuleDataPage < Page
89
+ ##
90
+ # Initialize the ModuleDataPage
91
+ # @param [Version] version Version that contains the resource
92
+ # @param [Response] response Response from the API
93
+ # @param [Hash] solution Path solution for the resource
94
+ # @return [ModuleDataPage] ModuleDataPage
95
+ def initialize(version, response, solution)
96
+ super(version, response)
97
+
98
+ # Path Solution
99
+ @solution = solution
100
+ end
101
+
102
+ ##
103
+ # Build an instance of ModuleDataInstance
104
+ # @param [Hash] payload Payload response from the API
105
+ # @return [ModuleDataInstance] ModuleDataInstance
106
+ def get_instance(payload)
107
+ ModuleDataInstance.new(@version, payload)
108
+ end
109
+
110
+ ##
111
+ # Provide a user friendly representation
112
+ def to_s
113
+ '<Twilio.Marketplace.V1.ModuleDataPage>'
114
+ end
115
+ end
116
+ class ModuleDataInstance < InstanceResource
117
+ ##
118
+ # Initialize the ModuleDataInstance
119
+ # @param [Version] version Version that contains the resource
120
+ # @param [Hash] payload payload that contains response from Twilio
121
+ # @param [String] account_sid The SID of the
122
+ # {Account}[https://www.twilio.com/docs/iam/api/account] that created this ModuleData
123
+ # resource.
124
+ # @param [String] sid The SID of the Call resource to fetch.
125
+ # @return [ModuleDataInstance] ModuleDataInstance
126
+ def initialize(version, payload )
127
+ super(version)
128
+
129
+ # Marshaled Properties
130
+ @properties = {
131
+ 'url' => payload['url'],
132
+ 'sid' => payload['sid'],
133
+ 'description' => payload['description'],
134
+ 'support' => payload['support'],
135
+ 'policies' => payload['policies'],
136
+ 'module_info' => payload['module_info'],
137
+ 'documentation' => payload['documentation'],
138
+ 'configuration' => payload['configuration'],
139
+ 'pricing' => payload['pricing'],
140
+ 'listings' => payload['listings'],
141
+ }
142
+ end
143
+
144
+
145
+ ##
146
+ # @return [String] URL to query the subresource.
147
+ def url
148
+ @properties['url']
149
+ end
150
+
151
+ ##
152
+ # @return [String] ModuleSid that identifies this Listing.
153
+ def sid
154
+ @properties['sid']
155
+ end
156
+
157
+ ##
158
+ # @return [Hash] A JSON object describing the module and is displayed under the Description tab of the Module detail page. You can define the main body of the description, highlight key features or aspects of the module and if applicable, provide code samples for developers
159
+ def description
160
+ @properties['description']
161
+ end
162
+
163
+ ##
164
+ # @return [Hash] A JSON object containing information on how customers can obtain support for the module. Use this parameter to provide details such as contact information and support description.
165
+ def support
166
+ @properties['support']
167
+ end
168
+
169
+ ##
170
+ # @return [Hash] A JSON object describing the module's privacy and legal policies and is displayed under the Policies tab of the Module detail page. The maximum file size for Policies is 5MB
171
+ def policies
172
+ @properties['policies']
173
+ end
174
+
175
+ ##
176
+ # @return [Hash] A JSON object containing essential attributes that define a module. This information is presented on the Module detail page in the Twilio Marketplace Catalog. You can pass the following attributes in the JSON object
177
+ def module_info
178
+ @properties['module_info']
179
+ end
180
+
181
+ ##
182
+ # @return [Hash] A JSON object for providing comprehensive information, instructions, and resources related to the module
183
+ def documentation
184
+ @properties['documentation']
185
+ end
186
+
187
+ ##
188
+ # @return [Hash] A JSON object for providing listing specific configuration. Contains button setup, notification url, among others.
189
+ def configuration
190
+ @properties['configuration']
191
+ end
192
+
193
+ ##
194
+ # @return [Hash] A JSON object for providing Listing specific pricing information.
195
+ def pricing
196
+ @properties['pricing']
197
+ end
198
+
199
+ ##
200
+ # @return [Array<Hash>]
201
+ def listings
202
+ @properties['listings']
203
+ end
204
+
205
+ ##
206
+ # Provide a user friendly representation
207
+ def to_s
208
+ "<Twilio.Marketplace.V1.ModuleDataInstance>"
209
+ end
210
+
211
+ ##
212
+ # Provide a detailed, user friendly representation
213
+ def inspect
214
+ "<Twilio.Marketplace.V1.ModuleDataInstance>"
215
+ end
216
+ end
217
+
218
+ end
219
+ end
220
+ end
221
+ end
@@ -186,6 +186,7 @@ module Twilio
186
186
  'documentation' => payload['documentation'],
187
187
  'configuration' => payload['configuration'],
188
188
  'pricing' => payload['pricing'],
189
+ 'listings' => payload['listings'],
189
190
  }
190
191
 
191
192
  # Context
@@ -258,6 +259,12 @@ module Twilio
258
259
  @properties['pricing']
259
260
  end
260
261
 
262
+ ##
263
+ # @return [Array<Hash>]
264
+ def listings
265
+ @properties['listings']
266
+ end
267
+
261
268
  ##
262
269
  # Fetch the ModuleDataManagementInstance
263
270
  # @return [ModuleDataManagementInstance] Fetched ModuleDataManagementInstance
@@ -23,6 +23,7 @@ module Twilio
23
23
  @version = 'v1'
24
24
  @available_add_ons = nil
25
25
  @installed_add_ons = nil
26
+ @module_data = nil
26
27
  @module_data_management = nil
27
28
  @referral_conversion = nil
28
29
  end
@@ -56,6 +57,11 @@ module Twilio
56
57
  end
57
58
  end
58
59
  ##
60
+ # @return [Twilio::REST::Marketplace::V1::ModuleDataList]
61
+ def module_data
62
+ @module_data ||= ModuleDataList.new self
63
+ end
64
+ ##
59
65
  # @param [String] sid The unique identifier of a Listing.
60
66
  # @return [Twilio::REST::Marketplace::V1::ModuleDataManagementContext] if sid was passed.
61
67
  # @return [Twilio::REST::Marketplace::V1::ModuleDataManagementList]
@@ -44,7 +44,7 @@ module Twilio
44
44
  # @param [ScanMessageContent] scan_message_content
45
45
  # @param [Boolean] fallback_to_long_code [OBSOLETE] Former feature used to fallback to long code sender after certain short code message failures.
46
46
  # @param [Boolean] area_code_geomatch Whether to enable [Area Code Geomatch](https://www.twilio.com/docs/messaging/services#area-code-geomatch) on the Service Instance.
47
- # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`.
47
+ # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`.
48
48
  # @param [Boolean] synchronous_validation Reserved.
49
49
  # @param [String] usecase A string that describes the scenario in which the Messaging Service will be used. Possible values are `notifications`, `marketing`, `verification`, `discussion`, `poll`, `undeclared`.
50
50
  # @param [Boolean] use_inbound_webhook_on_number A boolean value that indicates either the webhook url configured on the phone number will be used or `inbound_request_url`/`fallback_url` url will be called when a message is received from the phone number. If this field is enabled then the webhook url defined on the phone number will override the `inbound_request_url`/`fallback_url` defined for the Messaging Service.
@@ -263,7 +263,7 @@ module Twilio
263
263
  # @param [ScanMessageContent] scan_message_content
264
264
  # @param [Boolean] fallback_to_long_code [OBSOLETE] Former feature used to fallback to long code sender after certain short code message failures.
265
265
  # @param [Boolean] area_code_geomatch Whether to enable [Area Code Geomatch](https://www.twilio.com/docs/messaging/services#area-code-geomatch) on the Service Instance.
266
- # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`.
266
+ # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`.
267
267
  # @param [Boolean] synchronous_validation Reserved.
268
268
  # @param [String] usecase A string that describes the scenario in which the Messaging Service will be used. Possible values are `notifications`, `marketing`, `verification`, `discussion`, `poll`, `undeclared`.
269
269
  # @param [Boolean] use_inbound_webhook_on_number A boolean value that indicates either the webhook url configured on the phone number will be used or `inbound_request_url`/`fallback_url` url will be called when a message is received from the phone number. If this field is enabled then the webhook url defined on the phone number will override the `inbound_request_url`/`fallback_url` defined for the Messaging Service.
@@ -629,7 +629,7 @@ module Twilio
629
629
  end
630
630
 
631
631
  ##
632
- # @return [String] How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`.
632
+ # @return [String] How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`.
633
633
  def validity_period
634
634
  @properties['validity_period']
635
635
  end
@@ -694,7 +694,7 @@ module Twilio
694
694
  # @param [ScanMessageContent] scan_message_content
695
695
  # @param [Boolean] fallback_to_long_code [OBSOLETE] Former feature used to fallback to long code sender after certain short code message failures.
696
696
  # @param [Boolean] area_code_geomatch Whether to enable [Area Code Geomatch](https://www.twilio.com/docs/messaging/services#area-code-geomatch) on the Service Instance.
697
- # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`.
697
+ # @param [String] validity_period How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`.
698
698
  # @param [Boolean] synchronous_validation Reserved.
699
699
  # @param [String] usecase A string that describes the scenario in which the Messaging Service will be used. Possible values are `notifications`, `marketing`, `verification`, `discussion`, `poll`, `undeclared`.
700
700
  # @param [Boolean] use_inbound_webhook_on_number A boolean value that indicates either the webhook url configured on the phone number will be used or `inbound_request_url`/`fallback_url` url will be called when a message is received from the phone number. If this field is enabled then the webhook url defined on the phone number will override the `inbound_request_url`/`fallback_url` defined for the Messaging Service.
@@ -1,3 +1,3 @@
1
1
  module Twilio
2
- VERSION = '7.4.1'
2
+ VERSION = '7.4.3'
3
3
  end
data/twilio-ruby.gemspec CHANGED
@@ -28,6 +28,8 @@ Gem::Specification.new do |spec|
28
28
  spec.add_dependency('jwt', '>= 1.5', '< 3.0')
29
29
  spec.add_dependency('nokogiri', '>= 1.6', '< 2.0')
30
30
  spec.add_dependency('faraday', '>= 0.9', '< 3.0')
31
+ spec.add_dependency 'ostruct'
32
+ spec.add_dependency 'benchmark'
31
33
  # Workaround for RBX <= 2.2.1, should be fixed in next version
32
34
  spec.add_dependency('rubysl') if defined?(RUBY_ENGINE) && RUBY_ENGINE == 'rbx'
33
35
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: twilio-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.4.1
4
+ version: 7.4.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Twilio API Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-01-09 00:00:00.000000000 Z
11
+ date: 2025-01-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jwt
@@ -70,6 +70,34 @@ dependencies:
70
70
  - - "<"
71
71
  - !ruby/object:Gem::Version
72
72
  version: '3.0'
73
+ - !ruby/object:Gem::Dependency
74
+ name: ostruct
75
+ requirement: !ruby/object:Gem::Requirement
76
+ requirements:
77
+ - - ">="
78
+ - !ruby/object:Gem::Version
79
+ version: '0'
80
+ type: :runtime
81
+ prerelease: false
82
+ version_requirements: !ruby/object:Gem::Requirement
83
+ requirements:
84
+ - - ">="
85
+ - !ruby/object:Gem::Version
86
+ version: '0'
87
+ - !ruby/object:Gem::Dependency
88
+ name: benchmark
89
+ requirement: !ruby/object:Gem::Requirement
90
+ requirements:
91
+ - - ">="
92
+ - !ruby/object:Gem::Version
93
+ version: '0'
94
+ type: :runtime
95
+ prerelease: false
96
+ version_requirements: !ruby/object:Gem::Requirement
97
+ requirements:
98
+ - - ">="
99
+ - !ruby/object:Gem::Version
100
+ version: '0'
73
101
  - !ruby/object:Gem::Dependency
74
102
  name: bundler
75
103
  requirement: !ruby/object:Gem::Requirement
@@ -198,6 +226,7 @@ extra_rdoc_files:
198
226
  - LICENSE
199
227
  files:
200
228
  - ".dockerignore"
229
+ - ".github/ISSUE_TEMPLATE/bug_report.yml"
201
230
  - ".github/workflows/pr-lint.yml"
202
231
  - ".github/workflows/test-and-deploy.yml"
203
232
  - ".gitignore"
@@ -563,6 +592,7 @@ files:
563
592
  - lib/twilio-ruby/rest/marketplace/v1/installed_add_on.rb
564
593
  - lib/twilio-ruby/rest/marketplace/v1/installed_add_on/installed_add_on_extension.rb
565
594
  - lib/twilio-ruby/rest/marketplace/v1/installed_add_on/installed_add_on_usage.rb
595
+ - lib/twilio-ruby/rest/marketplace/v1/module_data.rb
566
596
  - lib/twilio-ruby/rest/marketplace/v1/module_data_management.rb
567
597
  - lib/twilio-ruby/rest/marketplace/v1/referral_conversion.rb
568
598
  - lib/twilio-ruby/rest/marketplace_base.rb