Class: GetStream::Generated::Models::CreateUserGroupRequest
- Defined in:
- lib/getstream_ruby/generated/models/create_user_group_request.rb
Overview
Request body for creating a user group
Instance Attribute Summary collapse
-
#description ⇒ String
An optional description for the group.
-
#id ⇒ String
Optional user group ID.
-
#member_ids ⇒ Array<String>
Optional initial list of user IDs to add as members.
-
#name ⇒ String
The user friendly name of the user group.
-
#team_id ⇒ String
Optional team ID to scope the group to a team.
Class Method Summary collapse
-
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization.
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ CreateUserGroupRequest
constructor
Initialize with attributes.
Methods inherited from BaseModel
#==, #inspect, omit_empty_fields, #to_h, #to_json
Constructor Details
#initialize(attributes = {}) ⇒ CreateUserGroupRequest
Initialize with attributes
29 30 31 32 33 34 35 36 |
# File 'lib/getstream_ruby/generated/models/create_user_group_request.rb', line 29 def initialize(attributes = {}) super(attributes) @name = attributes[:name] || attributes['name'] @description = attributes[:description] || attributes['description'] || nil @id = attributes[:id] || attributes['id'] || nil @team_id = attributes[:team_id] || attributes['team_id'] || nil @member_ids = attributes[:member_ids] || attributes['member_ids'] || nil end |
Instance Attribute Details
#description ⇒ String
Returns An optional description for the group.
17 18 19 |
# File 'lib/getstream_ruby/generated/models/create_user_group_request.rb', line 17 def description @description end |
#id ⇒ String
Returns Optional user group ID. If not provided, a UUID v7 will be generated.
20 21 22 |
# File 'lib/getstream_ruby/generated/models/create_user_group_request.rb', line 20 def id @id end |
#member_ids ⇒ Array<String>
Returns Optional initial list of user IDs to add as members.
26 27 28 |
# File 'lib/getstream_ruby/generated/models/create_user_group_request.rb', line 26 def member_ids @member_ids end |
#name ⇒ String
Returns The user friendly name of the user group.
14 15 16 |
# File 'lib/getstream_ruby/generated/models/create_user_group_request.rb', line 14 def name @name end |
#team_id ⇒ String
Returns Optional team ID to scope the group to a team.
23 24 25 |
# File 'lib/getstream_ruby/generated/models/create_user_group_request.rb', line 23 def team_id @team_id end |
Class Method Details
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization
39 40 41 42 43 44 45 46 47 |
# File 'lib/getstream_ruby/generated/models/create_user_group_request.rb', line 39 def self.json_field_mappings { name: 'name', description: 'description', id: 'id', team_id: 'team_id', member_ids: 'member_ids' } end |