Class: Spaceship::ConnectAPI::CustomAppUser
- Inherits:
-
Object
- Object
- Spaceship::ConnectAPI::CustomAppUser
- Includes:
- Model
- Defined in:
- spaceship/lib/spaceship/connect_api/models/custom_app_user.rb
Instance Attribute Summary collapse
-
#apple_id ⇒ Object
Returns the value of attribute apple_id.
Attributes included from Model
Class Method Summary collapse
-
.all(app_id: nil, filter: {}, includes: nil, limit: nil, sort: nil) ⇒ Object
API.
- .create(app_id: nil, apple_id: nil) ⇒ Object
- .type ⇒ Object
Instance Method Summary collapse
Methods included from Model
#attr_mapping, included, #initialize, #reverse_attr_mapping, #to_json, #update_attributes
Instance Attribute Details
#apple_id ⇒ Object
Returns the value of attribute apple_id.
7 8 9 |
# File 'spaceship/lib/spaceship/connect_api/models/custom_app_user.rb', line 7 def apple_id @apple_id end |
Class Method Details
.all(app_id: nil, filter: {}, includes: nil, limit: nil, sort: nil) ⇒ Object
API
21 22 23 24 25 26 27 28 29 30 |
# File 'spaceship/lib/spaceship/connect_api/models/custom_app_user.rb', line 21 def self.all(app_id: nil, filter: {}, includes: nil, limit: nil, sort: nil) resps = Spaceship::ConnectAPI.get_custom_app_users( app_id: app_id, filter: filter, includes: includes, limit: nil, sort: nil ).all_pages return resps.flat_map(&:to_models) end |
.create(app_id: nil, apple_id: nil) ⇒ Object
32 33 34 |
# File 'spaceship/lib/spaceship/connect_api/models/custom_app_user.rb', line 32 def self.create(app_id: nil, apple_id: nil) return Spaceship::ConnectAPI.post_custom_app_user(app_id: app_id, apple_id: apple_id).first end |
.type ⇒ Object
13 14 15 |
# File 'spaceship/lib/spaceship/connect_api/models/custom_app_user.rb', line 13 def self.type return "customAppUsers" end |
Instance Method Details
#delete! ⇒ Object
36 37 38 |
# File 'spaceship/lib/spaceship/connect_api/models/custom_app_user.rb', line 36 def delete! Spaceship::ConnectAPI.delete_custom_app_user(custom_app_user_id: id) end |