alula-ruby 0.50.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.circleci/config.yml +14 -0
- data/.env.example +8 -0
- data/.github/workflows/gem-push.yml +45 -0
- data/.gitignore +23 -0
- data/.rspec +3 -0
- data/.travis.yml +7 -0
- data/Dockerfile +6 -0
- data/Gemfile +12 -0
- data/Guardfile +42 -0
- data/README.md +423 -0
- data/Rakefile +6 -0
- data/VERSION.md +84 -0
- data/alula-docker-compose.yml +80 -0
- data/alula.gemspec +38 -0
- data/bin/console +15 -0
- data/bin/docparse +36 -0
- data/bin/genresource +79 -0
- data/bin/setup +8 -0
- data/bin/testauth +24 -0
- data/bin/testprep +9 -0
- data/data/docs/Alula_API_Documentation_2021-04-06.html +16240 -0
- data/docker-compose.yml +11 -0
- data/lib/alula/alula_response.rb +20 -0
- data/lib/alula/api_operations/delete.rb +52 -0
- data/lib/alula/api_operations/list.rb +45 -0
- data/lib/alula/api_operations/request.rb +44 -0
- data/lib/alula/api_operations/save.rb +81 -0
- data/lib/alula/api_resource.rb +196 -0
- data/lib/alula/client.rb +142 -0
- data/lib/alula/errors.rb +169 -0
- data/lib/alula/filter_builder.rb +271 -0
- data/lib/alula/helpers/device_attribute_translations.rb +68 -0
- data/lib/alula/list_object.rb +64 -0
- data/lib/alula/meta.rb +16 -0
- data/lib/alula/monkey_patches.rb +24 -0
- data/lib/alula/oauth.rb +118 -0
- data/lib/alula/pagination.rb +25 -0
- data/lib/alula/procedures/dealer_device_stats_proc.rb +16 -0
- data/lib/alula/procedures/dealer_restore_proc.rb +25 -0
- data/lib/alula/procedures/dealer_suspend_proc.rb +25 -0
- data/lib/alula/procedures/device_assign_proc.rb +23 -0
- data/lib/alula/procedures/device_cellular_history_proc.rb +33 -0
- data/lib/alula/procedures/device_rateplan_get_proc.rb +21 -0
- data/lib/alula/procedures/device_register_proc.rb +31 -0
- data/lib/alula/procedures/device_signal_add_proc.rb +42 -0
- data/lib/alula/procedures/device_signal_delivered_proc.rb +31 -0
- data/lib/alula/procedures/device_signal_update_proc.rb +32 -0
- data/lib/alula/procedures/device_unassign_proc.rb +16 -0
- data/lib/alula/procedures/device_unregister_proc.rb +21 -0
- data/lib/alula/procedures/upload_touchpad_branding_proc.rb +24 -0
- data/lib/alula/procedures/user_plansvideo_price_get.rb +21 -0
- data/lib/alula/procedures/user_transfer_accept.rb +19 -0
- data/lib/alula/procedures/user_transfer_authorize.rb +18 -0
- data/lib/alula/procedures/user_transfer_cancel.rb +18 -0
- data/lib/alula/procedures/user_transfer_deny.rb +19 -0
- data/lib/alula/procedures/user_transfer_reject.rb +19 -0
- data/lib/alula/procedures/user_transfer_request.rb +19 -0
- data/lib/alula/query_interface.rb +142 -0
- data/lib/alula/rate_limit.rb +11 -0
- data/lib/alula/relationship_attributes.rb +107 -0
- data/lib/alula/resource_attributes.rb +206 -0
- data/lib/alula/resources/admin_user.rb +207 -0
- data/lib/alula/resources/billing_program.rb +41 -0
- data/lib/alula/resources/dealer.rb +218 -0
- data/lib/alula/resources/dealer_account_transfer.rb +172 -0
- data/lib/alula/resources/dealer_address.rb +89 -0
- data/lib/alula/resources/dealer_branding.rb +226 -0
- data/lib/alula/resources/dealer_program.rb +75 -0
- data/lib/alula/resources/dealer_suspension_log.rb +49 -0
- data/lib/alula/resources/device.rb +716 -0
- data/lib/alula/resources/device_cellular_status.rb +134 -0
- data/lib/alula/resources/device_charge.rb +70 -0
- data/lib/alula/resources/device_event_log.rb +167 -0
- data/lib/alula/resources/device_program.rb +54 -0
- data/lib/alula/resources/event_trigger.rb +75 -0
- data/lib/alula/resources/event_webhook.rb +47 -0
- data/lib/alula/resources/feature_bysubject.rb +74 -0
- data/lib/alula/resources/feature_plan.rb +57 -0
- data/lib/alula/resources/feature_planvideo.rb +54 -0
- data/lib/alula/resources/feature_price.rb +46 -0
- data/lib/alula/resources/receiver_connection.rb +95 -0
- data/lib/alula/resources/receiver_group.rb +74 -0
- data/lib/alula/resources/revision.rb +91 -0
- data/lib/alula/resources/self.rb +61 -0
- data/lib/alula/resources/station.rb +130 -0
- data/lib/alula/resources/token_exchange.rb +34 -0
- data/lib/alula/resources/user.rb +229 -0
- data/lib/alula/resources/user_address.rb +121 -0
- data/lib/alula/resources/user_phone.rb +116 -0
- data/lib/alula/resources/user_preferences.rb +57 -0
- data/lib/alula/resources/user_pushtoken.rb +75 -0
- data/lib/alula/resources/user_videoprofile.rb +38 -0
- data/lib/alula/rest_resource.rb +17 -0
- data/lib/alula/rpc_resource.rb +40 -0
- data/lib/alula/rpc_response.rb +14 -0
- data/lib/alula/singleton_rest_resource.rb +26 -0
- data/lib/alula/util.rb +107 -0
- data/lib/alula/version.rb +5 -0
- data/lib/alula.rb +135 -0
- data/lib/parser.rb +199 -0
- metadata +282 -0
@@ -0,0 +1,134 @@
|
|
1
|
+
module Alula
|
2
|
+
class DeviceCellularStatus < Alula::RestResource
|
3
|
+
extend Alula::ResourceAttributes
|
4
|
+
extend Alula::RelationshipAttributes
|
5
|
+
extend Alula::ApiOperations::Request
|
6
|
+
extend Alula::ApiOperations::List
|
7
|
+
|
8
|
+
resource_path 'devices/cellular/status'
|
9
|
+
type 'devices-cellular-status'
|
10
|
+
|
11
|
+
# Relationships
|
12
|
+
# None
|
13
|
+
|
14
|
+
# Resource Fields
|
15
|
+
field :id,
|
16
|
+
type: :string,
|
17
|
+
sortable: false,
|
18
|
+
filterable: false,
|
19
|
+
creatable_by: [],
|
20
|
+
patchable_by: []
|
21
|
+
|
22
|
+
field :meid,
|
23
|
+
type: :string,
|
24
|
+
sortable: false,
|
25
|
+
filterable: false,
|
26
|
+
creatable_by: [],
|
27
|
+
patchable_by: []
|
28
|
+
|
29
|
+
field :imei,
|
30
|
+
type: :string,
|
31
|
+
sortable: false,
|
32
|
+
filterable: false,
|
33
|
+
creatable_by: [],
|
34
|
+
patchable_by: []
|
35
|
+
|
36
|
+
field :esn,
|
37
|
+
type: :string,
|
38
|
+
sortable: false,
|
39
|
+
filterable: false,
|
40
|
+
creatable_by: [],
|
41
|
+
patchable_by: []
|
42
|
+
|
43
|
+
field :mdn,
|
44
|
+
type: :string,
|
45
|
+
sortable: false,
|
46
|
+
filterable: false,
|
47
|
+
creatable_by: [],
|
48
|
+
patchable_by: []
|
49
|
+
|
50
|
+
field :iccid,
|
51
|
+
type: :string,
|
52
|
+
sortable: false,
|
53
|
+
filterable: false,
|
54
|
+
creatable_by: [],
|
55
|
+
patchable_by: []
|
56
|
+
|
57
|
+
field :imsi,
|
58
|
+
type: :string,
|
59
|
+
sortable: false,
|
60
|
+
filterable: false,
|
61
|
+
creatable_by: [],
|
62
|
+
patchable_by: []
|
63
|
+
|
64
|
+
field :account_name,
|
65
|
+
type: :string,
|
66
|
+
sortable: false,
|
67
|
+
filterable: false,
|
68
|
+
creatable_by: [],
|
69
|
+
patchable_by: []
|
70
|
+
|
71
|
+
field :carrier_name,
|
72
|
+
type: :string,
|
73
|
+
sortable: false,
|
74
|
+
filterable: false,
|
75
|
+
creatable_by: [],
|
76
|
+
patchable_by: []
|
77
|
+
|
78
|
+
field :device_group,
|
79
|
+
type: :string,
|
80
|
+
sortable: false,
|
81
|
+
filterable: false,
|
82
|
+
creatable_by: [],
|
83
|
+
patchable_by: []
|
84
|
+
|
85
|
+
field :rate_plan,
|
86
|
+
type: :string,
|
87
|
+
sortable: false,
|
88
|
+
filterable: false,
|
89
|
+
creatable_by: [],
|
90
|
+
patchable_by: []
|
91
|
+
|
92
|
+
field :state,
|
93
|
+
type: :string,
|
94
|
+
sortable: false,
|
95
|
+
filterable: false,
|
96
|
+
creatable_by: [],
|
97
|
+
patchable_by: []
|
98
|
+
|
99
|
+
field :ip_address,
|
100
|
+
type: :string,
|
101
|
+
sortable: false,
|
102
|
+
filterable: false,
|
103
|
+
creatable_by: [],
|
104
|
+
patchable_by: []
|
105
|
+
|
106
|
+
field :created_at,
|
107
|
+
type: :string,
|
108
|
+
sortable: false,
|
109
|
+
filterable: false,
|
110
|
+
creatable_by: [],
|
111
|
+
patchable_by: []
|
112
|
+
|
113
|
+
field :updated_at,
|
114
|
+
type: :date,
|
115
|
+
sortable: false,
|
116
|
+
filterable: false,
|
117
|
+
creatable_by: [],
|
118
|
+
patchable_by: []
|
119
|
+
|
120
|
+
field :connected,
|
121
|
+
type: :string,
|
122
|
+
sortable: false,
|
123
|
+
filterable: false,
|
124
|
+
creatable_by: [],
|
125
|
+
patchable_by: []
|
126
|
+
|
127
|
+
field :signal_strength,
|
128
|
+
type: :string,
|
129
|
+
sortable: false,
|
130
|
+
filterable: false,
|
131
|
+
creatable_by: [],
|
132
|
+
patchable_by: []
|
133
|
+
end
|
134
|
+
end
|
@@ -0,0 +1,70 @@
|
|
1
|
+
module Alula
|
2
|
+
class DeviceCharge < Alula::RestResource
|
3
|
+
extend Alula::ResourceAttributes
|
4
|
+
extend Alula::ApiOperations::Request
|
5
|
+
extend Alula::ApiOperations::List
|
6
|
+
extend Alula::ApiOperations::Save
|
7
|
+
|
8
|
+
resource_path 'devices/charges'
|
9
|
+
type 'devices-charge'
|
10
|
+
|
11
|
+
# Resource Fields
|
12
|
+
# Not all params are used at the moment. See Alula::ResourceAttributes for details
|
13
|
+
# on how params are parsed,
|
14
|
+
field :id,
|
15
|
+
type: :string,
|
16
|
+
sortable: false,
|
17
|
+
filterable: false,
|
18
|
+
creatable_by: [],
|
19
|
+
patchable_by: []
|
20
|
+
|
21
|
+
field :device_id,
|
22
|
+
type: :string,
|
23
|
+
sortable: false,
|
24
|
+
filterable: true,
|
25
|
+
creatable_by: [:system],
|
26
|
+
patchable_by: []
|
27
|
+
|
28
|
+
field :name,
|
29
|
+
type: :string,
|
30
|
+
sortable: true,
|
31
|
+
filterable: true,
|
32
|
+
creatable_by: [:system],
|
33
|
+
patchable_by: []
|
34
|
+
|
35
|
+
field :description,
|
36
|
+
type: :string,
|
37
|
+
sortable: false,
|
38
|
+
filterable: false,
|
39
|
+
creatable_by: [:system],
|
40
|
+
patchable_by: []
|
41
|
+
|
42
|
+
field :price,
|
43
|
+
type: :string,
|
44
|
+
sortable: true,
|
45
|
+
filterable: false,
|
46
|
+
creatable_by: [:system],
|
47
|
+
patchable_by: [:system]
|
48
|
+
|
49
|
+
field :date_modified,
|
50
|
+
type: :date,
|
51
|
+
sortable: true,
|
52
|
+
filterable: true,
|
53
|
+
creatable_by: [],
|
54
|
+
patchable_by: []
|
55
|
+
|
56
|
+
field :date_created,
|
57
|
+
type: :date,
|
58
|
+
sortable: true,
|
59
|
+
filterable: true,
|
60
|
+
creatable_by: [:system],
|
61
|
+
patchable_by: []
|
62
|
+
|
63
|
+
field :date_charged,
|
64
|
+
type: :date,
|
65
|
+
sortable: true,
|
66
|
+
filterable: true,
|
67
|
+
creatable_by: [:system],
|
68
|
+
patchable_by: []
|
69
|
+
end
|
70
|
+
end
|
@@ -0,0 +1,167 @@
|
|
1
|
+
module Alula
|
2
|
+
class DeviceEventLog < Alula::RestResource
|
3
|
+
extend Alula::ResourceAttributes
|
4
|
+
extend Alula::RelationshipAttributes
|
5
|
+
extend Alula::ApiOperations::Request
|
6
|
+
extend Alula::ApiOperations::List
|
7
|
+
|
8
|
+
resource_path 'devices/eventlog'
|
9
|
+
type 'devices-eventlog'
|
10
|
+
|
11
|
+
# Relationships
|
12
|
+
relationship :device, type: 'devices', cardinality: 'To-one'
|
13
|
+
relationship :customer, type: 'users', cardinality: 'To-one'
|
14
|
+
relationship :dealer, type: 'dealers', cardinality: 'To-one'
|
15
|
+
|
16
|
+
# Resource Fields
|
17
|
+
# Not all params are used at the moment. See Alula::ResourceAttributes for details
|
18
|
+
# on how params are parsed,
|
19
|
+
field :id,
|
20
|
+
type: :string,
|
21
|
+
sortable: false,
|
22
|
+
filterable: false,
|
23
|
+
creatable_by: [],
|
24
|
+
patchable_by: []
|
25
|
+
|
26
|
+
field :device_id,
|
27
|
+
type: :string,
|
28
|
+
sortable: false,
|
29
|
+
filterable: true,
|
30
|
+
creatable_by: [],
|
31
|
+
patchable_by: []
|
32
|
+
|
33
|
+
field :dealer_id,
|
34
|
+
type: :string,
|
35
|
+
sortable: false,
|
36
|
+
filterable: true,
|
37
|
+
creatable_by: [],
|
38
|
+
patchable_by: []
|
39
|
+
|
40
|
+
field :customer_id,
|
41
|
+
type: :string,
|
42
|
+
sortable: false,
|
43
|
+
filterable: true,
|
44
|
+
creatable_by: [],
|
45
|
+
patchable_by: []
|
46
|
+
|
47
|
+
field :group_id,
|
48
|
+
type: :string,
|
49
|
+
sortable: false,
|
50
|
+
filterable: false,
|
51
|
+
creatable_by: [],
|
52
|
+
patchable_by: []
|
53
|
+
|
54
|
+
field :date_entered,
|
55
|
+
type: :date,
|
56
|
+
sortable: true,
|
57
|
+
filterable: true,
|
58
|
+
creatable_by: [],
|
59
|
+
patchable_by: []
|
60
|
+
|
61
|
+
field :relay,
|
62
|
+
type: :string,
|
63
|
+
sortable: false,
|
64
|
+
filterable: true,
|
65
|
+
creatable_by: [],
|
66
|
+
patchable_by: []
|
67
|
+
|
68
|
+
field :action,
|
69
|
+
type: :string,
|
70
|
+
sortable: false,
|
71
|
+
filterable: true,
|
72
|
+
creatable_by: [],
|
73
|
+
patchable_by: []
|
74
|
+
|
75
|
+
field :npv,
|
76
|
+
type: :string,
|
77
|
+
sortable: false,
|
78
|
+
filterable: true,
|
79
|
+
creatable_by: [],
|
80
|
+
patchable_by: []
|
81
|
+
|
82
|
+
field :relay_status,
|
83
|
+
type: :string,
|
84
|
+
sortable: false,
|
85
|
+
filterable: true,
|
86
|
+
creatable_by: [],
|
87
|
+
patchable_by: []
|
88
|
+
|
89
|
+
field :signal_account_number,
|
90
|
+
type: :string,
|
91
|
+
sortable: false,
|
92
|
+
filterable: false,
|
93
|
+
creatable_by: [],
|
94
|
+
patchable_by: []
|
95
|
+
|
96
|
+
field :signal_event_qualifier,
|
97
|
+
type: :string,
|
98
|
+
sortable: false,
|
99
|
+
filterable: false,
|
100
|
+
creatable_by: [],
|
101
|
+
patchable_by: []
|
102
|
+
|
103
|
+
field :signal_event_code,
|
104
|
+
type: :string,
|
105
|
+
sortable: false,
|
106
|
+
filterable: true,
|
107
|
+
creatable_by: [],
|
108
|
+
patchable_by: []
|
109
|
+
|
110
|
+
field :signal_event_description,
|
111
|
+
type: :string,
|
112
|
+
sortable: false,
|
113
|
+
filterable: false,
|
114
|
+
creatable_by: [],
|
115
|
+
patchable_by: []
|
116
|
+
|
117
|
+
field :signal_partition,
|
118
|
+
type: :string,
|
119
|
+
sortable: false,
|
120
|
+
filterable: true,
|
121
|
+
creatable_by: [],
|
122
|
+
patchable_by: []
|
123
|
+
|
124
|
+
field :signal_user_zone,
|
125
|
+
type: :string,
|
126
|
+
sortable: false,
|
127
|
+
filterable: true,
|
128
|
+
creatable_by: [],
|
129
|
+
patchable_by: []
|
130
|
+
|
131
|
+
field :signal_user_zone_type,
|
132
|
+
type: :string,
|
133
|
+
sortable: false,
|
134
|
+
filterable: false,
|
135
|
+
creatable_by: [],
|
136
|
+
patchable_by: []
|
137
|
+
|
138
|
+
field :signal_user_zone_alias,
|
139
|
+
type: :string,
|
140
|
+
sortable: false,
|
141
|
+
filterable: false,
|
142
|
+
creatable_by: [],
|
143
|
+
patchable_by: []
|
144
|
+
|
145
|
+
field :signal_protocol,
|
146
|
+
type: :string,
|
147
|
+
sortable: false,
|
148
|
+
filterable: true,
|
149
|
+
creatable_by: [],
|
150
|
+
patchable_by: []
|
151
|
+
|
152
|
+
def relay_status_name
|
153
|
+
relay_status_names = {
|
154
|
+
0 => 'eventLog.relayStatus.notRelayed',
|
155
|
+
1 => 'eventLog.relayStatus.attemptingToRelay',
|
156
|
+
2 => 'eventLog.relayStatus.suppressed',
|
157
|
+
3 => 'eventLog.relayStatus.timedOutCannotRelay',
|
158
|
+
4 => 'eventLog.relayStatus.noReceiversConfigured',
|
159
|
+
8 => 'eventLog.relayStatus.noStartTone',
|
160
|
+
9 => 'eventLog.relayStatus.negativeAcknowledgement',
|
161
|
+
10 => 'eventLog.relayStatus.relayCompleted'
|
162
|
+
}
|
163
|
+
|
164
|
+
relay_status_names[relay_status]
|
165
|
+
end
|
166
|
+
end
|
167
|
+
end
|
@@ -0,0 +1,54 @@
|
|
1
|
+
module Alula
|
2
|
+
class DeviceProgram < Alula::RestResource
|
3
|
+
extend Alula::ResourceAttributes
|
4
|
+
extend Alula::RelationshipAttributes
|
5
|
+
extend Alula::ApiOperations::Request
|
6
|
+
extend Alula::ApiOperations::List
|
7
|
+
extend Alula::ApiOperations::Save
|
8
|
+
|
9
|
+
resource_path 'devices/programs'
|
10
|
+
type 'devices-program'
|
11
|
+
|
12
|
+
# Relationships
|
13
|
+
relationship :device, type: 'devices', cardinality: 'To-one'
|
14
|
+
relationship :dealer_billing_program, type: 'dealers-programs', cardinality: 'To-one'
|
15
|
+
|
16
|
+
# Resource Fields
|
17
|
+
# Not all params are used at the moment. See Alula::ResourceAttributes for details
|
18
|
+
# on how params are parsed,
|
19
|
+
field :id,
|
20
|
+
type: :string,
|
21
|
+
sortable: false,
|
22
|
+
filterable: false,
|
23
|
+
creatable_by: [],
|
24
|
+
patchable_by: []
|
25
|
+
|
26
|
+
field :device_id,
|
27
|
+
type: :string,
|
28
|
+
sortable: false,
|
29
|
+
filterable: true,
|
30
|
+
creatable_by: [:system],
|
31
|
+
patchable_by: []
|
32
|
+
|
33
|
+
field :dealer_program_id,
|
34
|
+
type: :string,
|
35
|
+
sortable: false,
|
36
|
+
filterable: true,
|
37
|
+
creatable_by: [:system],
|
38
|
+
patchable_by: []
|
39
|
+
|
40
|
+
field :date_modified,
|
41
|
+
type: :date,
|
42
|
+
sortable: true,
|
43
|
+
filterable: true,
|
44
|
+
creatable_by: [],
|
45
|
+
patchable_by: []
|
46
|
+
|
47
|
+
field :date_created,
|
48
|
+
type: :date,
|
49
|
+
sortable: true,
|
50
|
+
filterable: true,
|
51
|
+
creatable_by: [:system],
|
52
|
+
patchable_by: []
|
53
|
+
end
|
54
|
+
end
|
@@ -0,0 +1,75 @@
|
|
1
|
+
module Alula
|
2
|
+
class EventTrigger < Alula::RestResource
|
3
|
+
extend Alula::ResourceAttributes
|
4
|
+
extend Alula::ApiOperations::Request
|
5
|
+
extend Alula::ApiOperations::List
|
6
|
+
extend Alula::ApiOperations::Save
|
7
|
+
|
8
|
+
# You should update this to be a slash-separated, literal path to the resource
|
9
|
+
# without the prefix /api/v1 or the suffix of an ID
|
10
|
+
resource_path 'events/triggers'
|
11
|
+
|
12
|
+
# Relationships
|
13
|
+
# None
|
14
|
+
|
15
|
+
# Resource Fields
|
16
|
+
# Not all params are used at the moment. See Alula::ResourceAttributes for details
|
17
|
+
# on how params are parsed,
|
18
|
+
field :id,
|
19
|
+
type: :string,
|
20
|
+
sortable: false,
|
21
|
+
filterable: false,
|
22
|
+
creatable_by: [:all],
|
23
|
+
patchable_by: [:all]
|
24
|
+
|
25
|
+
field :user_id,
|
26
|
+
type: :string,
|
27
|
+
sortable: false,
|
28
|
+
filterable: true,
|
29
|
+
creatable_by: [],
|
30
|
+
patchable_by: []
|
31
|
+
|
32
|
+
field :reference,
|
33
|
+
type: :string,
|
34
|
+
sortable: false,
|
35
|
+
filterable: true,
|
36
|
+
creatable_by: [:all],
|
37
|
+
patchable_by: [:all]
|
38
|
+
|
39
|
+
field :event,
|
40
|
+
type: :string,
|
41
|
+
sortable: false,
|
42
|
+
filterable: false,
|
43
|
+
creatable_by: [:all],
|
44
|
+
patchable_by: []
|
45
|
+
|
46
|
+
field :conditions,
|
47
|
+
type: :string,
|
48
|
+
sortable: false,
|
49
|
+
filterable: false,
|
50
|
+
creatable_by: [:all],
|
51
|
+
patchable_by: [:all]
|
52
|
+
|
53
|
+
field :action,
|
54
|
+
type: :string,
|
55
|
+
sortable: false,
|
56
|
+
filterable: false,
|
57
|
+
creatable_by: [:all],
|
58
|
+
patchable_by: [:all]
|
59
|
+
|
60
|
+
field :ttl,
|
61
|
+
type: :string,
|
62
|
+
sortable: false,
|
63
|
+
filterable: false,
|
64
|
+
creatable_by: [:all],
|
65
|
+
patchable_by: [:all]
|
66
|
+
|
67
|
+
field :expires,
|
68
|
+
type: :string,
|
69
|
+
sortable: true,
|
70
|
+
filterable: false,
|
71
|
+
creatable_by: [],
|
72
|
+
patchable_by: []
|
73
|
+
|
74
|
+
end
|
75
|
+
end
|
@@ -0,0 +1,47 @@
|
|
1
|
+
module Alula
|
2
|
+
class EventWebhook < Alula::RestResource
|
3
|
+
extend Alula::ResourceAttributes
|
4
|
+
extend Alula::ApiOperations::Request
|
5
|
+
extend Alula::ApiOperations::List
|
6
|
+
extend Alula::ApiOperations::Save
|
7
|
+
|
8
|
+
# You should update this to be a slash-separated, literal path to the resource
|
9
|
+
# without the prefix /api/v1 or the suffix of an ID
|
10
|
+
resource_path 'events/webhooks'
|
11
|
+
|
12
|
+
# Relationships
|
13
|
+
# None
|
14
|
+
|
15
|
+
# Resource Fields
|
16
|
+
# Not all params are used at the moment. See Alula::ResourceAttributes for details
|
17
|
+
# on how params are parsed,
|
18
|
+
field :id,
|
19
|
+
type: :string,
|
20
|
+
sortable: false,
|
21
|
+
filterable: false,
|
22
|
+
creatable_by: [:system, :dealer],
|
23
|
+
patchable_by: [:system, :dealer]
|
24
|
+
|
25
|
+
field :reference,
|
26
|
+
type: :string,
|
27
|
+
sortable: false,
|
28
|
+
filterable: true,
|
29
|
+
creatable_by: [:system, :dealer],
|
30
|
+
patchable_by: [:system, :dealer]
|
31
|
+
|
32
|
+
field :url,
|
33
|
+
type: :string,
|
34
|
+
sortable: false,
|
35
|
+
filterable: false,
|
36
|
+
creatable_by: [:system, :dealer],
|
37
|
+
patchable_by: [:system, :dealer]
|
38
|
+
|
39
|
+
field :secret,
|
40
|
+
type: :string,
|
41
|
+
sortable: false,
|
42
|
+
filterable: false,
|
43
|
+
creatable_by: [:system, :dealer],
|
44
|
+
patchable_by: [:system, :dealer]
|
45
|
+
|
46
|
+
end
|
47
|
+
end
|
@@ -0,0 +1,74 @@
|
|
1
|
+
module Alula
|
2
|
+
class FeatureBySubject < Alula::RestResource
|
3
|
+
extend Alula::ResourceAttributes
|
4
|
+
extend Alula::ApiOperations::Request
|
5
|
+
extend Alula::ApiOperations::List
|
6
|
+
extend Alula::ApiOperations::Save
|
7
|
+
|
8
|
+
resource_path 'features/bysubject'
|
9
|
+
type 'feature-bysubject'
|
10
|
+
|
11
|
+
field :id,
|
12
|
+
type: :string,
|
13
|
+
sortable: false,
|
14
|
+
filterable: false,
|
15
|
+
creatable_by: [:system],
|
16
|
+
patchable_by: []
|
17
|
+
|
18
|
+
field :gp_id,
|
19
|
+
type: :string,
|
20
|
+
sortable: false,
|
21
|
+
filterable: true,
|
22
|
+
creatable_by: [:system],
|
23
|
+
patchable_by: []
|
24
|
+
|
25
|
+
field :subject_id,
|
26
|
+
type: :string,
|
27
|
+
sortable: false,
|
28
|
+
filterable: true,
|
29
|
+
creatable_by: [:system],
|
30
|
+
patchable_by: []
|
31
|
+
|
32
|
+
field :subject_type,
|
33
|
+
type: :string,
|
34
|
+
sortable: true,
|
35
|
+
filterable: false,
|
36
|
+
creatable_by: [:system],
|
37
|
+
patchable_by: []
|
38
|
+
|
39
|
+
field :date_start,
|
40
|
+
type: :date,
|
41
|
+
sortable: true,
|
42
|
+
filterable: false,
|
43
|
+
creatable_by: [:system],
|
44
|
+
patchable_by: [:system]
|
45
|
+
|
46
|
+
field :date_end,
|
47
|
+
type: :date,
|
48
|
+
sortable: true,
|
49
|
+
filterable: false,
|
50
|
+
creatable_by: [:system],
|
51
|
+
patchable_by: [:system]
|
52
|
+
|
53
|
+
field :date_assigned,
|
54
|
+
type: :date,
|
55
|
+
sortable: true,
|
56
|
+
filterable: false,
|
57
|
+
creatable_by: [:system],
|
58
|
+
patchable_by: []
|
59
|
+
|
60
|
+
field :assigned_by,
|
61
|
+
type: :string,
|
62
|
+
sortable: false,
|
63
|
+
filterable: false,
|
64
|
+
creatable_by: [:system],
|
65
|
+
patchable_by: []
|
66
|
+
|
67
|
+
field :assignment_type,
|
68
|
+
type: :string,
|
69
|
+
sortable: true,
|
70
|
+
filterable: true,
|
71
|
+
creatable_by: [:system],
|
72
|
+
patchable_by: []
|
73
|
+
end
|
74
|
+
end
|
@@ -0,0 +1,57 @@
|
|
1
|
+
module Alula
|
2
|
+
class FeaturePlan < Alula::RestResource
|
3
|
+
extend Alula::ResourceAttributes
|
4
|
+
extend Alula::ApiOperations::Request
|
5
|
+
extend Alula::ApiOperations::List
|
6
|
+
extend Alula::ApiOperations::Save
|
7
|
+
extend Alula::ApiOperations::Delete
|
8
|
+
|
9
|
+
resource_path 'features/plans'
|
10
|
+
type 'feature-plan'
|
11
|
+
|
12
|
+
# Resource Fields
|
13
|
+
# Not all params are used at the moment. See Alula::ResourceAttributes for details
|
14
|
+
# on how params are parsed,
|
15
|
+
field :id,
|
16
|
+
type: :string,
|
17
|
+
sortable: false,
|
18
|
+
filterable: false,
|
19
|
+
creatable_by: [:system],
|
20
|
+
patchable_by: []
|
21
|
+
|
22
|
+
field :gp_id,
|
23
|
+
type: :string,
|
24
|
+
sortable: true,
|
25
|
+
filterable: true,
|
26
|
+
creatable_by: [:system],
|
27
|
+
patchable_by: []
|
28
|
+
|
29
|
+
field :name,
|
30
|
+
type: :string,
|
31
|
+
sortable: true,
|
32
|
+
filterable: false,
|
33
|
+
creatable_by: [:system],
|
34
|
+
patchable_by: [:system]
|
35
|
+
|
36
|
+
field :description,
|
37
|
+
type: :object,
|
38
|
+
sortable: false,
|
39
|
+
filterable: false,
|
40
|
+
creatable_by: [:system],
|
41
|
+
patchable_by: [:system]
|
42
|
+
|
43
|
+
field :date_created,
|
44
|
+
type: :date,
|
45
|
+
sortable: true,
|
46
|
+
filterable: true,
|
47
|
+
creatable_by: [:system],
|
48
|
+
patchable_by: []
|
49
|
+
|
50
|
+
field :date_modified,
|
51
|
+
type: :date,
|
52
|
+
sortable: true,
|
53
|
+
filterable: true,
|
54
|
+
creatable_by: [:system],
|
55
|
+
patchable_by: [:system]
|
56
|
+
end
|
57
|
+
end
|