CiscoWebex 0.0.4

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 (82) hide show
  1. checksums.yaml +7 -0
  2. data/lib/Admin/Admin.rb +84 -0
  3. data/lib/Admin/AuditEvents.rb +70 -0
  4. data/lib/Admin/Authorizations.rb +52 -0
  5. data/lib/Admin/Licenses.rb +50 -0
  6. data/lib/Admin/Organizations.rb +52 -0
  7. data/lib/Admin/People.rb +81 -0
  8. data/lib/Admin/ResourceGroups.rb +118 -0
  9. data/lib/Admin/Roles.rb +60 -0
  10. data/lib/Admin.rb +11 -0
  11. data/lib/CC/AddressBooks.rb +55 -0
  12. data/lib/CC/AgentProfiles.rb +71 -0
  13. data/lib/CC/Agents.rb +67 -0
  14. data/lib/CC/AuxiliaryCodes.rb +55 -0
  15. data/lib/CC/CC.rb +157 -0
  16. data/lib/CC/Captures.rb +30 -0
  17. data/lib/CC/DialPlans.rb +56 -0
  18. data/lib/CC/EntryPointMappings.rb +56 -0
  19. data/lib/CC/EntryPoints.rb +55 -0
  20. data/lib/CC/Journey/Actions.rb +41 -0
  21. data/lib/CC/Journey/Aliases.rb +28 -0
  22. data/lib/CC/Journey/Events.rb +37 -0
  23. data/lib/CC/Journey/Identities.rb +41 -0
  24. data/lib/CC/Journey/Journey.rb +84 -0
  25. data/lib/CC/Journey/ProfileViews.rb +24 -0
  26. data/lib/CC/Journey/Report.rb +24 -0
  27. data/lib/CC/Journey/Reports.rb +24 -0
  28. data/lib/CC/Journey/Streams.rb +41 -0
  29. data/lib/CC/Journey/Views.rb +80 -0
  30. data/lib/CC/Journey.rb +9 -0
  31. data/lib/CC/MultimediaProfiles.rb +52 -0
  32. data/lib/CC/OutboundANI.rb +56 -0
  33. data/lib/CC/Queues.rb +64 -0
  34. data/lib/CC/Sites.rb +51 -0
  35. data/lib/CC/SkillProfiles.rb +55 -0
  36. data/lib/CC/Skills.rb +55 -0
  37. data/lib/CC/Subscriptions.rb +55 -0
  38. data/lib/CC/Tasks.rb +37 -0
  39. data/lib/CC/Teams.rb +55 -0
  40. data/lib/CC/UserProfiles.rb +56 -0
  41. data/lib/CC/Users.rb +57 -0
  42. data/lib/CC.rb +26 -0
  43. data/lib/Calling/CallControl.rb +210 -0
  44. data/lib/Calling/Calling.rb +64 -0
  45. data/lib/Calling/Calls.rb +44 -0
  46. data/lib/Calling/Locations.rb +50 -0
  47. data/lib/Calling/Voicemail.rb +73 -0
  48. data/lib/Calling.rb +9 -0
  49. data/lib/CiscoWebex.rb +32 -0
  50. data/lib/Devices/Configurations.rb +52 -0
  51. data/lib/Devices/Devices.rb +66 -0
  52. data/lib/Devices/Endpoints.rb +51 -0
  53. data/lib/Devices/Workspaces.rb +51 -0
  54. data/lib/Devices/Xapi.rb +75 -0
  55. data/lib/Devices.rb +7 -0
  56. data/lib/Meetings/ControlStatus.rb +53 -0
  57. data/lib/Meetings/Invitees.rb +52 -0
  58. data/lib/Meetings/Meetings.rb +91 -0
  59. data/lib/Meetings/Participants.rb +52 -0
  60. data/lib/Meetings/Qualities.rb +55 -0
  61. data/lib/Meetings/Registrations.rb +116 -0
  62. data/lib/Meetings/SessionTypes.rb +57 -0
  63. data/lib/Meetings/Templates.rb +57 -0
  64. data/lib/Meetings/Transcripts.rb +98 -0
  65. data/lib/Meetings/WebexMeetings.rb +108 -0
  66. data/lib/Meetings.rb +13 -0
  67. data/lib/Messaging/Attachements.rb +60 -0
  68. data/lib/Messaging/Classifications.rb +64 -0
  69. data/lib/Messaging/Events.rb +60 -0
  70. data/lib/Messaging/Memberships.rb +59 -0
  71. data/lib/Messaging/Messages.rb +126 -0
  72. data/lib/Messaging/Messaging.rb +92 -0
  73. data/lib/Messaging/People.rb +81 -0
  74. data/lib/Messaging/Rooms.rb +121 -0
  75. data/lib/Messaging/Teams.rb +117 -0
  76. data/lib/Messaging/Webhooks.rb +63 -0
  77. data/lib/Messaging.rb +13 -0
  78. data/lib/REST/Rest.rb +213 -0
  79. data/lib/REST/RestCC.rb +242 -0
  80. data/lib/Toolbox/Toolbox.rb +78 -0
  81. data/lib/bersion.rb +3 -0
  82. metadata +122 -0
@@ -0,0 +1,71 @@
1
+ module CiscoWebex
2
+ class AgentProfiles < ContactCenter
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ # initialize object with stored token
7
+ def initialize(token=nil, org_id=nil)
8
+ if token == nil || org_id == nil
9
+ STDERR.puts "Must provide API key for CiscoWebex::ContactCenter::AgentProfiles"
10
+ return false
11
+ else
12
+ @auth_token = token if token
13
+ @org_id = org_id # test token and store users profile
14
+ end
15
+ end
16
+
17
+ def this()
18
+ puts "CiscoWebex::ContactCenter::AgentProfiles - Org:#{@org_id}"
19
+ end
20
+
21
+ def get(id, limit=5000)
22
+ return CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/agent-profile/#{id}", {}, limit)['data'] rescue false
23
+ end
24
+
25
+ def list(params={}, limit=5000)
26
+ return CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/agent-profile", {}, limit)['data'] rescue false
27
+ end
28
+
29
+ def search(params={}, limit=5000)
30
+ if params.class == Hash && params.has_key?('name')
31
+ search_param = params['name']
32
+ elsif params.class == String
33
+ search_param = params
34
+ else
35
+ STDERR.puts "Must provide name to search on"
36
+ return false
37
+ end
38
+
39
+ cc_data = CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/agent-profile")['data'] rescue []
40
+ for data in cc_data['data'] do
41
+ if search_param == cc_data['name']
42
+ return data
43
+ end
44
+ end
45
+
46
+ STDERR.puts "Agent Profile #{search_param} not found."
47
+ return nil
48
+ end
49
+
50
+ def save(params={})
51
+ return CiscoWebex::RestCC.post(@auth_token, "/organization/#{@org_id}/agent-profile/bulk", params) rescue false
52
+ end
53
+
54
+ def create(params)
55
+ return CiscoWebex::RestCC.post(@auth_token, "/organization/#{@org_id}/agent-profile", params) rescue false
56
+ end
57
+
58
+ def delete(id)
59
+ return CiscoWebex::RestCC.delete(@auth_token, "/organization/#{@org_id}/agent-profile/#{id}") rescue false
60
+ end
61
+
62
+ def update(id, params)
63
+ return CiscoWebex::RestCC.put(@auth_token, "/organization/#{@org_id}/agent-profile/#{id}", params) rescue false
64
+ end
65
+
66
+ def patch(id, params)
67
+ return CiscoWebex::RestCC.patch(@auth_token, "/organization/#{@org_id}/agent-profile/#{id}", params) rescue false
68
+ end
69
+ end
70
+ end
71
+
data/lib/CC/Agents.rb ADDED
@@ -0,0 +1,67 @@
1
+ module CiscoWebex
2
+ class Agents < ContactCenter
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ # initialize object with stored token
7
+ def initialize(token=nil, org_id=nil)
8
+ if token == nil || org_id == nil
9
+ STDERR.puts "Must provide API key for CiscoWebex::ContactCenter::Agent"
10
+ return false
11
+ else
12
+ @auth_token = token
13
+ @org_id = org_id
14
+ end
15
+ end
16
+
17
+ def round_time(timestamp=nil, interval=15)
18
+ interval = interval * 60
19
+ if timestamp.class == DateTime
20
+ timestamp = timestamp.to_i
21
+ elsif timestamp.class == String
22
+ timestamp = Time.parse(timestamp.to_s).to_i
23
+ elsif timestamp.class != Integer
24
+ timestamp = DateTime.now.strftime('%s').to_i
25
+ end
26
+
27
+ rounded = Time.at((timestamp / interval).round * interval).to_i * 1000
28
+ end
29
+
30
+ def this()
31
+ puts "CiscoWebex::ContactCenter::Agent - Org:#{@org_id}"
32
+ end
33
+
34
+ def activities(params={}, limit=5000)
35
+ if params.class != Hash || params == {}
36
+ STDERR.puts "CiscoWebex::ContactCenter::Agents.activites() - You should provide search parameters, using defaults. Good luck!"
37
+ params = {}
38
+ end
39
+ params['from'] = CiscoWebex::Toolbox::WebexTime.shift("now", -86400, "CC") if ! params.has_key?('from')
40
+ return CiscoWebex::RestCC.get(@auth_token, "/v1/agents/activitiies", params, limit)['data'] rescue false
41
+ end
42
+
43
+ def statistics(params={}, limit=5000)
44
+ if params.class != Hash || params == {}
45
+ STDERR.puts "CiscoWebex::ContactCenter::Agents.statistics() - you should provide search parameters, using defaults. Good luck!"
46
+ params = {}
47
+ end
48
+
49
+ params['orgId'] = @org_id
50
+ params['interval'] = 60 if ! params.has_key?('interval')
51
+
52
+ if ! params.has_key?('from')
53
+ params['from'] = CiscoWebex::Toolbox::WebexTime.shift("now", -60, "ms", params['interval'])
54
+ else
55
+ params['from'] = CiscoWebex::Toolbox::WebexTime.round(params['from'], params['interval'], "ms")
56
+ end
57
+ if ! params.has_key?('to')
58
+ params['to'] = CiscoWebex::Toolbox::WebexTime.round("now", params['interval'], "ms")
59
+ else
60
+ params['to'] = CiscoWebex::Toolbox::WebexTime.round(params['to'], params['interval'], "ms")
61
+ end
62
+
63
+ return CiscoWebex::RestCC.get(@auth_token, "/v1/agents/statistics", params, limit)['data'] rescue false
64
+ end
65
+ end
66
+ end
67
+
@@ -0,0 +1,55 @@
1
+ module CiscoWebex
2
+ class AuxiliaryCodes < ContactCenter
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ # initialize object with stored token
7
+ def initialize(token=nil, org_id=nil)
8
+ if token == nil || org_id == nil
9
+ STDERR.puts "Must provide API key for CiscoWebex::ContactCenter::AuxiliaryCodes"
10
+ return false
11
+ else
12
+ @auth_token = token if token
13
+ @org_id = org_id # test token and store users profile
14
+ end
15
+ end
16
+
17
+ def this()
18
+ puts "CiscoWebex::ContactCenter::AuxiliaryCodes - Org:#{@org_id}"
19
+ end
20
+
21
+ def get(id, limit=5000)
22
+ return CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/auxiliary-code/#{id}", {}, limit)['data'] rescue false
23
+ end
24
+
25
+ def list(params={}, limit=5000)
26
+ return CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/auxiliary-code", {}, limit)['data'] rescue false
27
+ end
28
+
29
+ def search(params={}, limit=5000)
30
+ params = { "name"=> params } if params.class == String
31
+ return CiscoWebex::Toolbox.search(list(), params)
32
+ end
33
+
34
+ def save(params={})
35
+ return CiscoWebex::RestCC.post(@auth_token, "/organization/#{@org_id}/auxiliary-code/bulk", params) rescue false
36
+ end
37
+
38
+ def create(params)
39
+ return CiscoWebex::RestCC.post(@auth_token, "/organization/#{@org_id}/auxiliary-code", params) rescue false
40
+ end
41
+
42
+ def delete(id)
43
+ return CiscoWebex::RestCC.delete(@auth_token, "/organization/#{@org_id}/auxiliary-code/#{id}") rescue false
44
+ end
45
+
46
+ def update(id, params)
47
+ return CiscoWebex::RestCC.put(@auth_token, "/organization/#{@org_id}/auxiliary-code/#{id}", params) rescue false
48
+ end
49
+
50
+ def patch(id, params)
51
+ return CiscoWebex::RestCC.patch(@auth_token, "/organization/#{@org_id}/auxiliary-code/#{id}", params) rescue false
52
+ end
53
+ end
54
+ end
55
+
data/lib/CC/CC.rb ADDED
@@ -0,0 +1,157 @@
1
+ module CiscoWebex
2
+ class ContactCenter
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ # initialize object with stored token
7
+ def initialize(token=nil)
8
+ if not token
9
+ raise "Must provide API key"
10
+ else
11
+ @auth_token = token if token
12
+ @org_id = my_org() # test token and store users profile
13
+ if ! @org_id
14
+ raise "CiscoWebex::ContactCenter API Token not valid!"
15
+ else
16
+ # initiate all class methods
17
+ @users = Users.new(@auth_token, @org_id)
18
+ @user_profiles = UserProfiles.new(@auth_token, @org_id)
19
+ @teams = CCTeams.new(@auth_token, @org_id)
20
+ @skills = Skills.new(@auth_token, @org_id)
21
+ @agents = Agents.new(@auth_token, @org_id)
22
+ @queues = Queues.new(@auth_token, @org_id)
23
+ @tasks = Tasks.new(@auth_token, @org_id)
24
+ @captures = Captures.new(@auth_token, @org_id)
25
+ @subscriptions = Subscriptions.new(@auth_token, @org_id)
26
+ @skill_profiles = SkillProfiles.new(@auth_token, @org_id)
27
+ @sites = Sites.new(@auth_token, @org_id)
28
+ @entry_points = EntryPoints.new(@auth_token, @org_id)
29
+ @multimedia_profiles = MultimediaProfiles.new(@auth_token, @org_id)
30
+ @journey = Journey.new(@auth_token, @org_id)
31
+ @address_books = AddressBooks.new(@auth_token, @org_id)
32
+ @agent_profiles = AgentProfiles.new(@auth_token, @org_id)
33
+ @auxiliary_codes = AuxiliaryCodes.new(@auth_token, @org_id)
34
+ @dial_plans = DialPlans.new(@auth_token, @org_id)
35
+ @entry_point_mappings = EntryPointMappings.new(@auth_token, @org_id)
36
+ @outbound_ani = OutboundANI.new(@auth_token, @org_id)
37
+ end
38
+ end
39
+ end
40
+
41
+ def this()
42
+ puts "CiscoWebex::ContactCenter - Org:#{@org_id}"
43
+ end
44
+
45
+ # access to REST API
46
+ def get(uri, params=nil, limit=50000)
47
+ return CiscoWebex::RestCC.get(@auth_token, uri, params, limit)
48
+ end
49
+
50
+ # access to REST API
51
+ def head(uri, params=nil)
52
+ return CiscoWebex::RestCC.head(@auth_token, uri, params)
53
+ end
54
+
55
+ # access to REST API
56
+ def post(uri, params=nil)
57
+ return CiscoWebex::RestCC.post(@auth_token, uri, params)
58
+ end
59
+
60
+ # access to REST API
61
+ def put(uri, params=nil)
62
+ return CiscoWebex::RestCC.put(@auth_token, uri, params)
63
+ end
64
+
65
+ # shortcut for getting the org associated with the token
66
+ def my_org()
67
+ return CiscoWebex::RestCC.get(@auth_token, "/v1/subscriptions")['meta']['orgId'] rescue nil
68
+ end
69
+
70
+ # sub class for Journey methods
71
+ def outbound_ani()
72
+ return @outbound_ani
73
+ end
74
+
75
+ # sub class for Journey methods
76
+ def entry_point_mappings()
77
+ return @entry_point_mappings
78
+ end
79
+
80
+ # sub class for Journey methods
81
+ def dial_plans()
82
+ return @dial_plans
83
+ end
84
+
85
+ # sub class for Journey methods
86
+ def auxiliary_codes()
87
+ return @auxiliary_codes
88
+ end
89
+
90
+ # sub class for Journey methods
91
+ def agent_profiles()
92
+ return @agent_profiles
93
+ end
94
+
95
+ # sub class for Journey methods
96
+ def address_books()
97
+ return @address_books
98
+ end
99
+
100
+ # sub class for Journey methods
101
+ def journey()
102
+ return @journey
103
+ end
104
+
105
+ def users()
106
+ return @users
107
+ end
108
+
109
+ def teams()
110
+ return @teams
111
+ end
112
+
113
+ def skills()
114
+ return @skills
115
+ end
116
+
117
+ def entry_points()
118
+ return @entry_points
119
+ end
120
+
121
+ def subscriptions()
122
+ return @subscriptions
123
+ end
124
+
125
+ def tasks()
126
+ return @tasks
127
+ end
128
+
129
+ def skill_profiles()
130
+ return @skill_profiles
131
+ end
132
+
133
+ def queues()
134
+ return @queues
135
+ end
136
+
137
+ def captures()
138
+ return @captures
139
+ end
140
+
141
+ def multimedia_profiles()
142
+ return @multimedia_profiles
143
+ end
144
+
145
+ def agents()
146
+ return @agents
147
+ end
148
+
149
+ def sites()
150
+ return @sites
151
+ end
152
+
153
+ def user_profiles()
154
+ return @user_profiles
155
+ end
156
+ end
157
+ end
@@ -0,0 +1,30 @@
1
+ module CiscoWebex
2
+ class Captures < ContactCenter
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ # initialize object with stored token
7
+ def initialize(token=nil, org_id=nil)
8
+ if token == nil || org_id == nil
9
+ STDERR.puts "Must provide API key for CiscoWebex::ContactCenter::Capture"
10
+ return false
11
+ else
12
+ @auth_token = token if token
13
+ @org_id = org_id
14
+ end
15
+ end
16
+
17
+ def this()
18
+ puts "CiscoWebex::ContactCenter::Capture - Org:#{@org_id}"
19
+ end
20
+
21
+ def activities(params={}, limit=5000)
22
+ if ! params.has_key?('taskIds')
23
+ STDERR.puts "Must provide taskIds for Capture query"
24
+ return False
25
+ end
26
+ return CiscoWebex::RestCC.post(@auth_token, "/v1/captures/query", {}, limit)['data'] rescue false
27
+ end
28
+ end
29
+ end
30
+
@@ -0,0 +1,56 @@
1
+ module CiscoWebex
2
+ class DialPlans < ContactCenter
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ # initialize object with stored token
7
+ def initialize(token=nil, org_id=nil)
8
+ if token == nil || org_id == nil
9
+ STDERR.puts "Must provide API key for CiscoWebex::ContactCenter::DialPlans"
10
+ return false
11
+ else
12
+ @auth_token = token if token
13
+ @org_id = org_id # test token and store users profile
14
+ end
15
+ end
16
+
17
+ def this()
18
+ puts "CiscoWebex::ContactCenter::DialPlans - Org:#{@org_id}"
19
+ end
20
+
21
+ def get(id, limit=5000)
22
+ return CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/dial-plan/#{id}", {}, limit)['data'] rescue false
23
+ end
24
+
25
+ def list(params={}, limit=5000)
26
+ return CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/dial-plan", {}, limit)['data'] rescue false
27
+ end
28
+
29
+ def search(params={})
30
+ params = { "name"=> params } if params.class == String
31
+ return CiscoWebex::Toolbox.search(list(), params)
32
+ end
33
+
34
+ def save(params={})
35
+ return CiscoWebex::RestCC.post(@auth_token, "/organization/#{@org_id}/dial-plan/bulk", params) rescue false
36
+ end
37
+
38
+ def create(params)
39
+ return CiscoWebex::RestCC.post(@auth_token, "/organization/#{@org_id}/dial-plan", params) rescue false
40
+ end
41
+
42
+ def delete(id)
43
+ return CiscoWebex::RestCC.delete(@auth_token, "/organization/#{@org_id}/dial-plan/#{id}") rescue false
44
+ end
45
+
46
+ def update(id, params)
47
+ return CiscoWebex::RestCC.put(@auth_token, "/organization/#{@org_id}/dial-plan/#{id}", params) rescue false
48
+ end
49
+
50
+ def patch(id, params)
51
+ STDERR.puts "PATCH not Implemented"
52
+ return false
53
+ end
54
+ end
55
+ end
56
+
@@ -0,0 +1,56 @@
1
+ module CiscoWebex
2
+ class EntryPointMappings < ContactCenter
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ # initialize object with stored token
7
+ def initialize(token=nil, org_id=nil)
8
+ if token == nil || org_id == nil
9
+ STDERR.puts "Must provide API key for CiscoWebex::ContactCenter::EntryPointMappings"
10
+ return false
11
+ else
12
+ @auth_token = token if token
13
+ @org_id = org_id # test token and store users profile
14
+ end
15
+ end
16
+
17
+ def this()
18
+ puts "CiscoWebex::ContactCenter::EntryPointMappings - Org:#{@org_id}"
19
+ end
20
+
21
+ def get(id, limit=5000)
22
+ return CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/dial-number/#{id}", {}, limit)['data'] rescue false
23
+ end
24
+
25
+ def list(params={}, limit=5000)
26
+ return CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/dial-number", {}, limit)['data'] rescue false
27
+ end
28
+
29
+ def search(params={})
30
+ params = { "dialledNumber"=> params } if params.class == String
31
+ return CiscoWebex::Toolbox.search(list(), params)
32
+ end
33
+
34
+ def save(params={})
35
+ return CiscoWebex::RestCC.post(@auth_token, "/organization/#{@org_id}/dial-number/bulk", params) rescue false
36
+ end
37
+
38
+ def create(params)
39
+ return CiscoWebex::RestCC.post(@auth_token, "/organization/#{@org_id}/dial-number", params) rescue false
40
+ end
41
+
42
+ def delete(id)
43
+ return CiscoWebex::RestCC.delete(@auth_token, "/organization/#{@org_id}/dial-number/#{id}") rescue false
44
+ end
45
+
46
+ def update(id, params)
47
+ return CiscoWebex::RestCC.put(@auth_token, "/organization/#{@org_id}/dial-number/#{id}", params) rescue false
48
+ end
49
+
50
+ def patch(id, params)
51
+ STDERR.puts "PATCH not Implemented."
52
+ return False
53
+ end
54
+ end
55
+ end
56
+
@@ -0,0 +1,55 @@
1
+ module CiscoWebex
2
+ class EntryPoints < ContactCenter
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ # initialize object with stored token
7
+ def initialize(token=nil, org_id=nil)
8
+ if token == nil || org_id == nil
9
+ STDERR.puts "Must provide API key for CiscoWebex::ContactCenter::entry-point"
10
+ return false
11
+ else
12
+ @auth_token = token if token
13
+ @org_id = org_id # test token and store users profile
14
+ end
15
+ end
16
+
17
+ def this()
18
+ puts "CiscoWebex::ContactCenter::entry-point - Org:#{@org_id}"
19
+ end
20
+
21
+ def get(id, limit=5000)
22
+ return CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/entry-point/#{id}", {}, limit)['data'] rescue false
23
+ end
24
+
25
+ def list(params={}, limit=5000)
26
+ return CiscoWebex::RestCC.get(@auth_token, "/organization/#{@org_id}/entry-point", {}, limit)['data'] rescue false
27
+ end
28
+
29
+ def search(params={}, limit=5000)
30
+ params = { "name"=> params } if params.class == String
31
+ return CiscoWebex::Toolbox.search(list(), params)
32
+ end
33
+
34
+ def save(params={})
35
+ return CiscoWebex::RestCC.post(@auth_token, "/organization/#{@org_id}/entry-point/bulk", params) rescue false
36
+ end
37
+
38
+ def create(params)
39
+ return CiscoWebex::RestCC.post(@auth_token, "/organization/#{@org_id}/entry-point", params) rescue false
40
+ end
41
+
42
+ def delete(id)
43
+ return CiscoWebex::RestCC.delete(@auth_token, "/organization/#{@org_id}/entry-point/#{id}") rescue false
44
+ end
45
+
46
+ def update(id, params)
47
+ return CiscoWebex::RestCC.put(@auth_token, "/organization/#{@org_id}/entry-point/#{id}", params) rescue false
48
+ end
49
+
50
+ def patch(id, params)
51
+ return CiscoWebex::RestCC.patch(@auth_token, "/organization/#{@org_id}/entry-point/#{id}", params) rescue false
52
+ end
53
+ end
54
+ end
55
+
@@ -0,0 +1,41 @@
1
+ module CiscoWebex
2
+ class Actions < Journey
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ def initialize(token=nil, org_id=nil)
7
+ if token == nil || org_id == nil
8
+ STDERR.puts "Must provde token and org_idwhen initiating CiscoWebex::CC::Journey::Action"
9
+ return false
10
+ else
11
+ @org_id = org_id
12
+ @auth_token = token
13
+ end
14
+ end
15
+
16
+ def this()
17
+ puts "CiscoWebex::CC::Journey::Action - Org:#{@org_id}"
18
+ end
19
+
20
+ def get(id)
21
+ return CiscoWebex::RestCC.get(@auth_token, "/v1/journey/actions/#{id}")['data']
22
+ end
23
+
24
+ def list()
25
+ return CiscoWebex::RestCC.get(@auth_token, "/v1/journey/actions")['data']
26
+ end
27
+
28
+ def search(params={})
29
+ params = { "name"=> params } if params.class == String
30
+ return CiscoWebex::Toolbox.search(list(), params)
31
+ end
32
+
33
+ def create(params)
34
+ return CiscoWebex::RestCC.post(@auth_token, "/v1/journey/actions", params)['data']
35
+ end
36
+
37
+ def delete(id)
38
+ return CiscoWebex::RestCC.delete(@auth_token, "/v1/journey/actions/#{id}")['data']
39
+ end
40
+ end
41
+ end
@@ -0,0 +1,28 @@
1
+ module CiscoWebex
2
+ class Aliases < Journey
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ def initialize(token=nil, org_id=nil)
7
+ if token == nil || org_id == nil
8
+ STDERR.puts "Must provde token and org_idwhen initiating CiscoWebex::CC::Journey::Alias"
9
+ return false
10
+ else
11
+ @org_id = org_id
12
+ @auth_token = token
13
+ end
14
+ end
15
+
16
+ def this()
17
+ puts "CiscoWebex::CC::Journey::Alias - Org:#{@org_id}"
18
+ end
19
+
20
+ def delete(id)
21
+ return CiscoWebex::RestCC.delete(@auth_token, "/v1/journey/identities/#{id}/aliases")
22
+ end
23
+
24
+ def create(id, params)
25
+ return CiscoWebex::RestCC.post(@auth_token, "/v1/journey/identities/#{id}/aliases", params)
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,37 @@
1
+ module CiscoWebex
2
+ class JourneyEvents < Journey
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ def initialize(token=nil, org_id=nil)
7
+ if token == nil || org_id == nil
8
+ STDERR.puts "Must provde token and org_idwhen initiating CiscoWebex::CC::Journey::Event"
9
+ return false
10
+ else
11
+ @org_id = org_id
12
+ @auth_token = token
13
+ end
14
+ end
15
+
16
+ def this()
17
+ puts "CiscoWebex::CC::Journey::Event - Org:#{@org_id}"
18
+ end
19
+
20
+ def get()
21
+ return CiscoWebex::RestCC.get(@auth_token, "/v1/journey/events/")['data']
22
+ end
23
+
24
+ def list()
25
+ return CiscoWebex::RestCC.get(@auth_token, "/v1/journey/events")['data']
26
+ end
27
+
28
+ def search(params={})
29
+ params = { "type"=> params } if params.class == String
30
+ return CiscoWebex::Toolbox.search(list(), params)
31
+ end
32
+
33
+ def create(params)
34
+ return CiscoWebex::RestCC.post(@auth_token, "/v1/journey/events", params)
35
+ end
36
+ end
37
+ end
@@ -0,0 +1,41 @@
1
+ module CiscoWebex
2
+ class Identities < Journey
3
+ @auth_token = nil
4
+ @org_id = nil
5
+
6
+ def initialize(token=nil, org_id=nil)
7
+ if token == nil || org_id == nil
8
+ STDERR.puts "Must provde token and org_idwhen initiating CiscoWebex::CC::Journey::Identity"
9
+ return false
10
+ else
11
+ @org_id = org_id
12
+ @auth_token = token
13
+ end
14
+ end
15
+
16
+ def this()
17
+ puts "CiscoWebex::CC::Journey::Identity - Org:#{@org_id}"
18
+ end
19
+
20
+ def get(id)
21
+ return CiscoWebex::RestCC.get(@auth_token, "/v1/journey/identities/#{id}")['data']
22
+ end
23
+
24
+ def list()
25
+ return CiscoWebex::RestCC.get(@auth_token, "/v1/journey/identities")['data']
26
+ end
27
+
28
+ def search(params={})
29
+ params = { "id"=> params } if params.class == String
30
+ return CiscoWebex::Toolbox.search(list(), params)
31
+ end
32
+
33
+ def delete(id)
34
+ return CiscoWebex::RestCC.delete(@auth_token, "/v1/journey/identities/#{id}")
35
+ end
36
+
37
+ def create(params)
38
+ return CiscoWebex::RestCC.post(@auth_token, "/v1/journey/identities", params)
39
+ end
40
+ end
41
+ end