class Nexmo::Conversations::Users
Public Instance Methods
create(params)
click to toggle source
Create a user.
@option params [String] :name
Unique name for a user.
@option params [String] :display_name
A string to be displayed as user name. It does not need to be unique.
@option params [String] :image_url
A link to an image for conversations' and users' avatars.
@param [Hash] params
@return [Response]
@see developer.nexmo.com/api/conversation#createUser
# File lib/nexmo/conversations/users.rb, line 28 def create(params) request('/beta/users', params: params, type: Post) end
delete(id)
click to toggle source
Delete a user.
@param [String] id
@return [Response]
@see developer.nexmo.com/api/conversation#deleteUser
# File lib/nexmo/conversations/users.rb, line 89 def delete(id) request('/beta/users/' + id, type: Delete) end
get(id)
click to toggle source
Retrieve a user.
@param [String] id
@return [Response]
@see developer.nexmo.com/api/conversation#getUser
# File lib/nexmo/conversations/users.rb, line 50 def get(id) request('/beta/users/' + id) end
list()
click to toggle source
List users.
@return [Response]
@see developer.nexmo.com/api/conversation#getUsers
# File lib/nexmo/conversations/users.rb, line 38 def list request('/beta/users') end
update(id, params)
click to toggle source
Update a user.
@option params [String] :name
Unique name for a user.
@option params [String] :display_name
A string to be displayed as user name. It does not need to be unique.
@option params [String] :image_url
A link to an image for conversations' and users' avatars.
@option params [Hash] :channels
A user who joins a conversation as a member can have one channel per membership type. Channels can be `app`, `phone`, `sip`, `websocket`, or `vbc`.
@param [String] id @param [Hash] params
@return [Response]
@see developer.nexmo.com/api/conversation#updateUser
# File lib/nexmo/conversations/users.rb, line 77 def update(id, params) request('/beta/users/' + id, params: params, type: Put) end