Skip to content

Commit e233c67

Browse files
author
InIn Devops
committed
6.1.5
1 parent dc6ea30 commit e233c67

83 files changed

Lines changed: 2683 additions & 96 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ npm install purecloud-platform-client-v2
2525
Reference from the CDN:
2626

2727
~~~ html
28-
<!-- Replace `6.1.4` with the version you want to use. -->
29-
<script src="https://sdk-cdn.mypurecloud.com/javascript/6.1.4/purecloud-platform-client-v2.min.js"></script>
28+
<!-- Replace `6.1.5` with the version you want to use. -->
29+
<script src="https://sdk-cdn.mypurecloud.com/javascript/6.1.5/purecloud-platform-client-v2.min.js"></script>
3030
~~~
3131

3232
View the documentation on the [PureCloud Developer Center](https://developer.mypurecloud.com/api/rest/client-libraries/javascript/).
@@ -50,7 +50,7 @@ Reference the SDK in your HTML document. For convenience, all modules are bundle
5050
Require the SDK in your node app. All modules are obtained from the `purecloud-platform-client-v2` package.
5151

5252
~~~ javascript
53-
const platformClient = require('platformClient');
53+
const platformClient = require('purecloud-platform-client-v2');
5454
~~~
5555

5656

@@ -63,7 +63,7 @@ After authentication has completed, the access token is stored on the `ApiClient
6363
The Client Credentials grant only works when used in node.js. This is restricted intentionally because it is impossible for client credentials to be handled securely in a browser application.
6464

6565
~~~ javascript
66-
const platformClient = require('platformClient');
66+
const platformClient = require('purecloud-platform-client-v2');
6767
var client = platformClient.ApiClient.instance;
6868
client.loginClientCredentialsGrant(clientId, clientSecret)
6969
.then(function() {
@@ -95,7 +95,11 @@ client.loginImplicitGrant(clientId, redirectUri)
9595
**Any platform** Provide an existing auth token
9696

9797
~~~ javascript
98+
// Browser
9899
const platformClient = require('platformClient');
100+
// Node
101+
const platformClient = require('purecloud-platform-client-v2');
102+
99103
var client = platformClient.ApiClient.instance;
100104
client.setAccessToken(yourAccessToken);
101105
// Do authenticated things; no login function needed
@@ -107,7 +111,11 @@ client.setAccessToken(yourAccessToken);
107111
If connecting to a PureCloud environment other than mypurecloud.com (e.g. mypurecloud.ie), set the environment on the `ApiClient` instance.
108112

109113
~~~ js
114+
// Browser
110115
const platformClient = require('platformClient');
116+
// Node
117+
const platformClient = require('purecloud-platform-client-v2');
118+
111119
var client = platformClient.ApiClient.instance;
112120
client.setEnvironment('mypurecloud.ie');
113121
~~~
@@ -131,6 +139,8 @@ All API requests return a Promise which resolves to the response body, otherwise
131139
**Node.js**
132140

133141
~~~ js
142+
const platformClient = require('purecloud-platform-client-v2');
143+
134144
// Create API instance
135145
var authorizationApi = new platformClient.AuthorizationApi();
136146

@@ -154,6 +164,8 @@ client.loginClientCredentialsGrant(clientId, clientSecret)
154164
**Web**
155165

156166
~~~ js
167+
const platformClient = require('platformClient');
168+
157169
// Create API instance
158170
var usersApi = new platformClient.UsersApi();
159171

@@ -180,7 +192,11 @@ client.loginImplicitGrant(clientId, redirectUri)
180192
By default, the SDK will return only the response body as the result of an API function call. To retrieve additional information about the response, enable extended responses. This will return the extended response for all API function calls:
181193

182194
~~~ js
195+
// Browser
183196
const platformClient = require('platformClient');
197+
// Node
198+
const platformClient = require('purecloud-platform-client-v2');
199+
184200
var client = purecloud-platform-client-v2.ApiClient.instance;
185201
client.setReturnExtendedResponses(true);
186202
~~~
@@ -249,7 +265,11 @@ Example error response object:
249265
There are hooks to trace requests and responses. To enable debug tracing, provide a log object. Optionally, specify a maximum number of lines. If specified, the response body trace will be truncated. If not specified, the entire response body will be traced out.
250266

251267
~~~ js
268+
// Browser
252269
const platformClient = require('platformClient');
270+
// Node
271+
const platformClient = require('purecloud-platform-client-v2');
272+
253273
var client = purecloud-platform-client-v2.ApiClient.instance;
254274
client.setDebugLog(console.log, 25);
255275
~~~

build/README.md

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ npm install purecloud-platform-client-v2
2525
Reference from the CDN:
2626

2727
~~~ html
28-
<!-- Replace `6.1.4` with the version you want to use. -->
29-
<script src="https://sdk-cdn.mypurecloud.com/javascript/6.1.4/purecloud-platform-client-v2.min.js"></script>
28+
<!-- Replace `6.1.5` with the version you want to use. -->
29+
<script src="https://sdk-cdn.mypurecloud.com/javascript/6.1.5/purecloud-platform-client-v2.min.js"></script>
3030
~~~
3131

3232
View the documentation on the [PureCloud Developer Center](https://developer.mypurecloud.com/api/rest/client-libraries/javascript/).
@@ -50,7 +50,7 @@ Reference the SDK in your HTML document. For convenience, all modules are bundle
5050
Require the SDK in your node app. All modules are obtained from the `purecloud-platform-client-v2` package.
5151

5252
~~~ javascript
53-
const platformClient = require('platformClient');
53+
const platformClient = require('purecloud-platform-client-v2');
5454
~~~
5555

5656

@@ -63,7 +63,7 @@ After authentication has completed, the access token is stored on the `ApiClient
6363
The Client Credentials grant only works when used in node.js. This is restricted intentionally because it is impossible for client credentials to be handled securely in a browser application.
6464

6565
~~~ javascript
66-
const platformClient = require('platformClient');
66+
const platformClient = require('purecloud-platform-client-v2');
6767
var client = platformClient.ApiClient.instance;
6868
client.loginClientCredentialsGrant(clientId, clientSecret)
6969
.then(function() {
@@ -95,7 +95,11 @@ client.loginImplicitGrant(clientId, redirectUri)
9595
**Any platform** Provide an existing auth token
9696

9797
~~~ javascript
98+
// Browser
9899
const platformClient = require('platformClient');
100+
// Node
101+
const platformClient = require('purecloud-platform-client-v2');
102+
99103
var client = platformClient.ApiClient.instance;
100104
client.setAccessToken(yourAccessToken);
101105
// Do authenticated things; no login function needed
@@ -107,7 +111,11 @@ client.setAccessToken(yourAccessToken);
107111
If connecting to a PureCloud environment other than mypurecloud.com (e.g. mypurecloud.ie), set the environment on the `ApiClient` instance.
108112

109113
~~~ js
114+
// Browser
110115
const platformClient = require('platformClient');
116+
// Node
117+
const platformClient = require('purecloud-platform-client-v2');
118+
111119
var client = platformClient.ApiClient.instance;
112120
client.setEnvironment('mypurecloud.ie');
113121
~~~
@@ -131,6 +139,8 @@ All API requests return a Promise which resolves to the response body, otherwise
131139
**Node.js**
132140

133141
~~~ js
142+
const platformClient = require('purecloud-platform-client-v2');
143+
134144
// Create API instance
135145
var authorizationApi = new platformClient.AuthorizationApi();
136146

@@ -154,6 +164,8 @@ client.loginClientCredentialsGrant(clientId, clientSecret)
154164
**Web**
155165

156166
~~~ js
167+
const platformClient = require('platformClient');
168+
157169
// Create API instance
158170
var usersApi = new platformClient.UsersApi();
159171

@@ -180,7 +192,11 @@ client.loginImplicitGrant(clientId, redirectUri)
180192
By default, the SDK will return only the response body as the result of an API function call. To retrieve additional information about the response, enable extended responses. This will return the extended response for all API function calls:
181193

182194
~~~ js
195+
// Browser
183196
const platformClient = require('platformClient');
197+
// Node
198+
const platformClient = require('purecloud-platform-client-v2');
199+
184200
var client = purecloud-platform-client-v2.ApiClient.instance;
185201
client.setReturnExtendedResponses(true);
186202
~~~
@@ -249,7 +265,11 @@ Example error response object:
249265
There are hooks to trace requests and responses. To enable debug tracing, provide a log object. Optionally, specify a maximum number of lines. If specified, the response body trace will be truncated. If not specified, the entire response body will be traced out.
250266

251267
~~~ js
268+
// Browser
252269
const platformClient = require('platformClient');
270+
// Node
271+
const platformClient = require('purecloud-platform-client-v2');
272+
253273
var client = purecloud-platform-client-v2.ApiClient.instance;
254274
client.setDebugLog(console.log, 25);
255275
~~~

build/docs/AlertingApi.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,10 @@ Delete an interaction stats alert
3232
### Example
3333

3434
~~~ javascript
35+
// Browser
3536
const platformClient = require('platformClient');
37+
// Node
38+
const platformClient = require('purecloud-platform-client-v2');
3639

3740
// Configure OAuth2 access token for authorization: PureCloud Auth
3841
platformClient.ApiClient.instance.authentications['PureCloud Auth'].accessToken = 'YOUR ACCESS TOKEN';
@@ -77,7 +80,10 @@ Delete an interaction stats rule.
7780
### Example
7881

7982
~~~ javascript
83+
// Browser
8084
const platformClient = require('platformClient');
85+
// Node
86+
const platformClient = require('purecloud-platform-client-v2');
8187

8288
// Configure OAuth2 access token for authorization: PureCloud Auth
8389
platformClient.ApiClient.instance.authentications['PureCloud Auth'].accessToken = 'YOUR ACCESS TOKEN';
@@ -122,7 +128,10 @@ Get an interaction stats alert
122128
### Example
123129

124130
~~~ javascript
131+
// Browser
125132
const platformClient = require('platformClient');
133+
// Node
134+
const platformClient = require('purecloud-platform-client-v2');
126135

127136
// Configure OAuth2 access token for authorization: PureCloud Auth
128137
platformClient.ApiClient.instance.authentications['PureCloud Auth'].accessToken = 'YOUR ACCESS TOKEN';
@@ -171,7 +180,10 @@ Get interaction stats alert list.
171180
### Example
172181

173182
~~~ javascript
183+
// Browser
174184
const platformClient = require('platformClient');
185+
// Node
186+
const platformClient = require('purecloud-platform-client-v2');
175187

176188
// Configure OAuth2 access token for authorization: PureCloud Auth
177189
platformClient.ApiClient.instance.authentications['PureCloud Auth'].accessToken = 'YOUR ACCESS TOKEN';
@@ -217,7 +229,10 @@ Gets user unread count of interaction stats alerts.
217229
### Example
218230

219231
~~~ javascript
232+
// Browser
220233
const platformClient = require('platformClient');
234+
// Node
235+
const platformClient = require('purecloud-platform-client-v2');
221236

222237
// Configure OAuth2 access token for authorization: PureCloud Auth
223238
platformClient.ApiClient.instance.authentications['PureCloud Auth'].accessToken = 'YOUR ACCESS TOKEN';
@@ -256,7 +271,10 @@ Get an interaction stats rule.
256271
### Example
257272

258273
~~~ javascript
274+
// Browser
259275
const platformClient = require('platformClient');
276+
// Node
277+
const platformClient = require('purecloud-platform-client-v2');
260278

261279
// Configure OAuth2 access token for authorization: PureCloud Auth
262280
platformClient.ApiClient.instance.authentications['PureCloud Auth'].accessToken = 'YOUR ACCESS TOKEN';
@@ -305,7 +323,10 @@ Get an interaction stats rule list.
305323
### Example
306324

307325
~~~ javascript
326+
// Browser
308327
const platformClient = require('platformClient');
328+
// Node
329+
const platformClient = require('purecloud-platform-client-v2');
309330

310331
// Configure OAuth2 access token for authorization: PureCloud Auth
311332
platformClient.ApiClient.instance.authentications['PureCloud Auth'].accessToken = 'YOUR ACCESS TOKEN';
@@ -351,7 +372,10 @@ Create an interaction stats rule.
351372
### Example
352373

353374
~~~ javascript
375+
// Browser
354376
const platformClient = require('platformClient');
377+
// Node
378+
const platformClient = require('purecloud-platform-client-v2');
355379

356380
// Configure OAuth2 access token for authorization: PureCloud Auth
357381
platformClient.ApiClient.instance.authentications['PureCloud Auth'].accessToken = 'YOUR ACCESS TOKEN';
@@ -400,7 +424,10 @@ Update an interaction stats alert read status
400424
### Example
401425

402426
~~~ javascript
427+
// Browser
403428
const platformClient = require('platformClient');
429+
// Node
430+
const platformClient = require('purecloud-platform-client-v2');
404431

405432
// Configure OAuth2 access token for authorization: PureCloud Auth
406433
platformClient.ApiClient.instance.authentications['PureCloud Auth'].accessToken = 'YOUR ACCESS TOKEN';
@@ -452,7 +479,10 @@ Update an interaction stats rule
452479
### Example
453480

454481
~~~ javascript
482+
// Browser
455483
const platformClient = require('platformClient');
484+
// Node
485+
const platformClient = require('purecloud-platform-client-v2');
456486

457487
// Configure OAuth2 access token for authorization: PureCloud Auth
458488
platformClient.ApiClient.instance.authentications['PureCloud Auth'].accessToken = 'YOUR ACCESS TOKEN';

0 commit comments

Comments
 (0)