lib/twilio-ruby/rest/chat/v2/service/user.rb in twilio-ruby-5.25.4 vs lib/twilio-ruby/rest/chat/v2/service/user.rb in twilio-ruby-5.26.0
- old
+ new
@@ -14,11 +14,11 @@
class UserList < ListResource
##
# Initialize the UserList
# @param [Version] version Version that contains the resource
# @param [String] service_sid The SID of the
- # [Service](https://www.twilio.com/docs/chat/rest/services) the resource is
+ # [Service](https://www.twilio.com/docs/chat/rest/services) the User resource is
# associated with.
# @return [UserList] UserList
def initialize(version, service_sid: nil)
super(version)
@@ -31,13 +31,13 @@
# Retrieve a single page of UserInstance records from the API.
# Request is executed immediately.
# @param [String] identity The `identity` value that uniquely identifies the new
# resource's [User](https://www.twilio.com/docs/chat/rest/users) within the
# [Service](https://www.twilio.com/docs/chat/rest/services). This value is often a
- # username or email address. See the Identity documentation for more details.
+ # username or email address. See the Identity documentation for more info.
# @param [String] role_sid The SID of the
- # [Role](https://www.twilio.com/docs/chat/rest/roles) assigned to the new User.
+ # [Role](https://www.twilio.com/docs/chat/rest/roles) to assign to the new User.
# @param [String] attributes A valid JSON string that contains
# application-specific data.
# @param [String] friendly_name A descriptive string that you create to describe
# the new resource. This value is often used for display purposes.
# @return [UserInstance] Newly created UserInstance
@@ -179,14 +179,14 @@
class UserContext < InstanceContext
##
# Initialize the UserContext
# @param [Version] version Version that contains the resource
# @param [String] service_sid The SID of the
- # [Service](https://www.twilio.com/docs/chat/rest/services) to fetch the resource
- # from.
- # @param [String] sid The Twilio-provided string that uniquely identifies the User
- # resource to fetch.
+ # [Service](https://www.twilio.com/docs/chat/rest/services) to fetch the User
+ # resource from.
+ # @param [String] sid The SID of the User resource to fetch. This value can be
+ # either the `sid` or the `identity` of the User resource to fetch.
# @return [UserContext] UserContext
def initialize(version, service_sid, sid)
super(version)
# Path Solution
@@ -213,19 +213,19 @@
UserInstance.new(@version, payload, service_sid: @solution[:service_sid], sid: @solution[:sid], )
end
##
# Deletes the UserInstance
- # @return [Boolean] true if delete succeeds, true otherwise
+ # @return [Boolean] true if delete succeeds, false otherwise
def delete
@version.delete('delete', @uri)
end
##
# Update the UserInstance
# @param [String] role_sid The SID of the
- # [Role](https://www.twilio.com/docs/chat/rest/roles) assigned to this user.
+ # [Role](https://www.twilio.com/docs/chat/rest/roles) to assign to the User.
# @param [String] attributes A valid JSON string that contains
# application-specific data.
# @param [String] friendly_name A descriptive string that you create to describe
# the resource. It is often used for display purposes.
# @return [UserInstance] Updated UserInstance
@@ -308,14 +308,14 @@
##
# Initialize the UserInstance
# @param [Version] version Version that contains the resource
# @param [Hash] payload payload that contains response from Twilio
# @param [String] service_sid The SID of the
- # [Service](https://www.twilio.com/docs/chat/rest/services) the resource is
+ # [Service](https://www.twilio.com/docs/chat/rest/services) the User resource is
# associated with.
- # @param [String] sid The Twilio-provided string that uniquely identifies the User
- # resource to fetch.
+ # @param [String] sid The SID of the User resource to fetch. This value can be
+ # either the `sid` or the `identity` of the User resource to fetch.
# @return [UserInstance] UserInstance
def initialize(version, payload, service_sid: nil, sid: nil)
super(version)
# Marshaled Properties
@@ -405,23 +405,23 @@
def is_notifiable
@properties['is_notifiable']
end
##
- # @return [Time] The RFC 2822 date and time in GMT when the resource was created
+ # @return [Time] The ISO 8601 date and time in GMT when the resource was created
def date_created
@properties['date_created']
end
##
- # @return [Time] The RFC 2822 date and time in GMT when the resource was last updated
+ # @return [Time] The ISO 8601 date and time in GMT when the resource was last updated
def date_updated
@properties['date_updated']
end
##
- # @return [String] The number of Channels this User is a Member of
+ # @return [String] The number of Channels the User is a Member of
def joined_channels_count
@properties['joined_channels_count']
end
##
@@ -443,18 +443,18 @@
context.fetch
end
##
# Deletes the UserInstance
- # @return [Boolean] true if delete succeeds, true otherwise
+ # @return [Boolean] true if delete succeeds, false otherwise
def delete
context.delete
end
##
# Update the UserInstance
# @param [String] role_sid The SID of the
- # [Role](https://www.twilio.com/docs/chat/rest/roles) assigned to this user.
+ # [Role](https://www.twilio.com/docs/chat/rest/roles) to assign to the User.
# @param [String] attributes A valid JSON string that contains
# application-specific data.
# @param [String] friendly_name A descriptive string that you create to describe
# the resource. It is often used for display purposes.
# @return [UserInstance] Updated UserInstance
\ No newline at end of file