Skip to content

Commit

Permalink
[Librarian] Regenerated @ 29d344435d2eacaa41b65d3f4430047ad5fe380f
Browse files Browse the repository at this point in the history
  • Loading branch information
twilio-dx committed Oct 6, 2021
1 parent 859b4fd commit 5d2e462
Show file tree
Hide file tree
Showing 45 changed files with 1,975 additions and 316 deletions.
36 changes: 36 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,42 @@
twilio-ruby changelog
=====================

[2021-10-06] Version 5.59.0
---------------------------
**Library - Fix**
- [PR #571](https://github.com/twilio/twilio-ruby/pull/571): fix travis build for ruby 3.0. Thanks to [@JenniferMah](https://github.com/JenniferMah)!

**Api**
- Add `emergency_address_status` attribute to `/IncomingPhoneNumbers` response.
- Add `siprec` resource

**Conversations**
- Added attachment parameters in configuration for `NewMessage` type of push notifications

**Flex**
- Adding `flex_insights_hr` object to Flex Configuration

**Numbers**
- Add API endpoint for Bundle ReplaceItems resource
- Add API endpoint for Bundle Copies resource

**Serverless**
- Add domain_base field to Service response

**Taskrouter**
- Add `If-Match` Header based on ETag for Worker Delete **(breaking change)**
- Add `If-Match` Header based on Etag for Reservation Update
- Add `If-Match` Header based on ETag for Worker Update
- Add `If-Match` Header based on ETag for Worker Delete
- Add `ETag` as Response Header to Worker

**Trunking**
- Added `transfer_caller_id` property on Trunks.

**Verify**
- Document new pilot `whatsapp` channel.


[2021-09-22] Version 5.58.3
---------------------------
**Events**
Expand Down
28 changes: 27 additions & 1 deletion lib/twilio-ruby/rest/api/v2010/account/call.rb
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ def initialize(version, account_sid: nil)
# section in {Making Calls}[https://www.twilio.com/docs/voice/make-calls].
# @param [String] twiml TwiML instructions for the call Twilio will use without
# fetching Twiml from url parameter. If both `twiml` and `url` are provided then
# `twiml` parameter will be ignored.
# `twiml` parameter will be ignored. Max 4000 characters.
# @param [String] application_sid The SID of the Application resource that will
# handle the call, if the call will be handled by an application.
# @return [CallInstance] Created CallInstance
Expand Down Expand Up @@ -442,6 +442,7 @@ def initialize(version, account_sid, sid)
@feedback = nil
@events = nil
@payments = nil
@siprec = nil
end

##
Expand Down Expand Up @@ -598,6 +599,24 @@ def payments(sid=:unset)
@payments
end

##
# Access the siprec
# @return [SiprecList]
# @return [SiprecContext] if sid was passed.
def siprec(sid=:unset)
raise ArgumentError, 'sid cannot be nil' if sid.nil?

if sid != :unset
return SiprecContext.new(@version, @solution[:account_sid], @solution[:sid], sid, )
end

unless @siprec
@siprec = SiprecList.new(@version, account_sid: @solution[:account_sid], call_sid: @solution[:sid], )
end

@siprec
end

##
# Provide a user friendly representation
def to_s
Expand Down Expand Up @@ -932,6 +951,13 @@ def payments
context.payments
end

##
# Access the siprec
# @return [siprec] siprec
def siprec
context.siprec
end

##
# Provide a user friendly representation
def to_s
Expand Down
667 changes: 667 additions & 0 deletions lib/twilio-ruby/rest/api/v2010/account/call/siprec.rb

Large diffs are not rendered by default.

20 changes: 10 additions & 10 deletions lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number.rb
Original file line number Diff line number Diff line change
Expand Up @@ -199,9 +199,9 @@ def get_page(target_url)
# @param [String] voice_url The URL that we should call to answer a call to the
# new phone number. The `voice_url` will not be called if a
# `voice_application_sid` or a `trunk_sid` is set.
# @param [incoming_phone_number.EmergencyStatus] emergency_status The
# configuration status parameter that determines whether the new phone number is
# enabled for emergency calling.
# @param [incoming_phone_number.EmergencyStatus] emergency_status The parameter
# displays if emergency calling is enabled for this number. Active numbers may
# place emergency calls by dialing valid emergency numbers for the country.
# @param [String] emergency_address_sid The SID of the emergency address
# configuration to use for emergency calling from the new phone number.
# @param [String] trunk_sid The SID of the Trunk we should use to handle calls to
Expand Down Expand Up @@ -387,9 +387,9 @@ def initialize(version, account_sid, sid)
# @param [String] voice_url The URL that we should call to answer a call to the
# phone number. The `voice_url` will not be called if a `voice_application_sid` or
# a `trunk_sid` is set.
# @param [incoming_phone_number.EmergencyStatus] emergency_status The
# configuration status parameter that determines whether the phone number is
# enabled for emergency calling.
# @param [incoming_phone_number.EmergencyStatus] emergency_status The parameter
# displays if emergency calling is enabled for this number. Active numbers may
# place emergency calls by dialing valid emergency numbers for the country.
# @param [String] emergency_address_sid The SID of the emergency address
# configuration to use for emergency calling from this phone number.
# @param [String] trunk_sid The SID of the Trunk we should use to handle phone
Expand Down Expand Up @@ -745,7 +745,7 @@ def voice_url
end

##
# @return [incoming_phone_number.EmergencyStatus] Whether the phone number is enabled for emergency calling
# @return [incoming_phone_number.EmergencyStatus] Displays if emergency calling is enabled for this number.
def emergency_status
@properties['emergency_status']
end
Expand Down Expand Up @@ -812,9 +812,9 @@ def status
# @param [String] voice_url The URL that we should call to answer a call to the
# phone number. The `voice_url` will not be called if a `voice_application_sid` or
# a `trunk_sid` is set.
# @param [incoming_phone_number.EmergencyStatus] emergency_status The
# configuration status parameter that determines whether the phone number is
# enabled for emergency calling.
# @param [incoming_phone_number.EmergencyStatus] emergency_status The parameter
# displays if emergency calling is enabled for this number. Active numbers may
# place emergency calls by dialing valid emergency numbers for the country.
# @param [String] emergency_address_sid The SID of the emergency address
# configuration to use for emergency calling from this phone number.
# @param [String] trunk_sid The SID of the Trunk we should use to handle phone
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -202,9 +202,9 @@ def get_page(target_url)
# @param [String] address_sid The SID of the Address resource we should associate
# with the new phone number. Some regions require addresses to meet local
# regulations.
# @param [local.EmergencyStatus] emergency_status The configuration status
# parameter that determines whether the new phone number is enabled for emergency
# calling.
# @param [local.EmergencyStatus] emergency_status The parameter displays if
# emergency calling is enabled for this number. Active numbers may place emergency
# calls by dialing valid emergency numbers for the country.
# @param [String] emergency_address_sid The SID of the emergency address
# configuration to use for emergency calling from the new phone number.
# @param [String] trunk_sid The SID of the Trunk we should use to handle calls to
Expand Down Expand Up @@ -511,7 +511,7 @@ def voice_url
end

##
# @return [local.EmergencyStatus] Whether the phone number is enabled for emergency calling
# @return [local.EmergencyStatus] Displays if emergency calling is enabled for this number.
def emergency_status
@properties['emergency_status']
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -201,9 +201,9 @@ def get_page(target_url)
# @param [String] address_sid The SID of the Address resource we should associate
# with the new phone number. Some regions require addresses to meet local
# regulations.
# @param [mobile.EmergencyStatus] emergency_status The configuration status
# parameter that determines whether the new phone number is enabled for emergency
# calling.
# @param [mobile.EmergencyStatus] emergency_status The parameter displays if
# emergency calling is enabled for this number. Active numbers may place emergency
# calls by dialing valid emergency numbers for the country.
# @param [String] emergency_address_sid The SID of the emergency address
# configuration to use for emergency calling from the new phone number.
# @param [String] trunk_sid The SID of the Trunk we should use to handle calls to
Expand Down Expand Up @@ -510,7 +510,7 @@ def voice_url
end

##
# @return [mobile.EmergencyStatus] Whether the phone number is enabled for emergency calling
# @return [mobile.EmergencyStatus] Displays if emergency calling is enabled for this number.
def emergency_status
@properties['emergency_status']
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -201,9 +201,9 @@ def get_page(target_url)
# @param [String] address_sid The SID of the Address resource we should associate
# with the new phone number. Some regions require addresses to meet local
# regulations.
# @param [toll_free.EmergencyStatus] emergency_status The configuration status
# parameter that determines whether the new phone number is enabled for emergency
# calling.
# @param [toll_free.EmergencyStatus] emergency_status The parameter displays if
# emergency calling is enabled for this number. Active numbers may place emergency
# calls by dialing valid emergency numbers for the country.
# @param [String] emergency_address_sid The SID of the emergency address
# configuration to use for emergency calling from the new phone number.
# @param [String] trunk_sid The SID of the Trunk we should use to handle calls to
Expand Down Expand Up @@ -510,7 +510,7 @@ def voice_url
end

##
# @return [toll_free.EmergencyStatus] Whether the phone number is enabled for emergency calling
# @return [toll_free.EmergencyStatus] Displays if emergency calling is enabled for this number.
def emergency_status
@properties['emergency_status']
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,14 @@ def initialize(version, chat_service_sid)
# @param [String] removed_from_conversation_sound The name of the sound to play to
# a user when they are removed from a conversation and
# `removed_from_conversation.enabled` is `true`.
# @param [Boolean] new_message_with_media_enabled Whether to send a notification
# when a new message with media/file attachments is added to a conversation. The
# default is `false`.
# @param [String] new_message_with_media_template The template to use to create
# the notification text displayed when a new message with media/file attachments
# is added to a conversation and `new_message.attachments.enabled` is `true`.
# @return [NotificationInstance] Updated NotificationInstance
def update(log_enabled: :unset, new_message_enabled: :unset, new_message_template: :unset, new_message_sound: :unset, new_message_badge_count_enabled: :unset, added_to_conversation_enabled: :unset, added_to_conversation_template: :unset, added_to_conversation_sound: :unset, removed_from_conversation_enabled: :unset, removed_from_conversation_template: :unset, removed_from_conversation_sound: :unset)
def update(log_enabled: :unset, new_message_enabled: :unset, new_message_template: :unset, new_message_sound: :unset, new_message_badge_count_enabled: :unset, added_to_conversation_enabled: :unset, added_to_conversation_template: :unset, added_to_conversation_sound: :unset, removed_from_conversation_enabled: :unset, removed_from_conversation_template: :unset, removed_from_conversation_sound: :unset, new_message_with_media_enabled: :unset, new_message_with_media_template: :unset)
data = Twilio::Values.of({
'LogEnabled' => log_enabled,
'NewMessage.Enabled' => new_message_enabled,
Expand All @@ -121,6 +127,8 @@ def update(log_enabled: :unset, new_message_enabled: :unset, new_message_templat
'RemovedFromConversation.Enabled' => removed_from_conversation_enabled,
'RemovedFromConversation.Template' => removed_from_conversation_template,
'RemovedFromConversation.Sound' => removed_from_conversation_sound,
'NewMessage.WithMedia.Enabled' => new_message_with_media_enabled,
'NewMessage.WithMedia.Template' => new_message_with_media_template,
})

payload = @version.update('POST', @uri, data: data)
Expand Down Expand Up @@ -261,8 +269,14 @@ def url
# @param [String] removed_from_conversation_sound The name of the sound to play to
# a user when they are removed from a conversation and
# `removed_from_conversation.enabled` is `true`.
# @param [Boolean] new_message_with_media_enabled Whether to send a notification
# when a new message with media/file attachments is added to a conversation. The
# default is `false`.
# @param [String] new_message_with_media_template The template to use to create
# the notification text displayed when a new message with media/file attachments
# is added to a conversation and `new_message.attachments.enabled` is `true`.
# @return [NotificationInstance] Updated NotificationInstance
def update(log_enabled: :unset, new_message_enabled: :unset, new_message_template: :unset, new_message_sound: :unset, new_message_badge_count_enabled: :unset, added_to_conversation_enabled: :unset, added_to_conversation_template: :unset, added_to_conversation_sound: :unset, removed_from_conversation_enabled: :unset, removed_from_conversation_template: :unset, removed_from_conversation_sound: :unset)
def update(log_enabled: :unset, new_message_enabled: :unset, new_message_template: :unset, new_message_sound: :unset, new_message_badge_count_enabled: :unset, added_to_conversation_enabled: :unset, added_to_conversation_template: :unset, added_to_conversation_sound: :unset, removed_from_conversation_enabled: :unset, removed_from_conversation_template: :unset, removed_from_conversation_sound: :unset, new_message_with_media_enabled: :unset, new_message_with_media_template: :unset)
context.update(
log_enabled: log_enabled,
new_message_enabled: new_message_enabled,
Expand All @@ -275,6 +289,8 @@ def update(log_enabled: :unset, new_message_enabled: :unset, new_message_templat
removed_from_conversation_enabled: removed_from_conversation_enabled,
removed_from_conversation_template: removed_from_conversation_template,
removed_from_conversation_sound: removed_from_conversation_sound,
new_message_with_media_enabled: new_message_with_media_enabled,
new_message_with_media_template: new_message_with_media_template,
)
end

Expand Down
7 changes: 7 additions & 0 deletions lib/twilio-ruby/rest/flex_api/v1/configuration.rb
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,7 @@ def initialize(version, payload)
'notifications' => payload['notifications'],
'markdown' => payload['markdown'],
'url' => payload['url'],
'flex_insights_hr' => payload['flex_insights_hr'],
}

# Context
Expand Down Expand Up @@ -419,6 +420,12 @@ def url
@properties['url']
end

##
# @return [Hash] Object that controls workspace reporting
def flex_insights_hr
@properties['flex_insights_hr']
end

##
# Fetch the ConfigurationInstance
# @param [String] ui_version The Pinned UI version of the Configuration resource
Expand Down
Loading

0 comments on commit 5d2e462

Please sign in to comment.