Wiki source code of Live API

Last modified by michaely on 2021/09/10 23:34

Show last authors
1 {{layout}}
2 {{layout-section ac:type="two_right_sidebar"}}
3 {{layout-cell}}
4 {{warning}}
5 This page is currently being written. Although the information below is probably accurate, it may not be complete or may have errors.
6 {{/warning}}
7
8 {{info}}
9 The information on this page applies to **iSymphony 3.2+**.
10 {{/info}}
11
12 = (% style="color: rgb(0,0,0);" %)Description(%%) =
13
14 The Live API provides information about the real time state of the iSymphony server, and exposes resources used to execute actions, via a HTTP REST interface. This API can be used to integrate external applications with iSymphony, by providing live information about users and call state in the system, and at the same time allowing those applications to preform actions. The information and actions provided are similar to those found in the client interface. In conjunction with the CRM Widget, this API can also be used to create custom widgets for the iSymphony client interface.
15 {{/layout-cell}}
16
17 {{layout-cell}}
18 {{panel title="On this page:"}}
19
20
21 {{toc maxLevel="2" indent="1"/}}
22 {{/panel}}
23 {{/layout-cell}}
24 {{/layout-section}}
25
26 {{layout-section ac:type="single"}}
27 {{layout-cell}}
28 = Resource Instance IDs =
29
30 Every instance of a REST resource specifies a UUID, that serves as a unique identifier for that specific instance of the resource. These UUIDs can be used in REST URLs to access a specific instance of a resource. These UUIDs are the same ids that are used to identify objects in the [[Event API>>doc:WebSocket API Documentation (Event)]], allowing collaboration between the Live REST API and the Event API.
31
32 For example, the URL below provides access to an extension instance with a UUID of ef2faba9-8557-49c1-9ffc-5a71f41c7a23, in a core server with a UUID of ca5de6c4-17bd-46ce-95a2-8b29c7812ca4:
33
34 {{code}}
35 http://localhost:58080/communication_manager/rest/live/coreServers/ca5de6c4-17bd-46ce-95a2-8b29c7812ca4/extensions/ef2faba9-8557-49c1-9ffc-5a71f41c7a23
36 {{/code}}
37
38 {{note title="Note on UUID persistance"}}
39 The UUIDs do not persist across restarts of the iSymphony server. If the server is restarted, the objects will contain new UUIDs. Also, if an object is destroyed then re-added, even with the same configuration, the UUID that represents that object will be different from the original.
40 {{/note}}
41
42 = Configuration IDs =
43
44 Some resource instances will provide configuration ids, that specify the id of the configuration object that is related to the live object. These are the same ids used to access resources in the [[REST Configuration API>>doc:Configuration API]], allowing collaboration between the REST Live API and the REST Configuration API.
45
46 = Accessing Resource Instances By Symbolic Name =
47
48 In addition to accessing resource instances by UUID, resource instances can also be accessed by their symbolic name. Most, but not all resources contain a symbolic name. The path section **getByName** can be used to access a resource instance by it symbolic name. Documentation for a specific resource will specify, if the resource can be accessed by symbolic name, and what the symbolic name property is.
49
50 == Examples ==
51
52 The following path will access an extension with extension number 4224, in a core server with a slug of default.
53
54 {{code}}
55 http://localhost:58080/communication_manager/rest/live/coreServers/getByName/default/extensions/getByName/4224
56 {{/code}}
57
58 \\
59
60 You can mix and match UUIDs and getByName in the REST URLs, like so:
61
62 {{code}}
63 http://localhost:58080/communication_manager/rest/live/coreServers/getByName/default/extensions/ef2faba9-8557-49c1-9ffc-5a71f41c7a23
64 {{/code}}
65
66 == Document Notation ==
67
68 When a parent resource path can be access by UUID and getByName, the path in the documentation will specify the following format:
69
70 {{code}}
71 [{UUID} | getByName/{symbolic_name}]
72 {{/code}}
73
74 This specifies that the instance can be accessed via "UUID" OR "getByName/symbolic_name". {UUID} and {symbolic_name} will be replaced with more specific names.
75
76 = REST Resources =
77
78 The Live API exposes several REST resources, that allow access to the current state of specific objects in the system. All current live resources are listed below. Details concerning each resource, and their actions, can be found within the individual resource documentation pages.
79
80 == Resource List ==
81
82
83
84 {{children/}}
85
86 == Notes on Resource Documentation ==
87
88 Due to the interdependent nature of resources in the system, the resource path information in the documentation is split into several sections. Paths in a specific section may relate to, or require, paths specified in other sections.
89
90 * **Root Resource Paths : **Specifies paths that can be used to access sets (multiple instances) of a resource, in relation to a parent resource.
91 * **Instance Resource Paths : **Specifies paths that can be used to access a specific instance of a resource. These paths require a **Root Resource Path**, in most cases, but not all.
92 * **Sub Resource Paths : **Specifies paths that provide access to the child resources, of a specific resource instance. These paths require an **Instance Resource Path.**
93 * **Action Paths: **Specifies paths that are used to perform actions on a specific resource instance. These paths require an **Instance Resource Path.**
94
95 \\
96 {{/layout-cell}}
97 {{/layout-section}}
98 {{/layout}}
iSymphony