Wiki source code of Licensing

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.1+**.
10 {{/info}}
11
12 = (% style="color: rgb(0,0,0);" %)Description(%%) =
13
14 The license REST resource allows access to the license of a specific core server instance. This resource allows activating licenses.
15
16
17 {{/layout-cell}}
18
19 {{layout-cell}}
20 {{panel title="On this page:"}}
21
22
23 {{toc maxLevel="2" indent="1"/}}
24 {{/panel}}
25 {{/layout-cell}}
26 {{/layout-section}}
27
28 {{layout-section ac:type="single"}}
29 {{layout-cell}}
30 = (% style="color: rgb(0,0,0);" %)Root Resource Path(%%) =
31
32 {{code}}
33 communication_manager/rest/config/server/coreServers/[{id} | getByName/{slug}]/license
34 {{/code}}
35
36 = JSON Representation =
37
38 {{code}}
39 {
40 "id": "8a2632b3-dc9e-4d66-a759-14d347a73b28",
41 "serial": "<serial key>",
42 "type": "PERPETUAL",
43 "licensedTo": "Mike",
44 "expirationDate": 1459749600000,
45 "maintenanceExpirationDate": 1459749600000,
46 "clientConnections": -1,
47 "configuredUsers": -1
48 }
49 {{/code}}
50
51 |=(((
52 Property
53 )))|=(((
54 Type
55 )))|=(((
56 Description
57 )))
58 |(((
59 {{{id}}}
60 )))|(((
61 String
62 )))|(((
63 Configuration id of the license.
64 )))
65 |(% colspan="1" %)(% colspan="1" %)
66 (((
67 serial
68 )))|(% colspan="1" %)(% colspan="1" %)
69 (((
70 String
71 )))|(% colspan="1" %)(% colspan="1" %)
72 (((
73 The serial key of the license.
74 )))
75 |(% colspan="1" %)(% colspan="1" %)
76 (((
77 {{{expirationDate}}}
78 )))|(% colspan="1" %)(% colspan="1" %)
79 (((
80 Long
81 )))|(% colspan="1" %)(% colspan="1" %)
82 (((
83 The expiration date of the license. Represented as a Unix timestamp in milliseconds. Set to null if the license does not expire.
84 )))
85 |(% colspan="1" %)(% colspan="1" %)
86 (((
87 {{{maintenanceExpirationDate}}}
88 )))|(% colspan="1" %)(% colspan="1" %)
89 (((
90 Long
91 )))|(% colspan="1" %)(% colspan="1" %)
92 (((
93 The maintenance expiration date of the license. Represented as a Unix timestamp in milliseconds.
94 )))
95 |(% colspan="1" %)(% colspan="1" %)
96 (((
97 {{{clientConnections}}}
98 )))|(% colspan="1" %)(% colspan="1" %)
99 (((
100 Integer
101 )))|(% colspan="1" %)(% colspan="1" %)
102 (((
103 The number of concurrent client logins allowed. -1 allows infinite logins. This is not currently used by the licensing system.
104 )))
105 |(% colspan="1" %)(% colspan="1" %)
106 (((
107 {{{configuredUsers}}}
108 )))|(% colspan="1" %)(% colspan="1" %)
109 (((
110 Integer
111 )))|(% colspan="1" %)(% colspan="1" %)
112 (((
113 The number of users allowed to be marked as enabled. -1 allows infinite enabled users. This is not currently used by the licensing system.
114 )))
115
116 = Resource Paths =
117
118 |=(% colspan="2" %)(% colspan="2" %)
119 (((
120 {{{communication_manager/rest/config/server/coreServers/[{id} | getByName/{slug}]/license}}}
121 )))
122 |(% class="highlight-grey" data-highlight-colour="grey" %)(% class="highlight-grey" data-highlight-colour="grey" %)
123 (((
124 **Description**
125 )))|(((
126 Accesses the license for the core server instance.
127 )))
128 |(% class="highlight-grey" data-highlight-colour="grey" %)(% class="highlight-grey" data-highlight-colour="grey" %)
129 (((
130 **GET**
131 )))|(((
132 Gets the license for the core server instance.
133 )))
134 |(% colspan="2" %)(% colspan="2" %)
135 (((
136
137 )))
138 |=(% colspan="2" %)(% colspan="2" %)
139 (((
140 {{{communication_manager/rest/config/server/coreServers/[{id} | getByName/{slug}]/license/activate}}}
141 )))
142 |(% class="highlight-grey" colspan="1" data-highlight-colour="grey" %)(% class="highlight-grey" colspan="1" data-highlight-colour="grey" %)
143 (((
144 **Description**
145 )))|(% colspan="1" %)(% colspan="1" %)
146 (((
147 Allows activation of a license on a core server instance.
148 )))
149 |(% class="highlight-grey" colspan="1" data-highlight-colour="grey" %)(% class="highlight-grey" colspan="1" data-highlight-colour="grey" %)
150 (((
151 **POST
152 **
153 )))|(% colspan="1" %)(% colspan="1" %)
154 (((
155 Activates a license on the core server instance.
156
157 {{note}}
158 If you are binding a license to a new server, this action will return a 403 Temporary Redirect. You need to make another REST call to the URL specified in the Location header of the response, with the additional information to complete the activation. See the **bind** resource below.
159
160 The bind request will timeout after 5 seconds.
161 {{/note}}
162
163 (% style="line-height: 1.42857;" %)**Errors:**
164
165 * 403: Returned if the license activation was denied.
166 * 307: A bind authorization was requested in order to complete the activation.
167 )))
168 |(% colspan="2" %)(% colspan="2" %)
169 (((
170
171 )))
172 |=(% colspan="2" %)(% colspan="2" %)
173 (((
174 {{{communication_manager/rest/config/server/coreServers/[{id} | getByName/{slug}]/license/bind/{serial}}}}
175 )))
176 |(% class="highlight-grey" data-highlight-colour="grey" %)(% class="highlight-grey" data-highlight-colour="grey" %)
177 (((
178 **Description**
179 )))|(((
180 Completes a license activation by providing the bind authorization.
181
182 **Parameters:**
183
184 * serial: The serial key of the license to complete the activation for.
185 )))
186 |(% class="highlight-grey" data-highlight-colour="grey" %)(% class="highlight-grey" data-highlight-colour="grey" %)
187 (((
188 **POST**
189 )))|(((
190 Completes a license activation. The following JSON must be passed to the resource:
191
192 {{code language="js"}}
193 {
194 "cancel": false,
195 "licensedTo": "Michael Yara",
196 "email": "me@mydomain.com"
197 }
198 {{/code}}
199
200 |=(((
201 Property
202 )))|=(((
203 Type
204 )))|=(((
205 Description
206 )))
207 |(((
208 cancel
209 )))|(((
210 Boolean
211 )))|(((
212 Set to true if you wish to cancle the bind request. Normally you will have this set to false.
213 )))
214 |(((
215 licensedTo
216 )))|(((
217 String
218 )))|(((
219 The name of the person or company name that owns the license.
220 )))
221 |(((
222 email
223 )))|(((
224 String
225 )))|(((
226 The email address of the person or company that owns the license.
227 )))
228
229 (% style="line-height: 1.42857;" %)**Errors:**
230
231 * 403: Returned if the license activation was denied.
232 )))
233
234 = Sub/Child Resource Paths =
235
236 |=(% colspan="2" %)(% colspan="2" %)
237 (((
238 {{{communication_manager/rest/config/server/coreServers/[{id} | getByName/{slug}]/license/moduleLicenses}}}
239 )))
240 |(% class="highlight-grey" colspan="1" data-highlight-colour="grey" %)(% class="highlight-grey" colspan="1" data-highlight-colour="grey" %)
241 (((
242 **Description**
243 )))|(% colspan="1" %)(% colspan="1" %)
244 (((
245 Access the sub/child resource for specifics of the license properties for each module in the system.
246
247 See [[doc:Module Licenses]] for more information.
248 )))
249
250 = Curl Examples =
251
252 === Get the license for the core server ===
253
254 {{code language="bash"}}
255 curl --user manager:manag3rpa55word -k -i -H "Accept: application/json" http://localhost:58080/communication_manager/rest/config/server/coreServers/bb8404fb-95b6-474c-b30e-0975283ea692/license
256 {{/code}}
257
258 === Activate a license ===
259
260 {{code language="bash"}}
261 curl --user manager:manag3rpa55word -k -i -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d '<serial>' http://localhost:58080/communication_manager/rest/config/server/coreServers/bb8404fb-95b6-474c-b30e-0975283ea692/license/activate
262 {{/code}}
263
264 Replace **<serial>** with your license serial key.
265
266 === Complete a bind authorization ===
267
268 {{code language="bash"}}
269 curl --user manager:manag3rpa55word -k -i -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d '{"cancel": false, "licensedTo": "Michael Yara", "email": "me@mydomain.com"}' http://localhost:58080/communication_manager/rest/config/server/coreServers/bb8404fb-95b6-474c-b30e-0975283ea692/license/bind/<serial>
270 {{/code}}
271
272 Replace **<serial>** with your license serial key.
273 {{/layout-cell}}
274 {{/layout-section}}
275 {{/layout}}
iSymphony