kaltura-client 1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. checksums.yaml +7 -0
  2. data/README +21 -0
  3. data/Rakefile +19 -0
  4. data/agpl.txt +674 -0
  5. data/kaltura.yml +7 -0
  6. data/lib/kaltura.rb +31 -0
  7. data/lib/kaltura_client.rb +15649 -0
  8. data/lib/kaltura_client_base.rb +432 -0
  9. data/lib/kaltura_plugins/kaltura_abc_screeners_watermark_access_control_client_plugin.rb +37 -0
  10. data/lib/kaltura_plugins/kaltura_ad_cue_point_client_plugin.rb +110 -0
  11. data/lib/kaltura_plugins/kaltura_annotation_client_plugin.rb +239 -0
  12. data/lib/kaltura_plugins/kaltura_aspera_client_plugin.rb +61 -0
  13. data/lib/kaltura_plugins/kaltura_attachment_client_plugin.rb +227 -0
  14. data/lib/kaltura_plugins/kaltura_audit_client_plugin.rb +349 -0
  15. data/lib/kaltura_plugins/kaltura_bulk_upload_client_plugin.rb +116 -0
  16. data/lib/kaltura_plugins/kaltura_bulk_upload_csv_client_plugin.rb +55 -0
  17. data/lib/kaltura_plugins/kaltura_bulk_upload_filter_client_plugin.rb +58 -0
  18. data/lib/kaltura_plugins/kaltura_bulk_upload_xml_client_plugin.rb +40 -0
  19. data/lib/kaltura_plugins/kaltura_caption_client_plugin.rb +406 -0
  20. data/lib/kaltura_plugins/kaltura_caption_search_client_plugin.rb +138 -0
  21. data/lib/kaltura_plugins/kaltura_code_cue_point_client_plugin.rb +99 -0
  22. data/lib/kaltura_plugins/kaltura_content_distribution_client_plugin.rb +1725 -0
  23. data/lib/kaltura_plugins/kaltura_cue_point_client_plugin.rb +312 -0
  24. data/lib/kaltura_plugins/kaltura_document_client_plugin.rb +522 -0
  25. data/lib/kaltura_plugins/kaltura_drm_client_plugin.rb +401 -0
  26. data/lib/kaltura_plugins/kaltura_drop_folder_client_plugin.rb +827 -0
  27. data/lib/kaltura_plugins/kaltura_drop_folder_xml_bulk_upload_client_plugin.rb +39 -0
  28. data/lib/kaltura_plugins/kaltura_email_notification_client_plugin.rb +273 -0
  29. data/lib/kaltura_plugins/kaltura_event_cue_point_client_plugin.rb +67 -0
  30. data/lib/kaltura_plugins/kaltura_event_notification_client_plugin.rb +415 -0
  31. data/lib/kaltura_plugins/kaltura_external_media_client_plugin.rb +203 -0
  32. data/lib/kaltura_plugins/kaltura_file_sync_client_plugin.rb +157 -0
  33. data/lib/kaltura_plugins/kaltura_http_notification_client_plugin.rb +309 -0
  34. data/lib/kaltura_plugins/kaltura_kontiki_client_plugin.rb +72 -0
  35. data/lib/kaltura_plugins/kaltura_like_client_plugin.rb +82 -0
  36. data/lib/kaltura_plugins/kaltura_metadata_client_plugin.rb +785 -0
  37. data/lib/kaltura_plugins/kaltura_multi_centers_client_plugin.rb +45 -0
  38. data/lib/kaltura_plugins/kaltura_play_ready_client_plugin.rb +347 -0
  39. data/lib/kaltura_plugins/kaltura_scheduled_task_client_plugin.rb +347 -0
  40. data/lib/kaltura_plugins/kaltura_scheduled_task_event_notification_client_plugin.rb +45 -0
  41. data/lib/kaltura_plugins/kaltura_scheduled_task_metadata_client_plugin.rb +51 -0
  42. data/lib/kaltura_plugins/kaltura_short_link_client_plugin.rb +231 -0
  43. data/lib/kaltura_plugins/kaltura_tag_search_client_plugin.rb +145 -0
  44. data/lib/kaltura_plugins/kaltura_thumb_cue_point_client_plugin.rb +105 -0
  45. data/lib/kaltura_plugins/kaltura_var_console_client_plugin.rb +238 -0
  46. data/lib/kaltura_plugins/kaltura_velocix_client_plugin.rb +40 -0
  47. data/lib/kaltura_plugins/kaltura_virus_scan_client_plugin.rb +263 -0
  48. data/lib/kaltura_plugins/kaltura_webex_drop_folder_client_plugin.rb +111 -0
  49. data/lib/kaltura_plugins/kaltura_widevine_client_plugin.rb +195 -0
  50. data/test/access_control_service_test.rb +75 -0
  51. data/test/base_entry_service_test.rb +267 -0
  52. data/test/configuration_test.rb +178 -0
  53. data/test/cue_point_service_test.rb +67 -0
  54. data/test/data_service_test.rb +76 -0
  55. data/test/document_service_test.rb +41 -0
  56. data/test/media/test.mov +0 -0
  57. data/test/media/test.pdf +0 -0
  58. data/test/media/test.png +0 -0
  59. data/test/media/test.swf +0 -0
  60. data/test/media/test.wmv +0 -0
  61. data/test/media_service_test.rb +294 -0
  62. data/test/metadata_profile_service_test.rb +63 -0
  63. data/test/test_helper.rb +59 -0
  64. metadata +132 -0
@@ -0,0 +1,39 @@
1
+ # ===================================================================================================
2
+ # _ __ _ _
3
+ # | |/ /__ _| | |_ _ _ _ _ __ _
4
+ # | ' </ _` | | _| || | '_/ _` |
5
+ # |_|\_\__,_|_|\__|\_,_|_| \__,_|
6
+ #
7
+ # This file is part of the Kaltura Collaborative Media Suite which allows users
8
+ # to do with audio, video, and animation what Wiki platfroms allow them to do with
9
+ # text.
10
+ #
11
+ # Copyright (C) 2006-2011 Kaltura Inc.
12
+ #
13
+ # This program is free software: you can redistribute it and/or modify
14
+ # it under the terms of the GNU Affero General Public License as
15
+ # published by the Free Software Foundation, either version 3 of the
16
+ # License, or (at your option) any later version.
17
+ #
18
+ # This program is distributed in the hope that it will be useful,
19
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
20
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21
+ # GNU Affero General Public License for more details.
22
+ #
23
+ # You should have received a copy of the GNU Affero General Public License
24
+ # along with this program. If not, see <http:#www.gnu.org/licenses/>.
25
+ #
26
+ # @ignore
27
+ # ===================================================================================================
28
+ require 'kaltura_client.rb'
29
+ require File.dirname(__FILE__) + '/kaltura_bulk_upload_xml_client_plugin.rb'
30
+ require File.dirname(__FILE__) + '/kaltura_drop_folder_client_plugin.rb'
31
+
32
+ module Kaltura
33
+
34
+ class KalturaDropFolderXmlBulkUploadFileHandlerConfig < KalturaDropFolderFileHandlerConfig
35
+
36
+ end
37
+
38
+
39
+ end
@@ -0,0 +1,273 @@
1
+ # ===================================================================================================
2
+ # _ __ _ _
3
+ # | |/ /__ _| | |_ _ _ _ _ __ _
4
+ # | ' </ _` | | _| || | '_/ _` |
5
+ # |_|\_\__,_|_|\__|\_,_|_| \__,_|
6
+ #
7
+ # This file is part of the Kaltura Collaborative Media Suite which allows users
8
+ # to do with audio, video, and animation what Wiki platfroms allow them to do with
9
+ # text.
10
+ #
11
+ # Copyright (C) 2006-2011 Kaltura Inc.
12
+ #
13
+ # This program is free software: you can redistribute it and/or modify
14
+ # it under the terms of the GNU Affero General Public License as
15
+ # published by the Free Software Foundation, either version 3 of the
16
+ # License, or (at your option) any later version.
17
+ #
18
+ # This program is distributed in the hope that it will be useful,
19
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
20
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21
+ # GNU Affero General Public License for more details.
22
+ #
23
+ # You should have received a copy of the GNU Affero General Public License
24
+ # along with this program. If not, see <http:#www.gnu.org/licenses/>.
25
+ #
26
+ # @ignore
27
+ # ===================================================================================================
28
+ require 'kaltura_client.rb'
29
+ require File.dirname(__FILE__) + '/kaltura_event_notification_client_plugin.rb'
30
+
31
+ module Kaltura
32
+
33
+ class KalturaEmailNotificationTemplatePriority
34
+ HIGH = 1
35
+ NORMAL = 3
36
+ LOW = 5
37
+ end
38
+
39
+ class KalturaEmailNotificationFormat
40
+ HTML = "1"
41
+ TEXT = "2"
42
+ end
43
+
44
+ class KalturaEmailNotificationRecipientProviderType
45
+ STATIC_LIST = "1"
46
+ CATEGORY = "2"
47
+ USER = "3"
48
+ end
49
+
50
+ class KalturaEmailNotificationTemplateOrderBy
51
+ CREATED_AT_ASC = "+createdAt"
52
+ ID_ASC = "+id"
53
+ UPDATED_AT_ASC = "+updatedAt"
54
+ CREATED_AT_DESC = "-createdAt"
55
+ ID_DESC = "-id"
56
+ UPDATED_AT_DESC = "-updatedAt"
57
+ end
58
+
59
+ class KalturaEmailNotificationRecipient < KalturaObjectBase
60
+ # Recipient e-mail address
61
+ #
62
+ attr_accessor :email
63
+ # Recipient name
64
+ #
65
+ attr_accessor :name
66
+
67
+ end
68
+
69
+ # Abstract class representing the final output recipients going into the batch mechanism
70
+ #
71
+ class KalturaEmailNotificationRecipientJobData < KalturaObjectBase
72
+ # Provider type of the job data.
73
+ #
74
+ attr_accessor :provider_type
75
+
76
+ end
77
+
78
+ # Abstract core class which provides the recipients (to, CC, BCC) for an email notification
79
+ #
80
+ class KalturaEmailNotificationRecipientProvider < KalturaObjectBase
81
+
82
+ end
83
+
84
+ class KalturaCategoryUserProviderFilter < KalturaFilter
85
+ attr_accessor :user_id_equal
86
+ attr_accessor :user_id_in
87
+ attr_accessor :status_equal
88
+ attr_accessor :status_in
89
+ attr_accessor :created_at_greater_than_or_equal
90
+ attr_accessor :created_at_less_than_or_equal
91
+ attr_accessor :updated_at_greater_than_or_equal
92
+ attr_accessor :updated_at_less_than_or_equal
93
+ attr_accessor :update_method_equal
94
+ attr_accessor :update_method_in
95
+ attr_accessor :permission_names_match_and
96
+ attr_accessor :permission_names_match_or
97
+
98
+ def status_equal=(val)
99
+ @status_equal = val.to_i
100
+ end
101
+ def created_at_greater_than_or_equal=(val)
102
+ @created_at_greater_than_or_equal = val.to_i
103
+ end
104
+ def created_at_less_than_or_equal=(val)
105
+ @created_at_less_than_or_equal = val.to_i
106
+ end
107
+ def updated_at_greater_than_or_equal=(val)
108
+ @updated_at_greater_than_or_equal = val.to_i
109
+ end
110
+ def updated_at_less_than_or_equal=(val)
111
+ @updated_at_less_than_or_equal = val.to_i
112
+ end
113
+ def update_method_equal=(val)
114
+ @update_method_equal = val.to_i
115
+ end
116
+ end
117
+
118
+ # Job Data representing the provider of recipients for a single categoryId
119
+ #
120
+ class KalturaEmailNotificationCategoryRecipientJobData < KalturaEmailNotificationRecipientJobData
121
+ attr_accessor :category_user_filter
122
+
123
+ end
124
+
125
+ # API object which provides the recipients of category related notifications.
126
+ #
127
+ class KalturaEmailNotificationCategoryRecipientProvider < KalturaEmailNotificationRecipientProvider
128
+ # The ID of the category whose subscribers should receive the email notification.
129
+ #
130
+ attr_accessor :category_id
131
+ attr_accessor :category_user_filter
132
+
133
+ end
134
+
135
+ class KalturaEmailNotificationParameter < KalturaEventNotificationParameter
136
+
137
+ end
138
+
139
+ # JobData representing the static receipient array
140
+ #
141
+ class KalturaEmailNotificationStaticRecipientJobData < KalturaEmailNotificationRecipientJobData
142
+ # Email to emails and names
143
+ #
144
+ attr_accessor :email_recipients
145
+
146
+ end
147
+
148
+ # API class for recipient provider containing a static list of email recipients.
149
+ #
150
+ class KalturaEmailNotificationStaticRecipientProvider < KalturaEmailNotificationRecipientProvider
151
+ # Email to emails and names
152
+ #
153
+ attr_accessor :email_recipients
154
+
155
+ end
156
+
157
+ class KalturaEmailNotificationTemplate < KalturaEventNotificationTemplate
158
+ # Define the email body format
159
+ #
160
+ attr_accessor :format
161
+ # Define the email subject
162
+ #
163
+ attr_accessor :subject
164
+ # Define the email body content
165
+ #
166
+ attr_accessor :body
167
+ # Define the email sender email
168
+ #
169
+ attr_accessor :from_email
170
+ # Define the email sender name
171
+ #
172
+ attr_accessor :from_name
173
+ # Email recipient emails and names
174
+ #
175
+ attr_accessor :to
176
+ # Email recipient emails and names
177
+ #
178
+ attr_accessor :cc
179
+ # Email recipient emails and names
180
+ #
181
+ attr_accessor :bcc
182
+ # Default email addresses to whom the reply should be sent.
183
+ #
184
+ attr_accessor :reply_to
185
+ # Define the email priority
186
+ #
187
+ attr_accessor :priority
188
+ # Email address that a reading confirmation will be sent
189
+ #
190
+ attr_accessor :confirm_reading_to
191
+ # Hostname to use in Message-Id and Received headers and as default HELLO string.
192
+ # If empty, the value returned by SERVER_NAME is used or 'localhost.localdomain'.
193
+ #
194
+ attr_accessor :hostname
195
+ # Sets the message ID to be used in the Message-Id header.
196
+ # If empty, a unique id will be generated.
197
+ #
198
+ attr_accessor :message_id
199
+ # Adds a e-mail custom header
200
+ #
201
+ attr_accessor :custom_headers
202
+
203
+ def priority=(val)
204
+ @priority = val.to_i
205
+ end
206
+ end
207
+
208
+ # JobData representing the dynamic user receipient array
209
+ #
210
+ class KalturaEmailNotificationUserRecipientJobData < KalturaEmailNotificationRecipientJobData
211
+ attr_accessor :filter
212
+
213
+ end
214
+
215
+ # API class for recipient provider which constructs a dynamic list of recipients according to a user filter
216
+ #
217
+ class KalturaEmailNotificationUserRecipientProvider < KalturaEmailNotificationRecipientProvider
218
+ attr_accessor :filter
219
+
220
+ end
221
+
222
+ class KalturaEmailNotificationDispatchJobData < KalturaEventNotificationDispatchJobData
223
+ # Define the email sender email
224
+ #
225
+ attr_accessor :from_email
226
+ # Define the email sender name
227
+ #
228
+ attr_accessor :from_name
229
+ # Email recipient emails and names, key is mail address and value is the name
230
+ #
231
+ attr_accessor :to
232
+ # Email cc emails and names, key is mail address and value is the name
233
+ #
234
+ attr_accessor :cc
235
+ # Email bcc emails and names, key is mail address and value is the name
236
+ #
237
+ attr_accessor :bcc
238
+ # Email addresses that a replies should be sent to, key is mail address and value is the name
239
+ #
240
+ attr_accessor :reply_to
241
+ # Define the email priority
242
+ #
243
+ attr_accessor :priority
244
+ # Email address that a reading confirmation will be sent to
245
+ #
246
+ attr_accessor :confirm_reading_to
247
+ # Hostname to use in Message-Id and Received headers and as default HELO string.
248
+ # If empty, the value returned by SERVER_NAME is used or 'localhost.localdomain'.
249
+ #
250
+ attr_accessor :hostname
251
+ # Sets the message ID to be used in the Message-Id header.
252
+ # If empty, a unique id will be generated.
253
+ #
254
+ attr_accessor :message_id
255
+ # Adds a e-mail custom header
256
+ #
257
+ attr_accessor :custom_headers
258
+
259
+ def priority=(val)
260
+ @priority = val.to_i
261
+ end
262
+ end
263
+
264
+ class KalturaEmailNotificationTemplateBaseFilter < KalturaEventNotificationTemplateFilter
265
+
266
+ end
267
+
268
+ class KalturaEmailNotificationTemplateFilter < KalturaEmailNotificationTemplateBaseFilter
269
+
270
+ end
271
+
272
+
273
+ end
@@ -0,0 +1,67 @@
1
+ # ===================================================================================================
2
+ # _ __ _ _
3
+ # | |/ /__ _| | |_ _ _ _ _ __ _
4
+ # | ' </ _` | | _| || | '_/ _` |
5
+ # |_|\_\__,_|_|\__|\_,_|_| \__,_|
6
+ #
7
+ # This file is part of the Kaltura Collaborative Media Suite which allows users
8
+ # to do with audio, video, and animation what Wiki platfroms allow them to do with
9
+ # text.
10
+ #
11
+ # Copyright (C) 2006-2011 Kaltura Inc.
12
+ #
13
+ # This program is free software: you can redistribute it and/or modify
14
+ # it under the terms of the GNU Affero General Public License as
15
+ # published by the Free Software Foundation, either version 3 of the
16
+ # License, or (at your option) any later version.
17
+ #
18
+ # This program is distributed in the hope that it will be useful,
19
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
20
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21
+ # GNU Affero General Public License for more details.
22
+ #
23
+ # You should have received a copy of the GNU Affero General Public License
24
+ # along with this program. If not, see <http:#www.gnu.org/licenses/>.
25
+ #
26
+ # @ignore
27
+ # ===================================================================================================
28
+ require 'kaltura_client.rb'
29
+ require File.dirname(__FILE__) + '/kaltura_cue_point_client_plugin.rb'
30
+
31
+ module Kaltura
32
+
33
+ class KalturaEventCuePointOrderBy
34
+ CREATED_AT_ASC = "+createdAt"
35
+ PARTNER_SORT_VALUE_ASC = "+partnerSortValue"
36
+ START_TIME_ASC = "+startTime"
37
+ TRIGGERED_AT_ASC = "+triggeredAt"
38
+ UPDATED_AT_ASC = "+updatedAt"
39
+ CREATED_AT_DESC = "-createdAt"
40
+ PARTNER_SORT_VALUE_DESC = "-partnerSortValue"
41
+ START_TIME_DESC = "-startTime"
42
+ TRIGGERED_AT_DESC = "-triggeredAt"
43
+ UPDATED_AT_DESC = "-updatedAt"
44
+ end
45
+
46
+ class KalturaEventType
47
+ BROADCAST_START = "1"
48
+ BROADCAST_END = "2"
49
+ end
50
+
51
+ class KalturaEventCuePoint < KalturaCuePoint
52
+ attr_accessor :event_type
53
+
54
+ end
55
+
56
+ class KalturaEventCuePointBaseFilter < KalturaCuePointFilter
57
+ attr_accessor :event_type_equal
58
+ attr_accessor :event_type_in
59
+
60
+ end
61
+
62
+ class KalturaEventCuePointFilter < KalturaEventCuePointBaseFilter
63
+
64
+ end
65
+
66
+
67
+ end
@@ -0,0 +1,415 @@
1
+ # ===================================================================================================
2
+ # _ __ _ _
3
+ # | |/ /__ _| | |_ _ _ _ _ __ _
4
+ # | ' </ _` | | _| || | '_/ _` |
5
+ # |_|\_\__,_|_|\__|\_,_|_| \__,_|
6
+ #
7
+ # This file is part of the Kaltura Collaborative Media Suite which allows users
8
+ # to do with audio, video, and animation what Wiki platfroms allow them to do with
9
+ # text.
10
+ #
11
+ # Copyright (C) 2006-2011 Kaltura Inc.
12
+ #
13
+ # This program is free software: you can redistribute it and/or modify
14
+ # it under the terms of the GNU Affero General Public License as
15
+ # published by the Free Software Foundation, either version 3 of the
16
+ # License, or (at your option) any later version.
17
+ #
18
+ # This program is distributed in the hope that it will be useful,
19
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
20
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21
+ # GNU Affero General Public License for more details.
22
+ #
23
+ # You should have received a copy of the GNU Affero General Public License
24
+ # along with this program. If not, see <http:#www.gnu.org/licenses/>.
25
+ #
26
+ # @ignore
27
+ # ===================================================================================================
28
+ require 'kaltura_client.rb'
29
+
30
+ module Kaltura
31
+
32
+ class KalturaEventNotificationTemplateStatus
33
+ DISABLED = 1
34
+ ACTIVE = 2
35
+ DELETED = 3
36
+ end
37
+
38
+ class KalturaEventNotificationEventObjectType
39
+ AD_CUE_POINT = "adCuePointEventNotifications.AdCuePoint"
40
+ ANNOTATION = "annotationEventNotifications.Annotation"
41
+ CAPTION_ASSET = "captionAssetEventNotifications.CaptionAsset"
42
+ CODE_CUE_POINT = "codeCuePointEventNotifications.CodeCuePoint"
43
+ DISTRIBUTION_PROFILE = "contentDistributionEventNotifications.DistributionProfile"
44
+ ENTRY_DISTRIBUTION = "contentDistributionEventNotifications.EntryDistribution"
45
+ CUE_POINT = "cuePointEventNotifications.CuePoint"
46
+ METADATA = "metadataEventNotifications.Metadata"
47
+ ENTRY = "1"
48
+ CATEGORY = "2"
49
+ ASSET = "3"
50
+ FLAVORASSET = "4"
51
+ THUMBASSET = "5"
52
+ KUSER = "8"
53
+ ACCESSCONTROL = "9"
54
+ BATCHJOB = "10"
55
+ BULKUPLOADRESULT = "11"
56
+ CATEGORYKUSER = "12"
57
+ CONVERSIONPROFILE2 = "14"
58
+ FLAVORPARAMS = "15"
59
+ FLAVORPARAMSCONVERSIONPROFILE = "16"
60
+ FLAVORPARAMSOUTPUT = "17"
61
+ GENERICSYNDICATIONFEED = "18"
62
+ KUSERTOUSERROLE = "19"
63
+ PARTNER = "20"
64
+ PERMISSION = "21"
65
+ PERMISSIONITEM = "22"
66
+ PERMISSIONTOPERMISSIONITEM = "23"
67
+ SCHEDULER = "24"
68
+ SCHEDULERCONFIG = "25"
69
+ SCHEDULERSTATUS = "26"
70
+ SCHEDULERWORKER = "27"
71
+ STORAGEPROFILE = "28"
72
+ SYNDICATIONFEED = "29"
73
+ THUMBPARAMS = "31"
74
+ THUMBPARAMSOUTPUT = "32"
75
+ UPLOADTOKEN = "33"
76
+ USERLOGINDATA = "34"
77
+ USERROLE = "35"
78
+ WIDGET = "36"
79
+ CATEGORYENTRY = "37"
80
+ end
81
+
82
+ class KalturaEventNotificationEventType
83
+ BATCH_JOB_STATUS = "1"
84
+ OBJECT_ADDED = "2"
85
+ OBJECT_CHANGED = "3"
86
+ OBJECT_COPIED = "4"
87
+ OBJECT_CREATED = "5"
88
+ OBJECT_DATA_CHANGED = "6"
89
+ OBJECT_DELETED = "7"
90
+ OBJECT_ERASED = "8"
91
+ OBJECT_READY_FOR_REPLACMENT = "9"
92
+ OBJECT_SAVED = "10"
93
+ OBJECT_UPDATED = "11"
94
+ OBJECT_REPLACED = "12"
95
+ OBJECT_READY_FOR_INDEX = "13"
96
+ end
97
+
98
+ class KalturaEventNotificationTemplateOrderBy
99
+ CREATED_AT_ASC = "+createdAt"
100
+ ID_ASC = "+id"
101
+ UPDATED_AT_ASC = "+updatedAt"
102
+ CREATED_AT_DESC = "-createdAt"
103
+ ID_DESC = "-id"
104
+ UPDATED_AT_DESC = "-updatedAt"
105
+ end
106
+
107
+ class KalturaEventNotificationTemplateType
108
+ EMAIL = "emailNotification.Email"
109
+ HTTP = "httpNotification.Http"
110
+ end
111
+
112
+ class KalturaEventNotificationParameter < KalturaObjectBase
113
+ # The key in the subject and body to be replaced with the dynamic value
114
+ #
115
+ attr_accessor :key
116
+ attr_accessor :description
117
+ # The dynamic value to be placed in the final output
118
+ #
119
+ attr_accessor :value
120
+
121
+ end
122
+
123
+ class KalturaEventNotificationTemplate < KalturaObjectBase
124
+ attr_accessor :id
125
+ attr_accessor :partner_id
126
+ attr_accessor :name
127
+ attr_accessor :system_name
128
+ attr_accessor :description
129
+ attr_accessor :type
130
+ attr_accessor :status
131
+ attr_accessor :created_at
132
+ attr_accessor :updated_at
133
+ # Define that the template could be dispatched manually from the API
134
+ #
135
+ attr_accessor :manual_dispatch_enabled
136
+ # Define that the template could be dispatched automatically by the system
137
+ #
138
+ attr_accessor :automatic_dispatch_enabled
139
+ # Define the event that should trigger this notification
140
+ #
141
+ attr_accessor :event_type
142
+ # Define the object that raied the event that should trigger this notification
143
+ #
144
+ attr_accessor :event_object_type
145
+ # Define the conditions that cause this notification to be triggered
146
+ #
147
+ attr_accessor :event_conditions
148
+ # Define the content dynamic parameters
149
+ #
150
+ attr_accessor :content_parameters
151
+ # Define the content dynamic parameters
152
+ #
153
+ attr_accessor :user_parameters
154
+
155
+ def id=(val)
156
+ @id = val.to_i
157
+ end
158
+ def partner_id=(val)
159
+ @partner_id = val.to_i
160
+ end
161
+ def status=(val)
162
+ @status = val.to_i
163
+ end
164
+ def created_at=(val)
165
+ @created_at = val.to_i
166
+ end
167
+ def updated_at=(val)
168
+ @updated_at = val.to_i
169
+ end
170
+ def manual_dispatch_enabled=(val)
171
+ @manual_dispatch_enabled = to_b(val)
172
+ end
173
+ def automatic_dispatch_enabled=(val)
174
+ @automatic_dispatch_enabled = to_b(val)
175
+ end
176
+ end
177
+
178
+ class KalturaEventNotificationTemplateListResponse < KalturaObjectBase
179
+ attr_accessor :objects
180
+ attr_accessor :total_count
181
+
182
+ def total_count=(val)
183
+ @total_count = val.to_i
184
+ end
185
+ end
186
+
187
+ class KalturaEventFieldCondition < KalturaCondition
188
+ # The field to be evaluated at runtime
189
+ #
190
+ attr_accessor :field
191
+
192
+ end
193
+
194
+ class KalturaEventNotificationArrayParameter < KalturaEventNotificationParameter
195
+ attr_accessor :values
196
+ # Used to restrict the values to close list
197
+ #
198
+ attr_accessor :allowed_values
199
+
200
+ end
201
+
202
+ class KalturaEventNotificationDispatchJobData < KalturaJobData
203
+ attr_accessor :template_id
204
+ # Define the content dynamic parameters
205
+ #
206
+ attr_accessor :content_parameters
207
+
208
+ def template_id=(val)
209
+ @template_id = val.to_i
210
+ end
211
+ end
212
+
213
+ class KalturaEventNotificationScope < KalturaScope
214
+ attr_accessor :object_id
215
+ attr_accessor :scope_object_type
216
+
217
+ end
218
+
219
+ class KalturaEventNotificationTemplateBaseFilter < KalturaFilter
220
+ attr_accessor :id_equal
221
+ attr_accessor :id_in
222
+ attr_accessor :partner_id_equal
223
+ attr_accessor :partner_id_in
224
+ attr_accessor :system_name_equal
225
+ attr_accessor :system_name_in
226
+ attr_accessor :type_equal
227
+ attr_accessor :type_in
228
+ attr_accessor :status_equal
229
+ attr_accessor :status_in
230
+ attr_accessor :created_at_greater_than_or_equal
231
+ attr_accessor :created_at_less_than_or_equal
232
+ attr_accessor :updated_at_greater_than_or_equal
233
+ attr_accessor :updated_at_less_than_or_equal
234
+
235
+ def id_equal=(val)
236
+ @id_equal = val.to_i
237
+ end
238
+ def partner_id_equal=(val)
239
+ @partner_id_equal = val.to_i
240
+ end
241
+ def status_equal=(val)
242
+ @status_equal = val.to_i
243
+ end
244
+ def created_at_greater_than_or_equal=(val)
245
+ @created_at_greater_than_or_equal = val.to_i
246
+ end
247
+ def created_at_less_than_or_equal=(val)
248
+ @created_at_less_than_or_equal = val.to_i
249
+ end
250
+ def updated_at_greater_than_or_equal=(val)
251
+ @updated_at_greater_than_or_equal = val.to_i
252
+ end
253
+ def updated_at_less_than_or_equal=(val)
254
+ @updated_at_less_than_or_equal = val.to_i
255
+ end
256
+ end
257
+
258
+ class KalturaEventObjectChangedCondition < KalturaCondition
259
+ # Comma seperated column names to be tested
260
+ #
261
+ attr_accessor :modified_columns
262
+
263
+ end
264
+
265
+ class KalturaEventNotificationTemplateFilter < KalturaEventNotificationTemplateBaseFilter
266
+
267
+ end
268
+
269
+
270
+ # Event notification template service lets you create and manage event notification templates
271
+ #
272
+ class KalturaEventNotificationTemplateService < KalturaServiceBase
273
+ def initialize(client)
274
+ super(client)
275
+ end
276
+
277
+ # Allows you to add a new event notification template object
278
+ #
279
+ def add(event_notification_template)
280
+ kparams = {}
281
+ client.add_param(kparams, 'eventNotificationTemplate', event_notification_template);
282
+ client.queue_service_action_call('eventnotification_eventnotificationtemplate', 'add', kparams);
283
+ if (client.is_multirequest)
284
+ return nil;
285
+ end
286
+ return client.do_queue();
287
+ end
288
+
289
+ # Allows you to clone exiting event notification template object and create a new one with similar configuration
290
+ #
291
+ def clone(id, event_notification_template=KalturaNotImplemented)
292
+ kparams = {}
293
+ # source template to clone
294
+ client.add_param(kparams, 'id', id);
295
+ # overwrite configuration object
296
+ client.add_param(kparams, 'eventNotificationTemplate', event_notification_template);
297
+ client.queue_service_action_call('eventnotification_eventnotificationtemplate', 'clone', kparams);
298
+ if (client.is_multirequest)
299
+ return nil;
300
+ end
301
+ return client.do_queue();
302
+ end
303
+
304
+ # Retrieve an event notification template object by id
305
+ #
306
+ def get(id)
307
+ kparams = {}
308
+ client.add_param(kparams, 'id', id);
309
+ client.queue_service_action_call('eventnotification_eventnotificationtemplate', 'get', kparams);
310
+ if (client.is_multirequest)
311
+ return nil;
312
+ end
313
+ return client.do_queue();
314
+ end
315
+
316
+ # Update an existing event notification template object
317
+ #
318
+ def update(id, event_notification_template)
319
+ kparams = {}
320
+ client.add_param(kparams, 'id', id);
321
+ client.add_param(kparams, 'eventNotificationTemplate', event_notification_template);
322
+ client.queue_service_action_call('eventnotification_eventnotificationtemplate', 'update', kparams);
323
+ if (client.is_multirequest)
324
+ return nil;
325
+ end
326
+ return client.do_queue();
327
+ end
328
+
329
+ # Update event notification template status by id
330
+ #
331
+ def update_status(id, status)
332
+ kparams = {}
333
+ client.add_param(kparams, 'id', id);
334
+ client.add_param(kparams, 'status', status);
335
+ client.queue_service_action_call('eventnotification_eventnotificationtemplate', 'updateStatus', kparams);
336
+ if (client.is_multirequest)
337
+ return nil;
338
+ end
339
+ return client.do_queue();
340
+ end
341
+
342
+ # Delete an event notification template object
343
+ #
344
+ def delete(id)
345
+ kparams = {}
346
+ client.add_param(kparams, 'id', id);
347
+ client.queue_service_action_call('eventnotification_eventnotificationtemplate', 'delete', kparams);
348
+ if (client.is_multirequest)
349
+ return nil;
350
+ end
351
+ return client.do_queue();
352
+ end
353
+
354
+ # list event notification template objects
355
+ #
356
+ def list(filter=KalturaNotImplemented, pager=KalturaNotImplemented)
357
+ kparams = {}
358
+ client.add_param(kparams, 'filter', filter);
359
+ client.add_param(kparams, 'pager', pager);
360
+ client.queue_service_action_call('eventnotification_eventnotificationtemplate', 'list', kparams);
361
+ if (client.is_multirequest)
362
+ return nil;
363
+ end
364
+ return client.do_queue();
365
+ end
366
+
367
+ def list_by_partner(filter=KalturaNotImplemented, pager=KalturaNotImplemented)
368
+ kparams = {}
369
+ client.add_param(kparams, 'filter', filter);
370
+ client.add_param(kparams, 'pager', pager);
371
+ client.queue_service_action_call('eventnotification_eventnotificationtemplate', 'listByPartner', kparams);
372
+ if (client.is_multirequest)
373
+ return nil;
374
+ end
375
+ return client.do_queue();
376
+ end
377
+
378
+ # Dispatch event notification object by id
379
+ #
380
+ def dispatch(id, scope)
381
+ kparams = {}
382
+ client.add_param(kparams, 'id', id);
383
+ client.add_param(kparams, 'scope', scope);
384
+ client.queue_service_action_call('eventnotification_eventnotificationtemplate', 'dispatch', kparams);
385
+ if (client.is_multirequest)
386
+ return nil;
387
+ end
388
+ return client.do_queue();
389
+ end
390
+
391
+ # Action lists the template partner event notification templates.
392
+ #
393
+ def list_templates(filter=KalturaNotImplemented, pager=KalturaNotImplemented)
394
+ kparams = {}
395
+ client.add_param(kparams, 'filter', filter);
396
+ client.add_param(kparams, 'pager', pager);
397
+ client.queue_service_action_call('eventnotification_eventnotificationtemplate', 'listTemplates', kparams);
398
+ if (client.is_multirequest)
399
+ return nil;
400
+ end
401
+ return client.do_queue();
402
+ end
403
+ end
404
+
405
+ class KalturaClient < KalturaClientBase
406
+ attr_reader :event_notification_template_service
407
+ def event_notification_template_service
408
+ if (@event_notification_template_service == nil)
409
+ @event_notification_template_service = KalturaEventNotificationTemplateService.new(self)
410
+ end
411
+ return @event_notification_template_service
412
+ end
413
+ end
414
+
415
+ end