comprodls-sdk 2.89.0 → 2.90.0-qa
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.
- package/README.md +1 -137
- package/dist/comprodls-sdk.js +5937 -8432
- package/dist/comprodls-sdk.min.js +15 -1
- package/lib/comprodls.js +39 -57
- package/lib/config/index.js +171 -199
- package/lib/helpers/index.js +3 -2
- package/lib/helpers/lib/api/converter.js +1 -2
- package/lib/helpers/lib/api/index.js +19 -94
- package/lib/helpers/lib/errors.js +73 -80
- package/lib/helpers/lib/requestLayer.js +154 -0
- package/lib/helpers/lib/validator.js +65 -52
- package/lib/open_access/index.js +48 -53
- package/lib/services/analytics/index.js +286 -1014
- package/lib/services/attempts/index.js +38 -88
- package/lib/services/auth/index.js +238 -896
- package/lib/services/authextn/index.js +50 -150
- package/lib/services/datasyncmanager/index.js +10 -45
- package/lib/services/drive/index.js +20 -83
- package/lib/services/integrations/index.js +51 -126
- package/lib/services/invitations/index.js +20 -61
- package/lib/services/product/index.js +74 -85
- package/lib/services/pub/index.js +159 -234
- package/lib/services/pushX/index.js +29 -33
- package/lib/services/pushX/pubnubClientWrapper.js +398 -398
- package/lib/services/rules/index.js +14 -67
- package/lib/services/spaces/index.js +106 -294
- package/lib/services/spacesextn/index.js +4 -24
- package/lib/services/superuser/index.js +21 -36
- package/lib/services/taxonomy/index.js +27 -57
- package/lib/services/workflows/index.js +37 -98
- package/lib/services/xapi/index.js +6 -125
- package/lib/token/index.js +73 -67
- package/lib/token/validations.js +45 -48
- package/package.json +1 -2
- package/lib/helpers/lib/api/validations.js +0 -73
- package/lib/helpers/lib/utils.js +0 -24
- package/lib/services/activity/activity.js +0 -209
- package/lib/services/activity/attempt.js +0 -431
- package/lib/services/activity/index.js +0 -28
- package/lib/services/auth/classProduct.js +0 -37
- package/lib/services/collab/index.js +0 -468
|
@@ -30,9 +30,6 @@ var Agent = require('agentkeepalive');
|
|
|
30
30
|
|
|
31
31
|
var DLSError = helpers.errors.DLSError;
|
|
32
32
|
|
|
33
|
-
/*********************************
|
|
34
|
-
* Setting Up Module Entry Point
|
|
35
|
-
**********************************/
|
|
36
33
|
module.exports = authextn;
|
|
37
34
|
|
|
38
35
|
var keepaliveAgent = new Agent({
|
|
@@ -75,21 +72,10 @@ function authextn() {
|
|
|
75
72
|
* Public Function definitions
|
|
76
73
|
**********************************/
|
|
77
74
|
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
grades:[ { //mandatory
|
|
83
|
-
id: "string",
|
|
84
|
-
title: "string",
|
|
85
|
-
min_threshold: "string",
|
|
86
|
-
max_threshold: "string",
|
|
87
|
-
target: boolean
|
|
88
|
-
}, ...]
|
|
89
|
-
data: {}
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
*/
|
|
75
|
+
/**
|
|
76
|
+
* Wiki Link for SDK params
|
|
77
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#creategradeformatparams
|
|
78
|
+
*/
|
|
93
79
|
function createGradeformat(options) {
|
|
94
80
|
var self = this;
|
|
95
81
|
// Initializing promise
|
|
@@ -136,21 +122,10 @@ function createGradeformat(options) {
|
|
|
136
122
|
return dfd.promise;
|
|
137
123
|
}
|
|
138
124
|
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
grades: [ {
|
|
144
|
-
id: "string",
|
|
145
|
-
title: "string",
|
|
146
|
-
min_threshold: "string",
|
|
147
|
-
max_threshold: "string",
|
|
148
|
-
target: boolean
|
|
149
|
-
}, ...]
|
|
150
|
-
data: {...}
|
|
151
|
-
}
|
|
152
|
-
}
|
|
153
|
-
*/
|
|
125
|
+
/**
|
|
126
|
+
* Wiki Link for SDK params
|
|
127
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#updategradeformatparams
|
|
128
|
+
*/
|
|
154
129
|
function updateGradeformat(options) {
|
|
155
130
|
// Initializing promise
|
|
156
131
|
var deferred = q.defer();
|
|
@@ -211,11 +186,10 @@ function updateGradeformat(options) {
|
|
|
211
186
|
return deferred.promise;
|
|
212
187
|
}
|
|
213
188
|
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
*/
|
|
189
|
+
/**
|
|
190
|
+
* Wiki Link for SDK params
|
|
191
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#deletegradeformatparams
|
|
192
|
+
*/
|
|
219
193
|
function deleteGradeformat(options) {
|
|
220
194
|
var self = this;
|
|
221
195
|
var dfd = q.defer();
|
|
@@ -261,11 +235,10 @@ function deleteGradeformat(options) {
|
|
|
261
235
|
return dfd.promise;
|
|
262
236
|
}
|
|
263
237
|
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
*/
|
|
238
|
+
/**
|
|
239
|
+
* Wiki Link for SDK params
|
|
240
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#getparticulargradeformatparams
|
|
241
|
+
*/
|
|
269
242
|
function getParticularGradeformat (options) {
|
|
270
243
|
// Initializing promise
|
|
271
244
|
var deferred = q.defer();
|
|
@@ -313,11 +286,10 @@ function getParticularGradeformat (options) {
|
|
|
313
286
|
return deferred.promise;
|
|
314
287
|
}
|
|
315
288
|
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
*/
|
|
289
|
+
/**
|
|
290
|
+
* Wiki Link for SDK params
|
|
291
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#getallgradeformatsparams
|
|
292
|
+
*/
|
|
321
293
|
function getAllGradeformats (options) {
|
|
322
294
|
// Initializing promise
|
|
323
295
|
var deferred = q.defer();
|
|
@@ -363,20 +335,8 @@ function getAllGradeformats (options) {
|
|
|
363
335
|
}
|
|
364
336
|
|
|
365
337
|
/**
|
|
366
|
-
*
|
|
367
|
-
*
|
|
368
|
-
* *gradeformat_id: 'string',
|
|
369
|
-
* *body: {
|
|
370
|
-
* *grades: [{
|
|
371
|
-
* id: 'string',
|
|
372
|
-
* title: 'string',
|
|
373
|
-
* min_threshold: 'string',
|
|
374
|
-
* max_threshold: 'string',
|
|
375
|
-
* target: <boolean>
|
|
376
|
-
* }],
|
|
377
|
-
* data: {}
|
|
378
|
-
* }
|
|
379
|
-
* } options
|
|
338
|
+
* Wiki Link for SDK params
|
|
339
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#associategradeformattoclassparams
|
|
380
340
|
*/
|
|
381
341
|
function associateGradeformatToClass(options) {
|
|
382
342
|
var self = this;
|
|
@@ -432,10 +392,8 @@ function associateGradeformatToClass(options) {
|
|
|
432
392
|
}
|
|
433
393
|
|
|
434
394
|
/**
|
|
435
|
-
*
|
|
436
|
-
*
|
|
437
|
-
* *gradeformat_id: 'string'
|
|
438
|
-
* } options
|
|
395
|
+
* Wiki Link for SDK params
|
|
396
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#unassociategradeformatfromclassparams
|
|
439
397
|
*/
|
|
440
398
|
function unassociateGradeformatFromClass(options) {
|
|
441
399
|
var self = this;
|
|
@@ -487,20 +445,8 @@ function unassociateGradeformatFromClass(options) {
|
|
|
487
445
|
}
|
|
488
446
|
|
|
489
447
|
/**
|
|
490
|
-
*
|
|
491
|
-
*
|
|
492
|
-
* *gradeformat_id: 'string',
|
|
493
|
-
* *body: {
|
|
494
|
-
* grades: [{
|
|
495
|
-
* id: 'string',
|
|
496
|
-
* title: 'string',
|
|
497
|
-
* min_threshold: 'string',
|
|
498
|
-
* max_threshold: 'string',
|
|
499
|
-
* target: <boolean>
|
|
500
|
-
* }],
|
|
501
|
-
* data: {}
|
|
502
|
-
* }
|
|
503
|
-
* } options
|
|
448
|
+
* Wiki Link for SDK params
|
|
449
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#updateclassgradeformatassociationparams
|
|
504
450
|
*/
|
|
505
451
|
function updateClassGradeformatAssociation(options) {
|
|
506
452
|
var self = this;
|
|
@@ -556,10 +502,8 @@ function updateClassGradeformatAssociation(options) {
|
|
|
556
502
|
}
|
|
557
503
|
|
|
558
504
|
/**
|
|
559
|
-
*
|
|
560
|
-
*
|
|
561
|
-
* *gradeformat_id: 'string'
|
|
562
|
-
* } options
|
|
505
|
+
* Wiki Link for SDK params
|
|
506
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#getparticulargradeformatofaclassparams
|
|
563
507
|
*/
|
|
564
508
|
function getParticularGradeformatOfAClass(options) {
|
|
565
509
|
var self = this;
|
|
@@ -610,10 +554,8 @@ function getParticularGradeformatOfAClass(options) {
|
|
|
610
554
|
}
|
|
611
555
|
|
|
612
556
|
/**
|
|
613
|
-
*
|
|
614
|
-
*
|
|
615
|
-
* cursor: 'string'
|
|
616
|
-
* } options
|
|
557
|
+
* Wiki Link for SDK params
|
|
558
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#getallgradeformatsofaclassparams
|
|
617
559
|
*/
|
|
618
560
|
function getAllGradeformatsOfAClass(options) {
|
|
619
561
|
var self = this;
|
|
@@ -666,10 +608,8 @@ function getAllGradeformatsOfAClass(options) {
|
|
|
666
608
|
}
|
|
667
609
|
|
|
668
610
|
/**
|
|
669
|
-
*
|
|
670
|
-
*
|
|
671
|
-
* cursor: 'string'
|
|
672
|
-
* } options
|
|
611
|
+
* Wiki Link for SDK params
|
|
612
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#getclassesofagradeformatparams
|
|
673
613
|
*/
|
|
674
614
|
function getClassesOfAGradeformat(options) {
|
|
675
615
|
var self = this;
|
|
@@ -722,21 +662,10 @@ function getClassesOfAGradeformat(options) {
|
|
|
722
662
|
return deferred.promise;
|
|
723
663
|
}
|
|
724
664
|
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
body : {
|
|
730
|
-
"users":[ // min:1 , max: 50
|
|
731
|
-
{
|
|
732
|
-
extUserId: "string", // Mandatory
|
|
733
|
-
}
|
|
734
|
-
....
|
|
735
|
-
],
|
|
736
|
-
"context": {} // Optional
|
|
737
|
-
}
|
|
738
|
-
}
|
|
739
|
-
*/
|
|
665
|
+
/**
|
|
666
|
+
* Wiki Link for SDK params
|
|
667
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#createuserassignedpathenrollmentsparams
|
|
668
|
+
*/
|
|
740
669
|
function createUserAssignedPathEnrollments(options) {
|
|
741
670
|
var self = this;
|
|
742
671
|
// Initializing promise
|
|
@@ -786,18 +715,10 @@ function createUserAssignedPathEnrollments(options) {
|
|
|
786
715
|
return dfd.promise;
|
|
787
716
|
}
|
|
788
717
|
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
body : [ // min:1 , max: 50
|
|
794
|
-
{
|
|
795
|
-
extUserId: "string", //Mandatory
|
|
796
|
-
},
|
|
797
|
-
...
|
|
798
|
-
]
|
|
799
|
-
}
|
|
800
|
-
*/
|
|
718
|
+
/**
|
|
719
|
+
* Wiki Link for SDK params
|
|
720
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#deleteuserassignedpathenrollmentsparams
|
|
721
|
+
*/
|
|
801
722
|
function deleteUserAssignedPathEnrollments(options) {
|
|
802
723
|
var self = this;
|
|
803
724
|
// Initializing promise
|
|
@@ -848,11 +769,8 @@ function deleteUserAssignedPathEnrollments(options) {
|
|
|
848
769
|
}
|
|
849
770
|
|
|
850
771
|
/**
|
|
851
|
-
*
|
|
852
|
-
*
|
|
853
|
-
* productDetails: <Boolean>, // optional
|
|
854
|
-
* bundleDetails: <Boolean> // optional
|
|
855
|
-
* } options
|
|
772
|
+
* Wiki Link for SDK params
|
|
773
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#getparticularclassv2params
|
|
856
774
|
*/
|
|
857
775
|
function getParticularClassV2(options) {
|
|
858
776
|
var self = this;
|
|
@@ -899,15 +817,8 @@ function getParticularClassV2(options) {
|
|
|
899
817
|
}
|
|
900
818
|
|
|
901
819
|
/**
|
|
902
|
-
*
|
|
903
|
-
*
|
|
904
|
-
* status: "string" // ['active', 'revoked'] - default: 'active'
|
|
905
|
-
* expired: <boolean>, // default: false
|
|
906
|
-
* startdate: <epoch>,
|
|
907
|
-
* enddate: <epoch>,
|
|
908
|
-
* audit: <boolean> // [true] - default: true
|
|
909
|
-
* ext_data: {...},
|
|
910
|
-
* } options
|
|
820
|
+
* Wiki Link for SDK params
|
|
821
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#createorgproductentitlementparams
|
|
911
822
|
*/
|
|
912
823
|
function createOrgProductEntitlement(options) {
|
|
913
824
|
var self = this;
|
|
@@ -953,15 +864,8 @@ function createOrgProductEntitlement(options) {
|
|
|
953
864
|
}
|
|
954
865
|
|
|
955
866
|
/**
|
|
956
|
-
*
|
|
957
|
-
*
|
|
958
|
-
* status: "string" // ['active', 'revoked']
|
|
959
|
-
* expired: <boolean>,
|
|
960
|
-
* startdate: <epoch>,
|
|
961
|
-
* enddate: <epoch>,
|
|
962
|
-
* audit: <boolean> // [true] - default: true
|
|
963
|
-
* ext_data: {...},
|
|
964
|
-
* } options
|
|
867
|
+
* Wiki Link for SDK params
|
|
868
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#updateorgproductentitlementparams
|
|
965
869
|
*/
|
|
966
870
|
function updateOrgProductEntitlement(options) {
|
|
967
871
|
var self = this;
|
|
@@ -1009,9 +913,8 @@ function updateOrgProductEntitlement(options) {
|
|
|
1009
913
|
}
|
|
1010
914
|
|
|
1011
915
|
/**
|
|
1012
|
-
*
|
|
1013
|
-
*
|
|
1014
|
-
* } options
|
|
916
|
+
* Wiki Link for SDK params
|
|
917
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#getparticularorgproductentitlementparams
|
|
1015
918
|
*/
|
|
1016
919
|
function getParticularOrgProductEntitlement(options) {
|
|
1017
920
|
var self = this;
|
|
@@ -1051,11 +954,8 @@ function getParticularOrgProductEntitlement(options) {
|
|
|
1051
954
|
}
|
|
1052
955
|
|
|
1053
956
|
/**
|
|
1054
|
-
*
|
|
1055
|
-
*
|
|
1056
|
-
* expired: <boolean>,
|
|
1057
|
-
* cursor: <epoch>
|
|
1058
|
-
* } options
|
|
957
|
+
* Wiki Link for SDK params
|
|
958
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/28_AUTHEXTN-Adapter#getallorgproductentitlementsparams
|
|
1059
959
|
*/
|
|
1060
960
|
function getAllOrgProductEntitlements(options) {
|
|
1061
961
|
var self = this;
|
|
@@ -30,9 +30,6 @@ var Agent = require('agentkeepalive');
|
|
|
30
30
|
var helpers = require('../../helpers');
|
|
31
31
|
var DLSError = helpers.errors.DLSError;
|
|
32
32
|
|
|
33
|
-
/*********************************
|
|
34
|
-
* Setting Up Module Entry Point
|
|
35
|
-
**********************************/
|
|
36
33
|
module.exports = datasyncmanager;
|
|
37
34
|
|
|
38
35
|
var keepaliveAgent = new Agent({
|
|
@@ -53,22 +50,8 @@ function datasyncmanager(accountId) {
|
|
|
53
50
|
}
|
|
54
51
|
|
|
55
52
|
/**
|
|
56
|
-
*
|
|
57
|
-
*
|
|
58
|
-
* "*dsmid": "string",
|
|
59
|
-
* "dsm_groupid": "string",
|
|
60
|
-
* "rules_orgs": [{"*id": "string"}, ...],
|
|
61
|
-
* "rules_products": [{
|
|
62
|
-
* "*productcode": "string",
|
|
63
|
-
* "*ext_entitlement_meta": { "start_date", "*end_date" },
|
|
64
|
-
* "*target_roles": [role]
|
|
65
|
-
* }],
|
|
66
|
-
* "*category": "entitlement_sync",
|
|
67
|
-
* "*type": "managed",
|
|
68
|
-
* "*ext_user_id": "string",
|
|
69
|
-
* "data": {},
|
|
70
|
-
* "*audit": true
|
|
71
|
-
* }
|
|
53
|
+
* Wiki Link for SDK params
|
|
54
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/27_DATASYNCMANAGER-Adapter#createdatasyncmanagerparams
|
|
72
55
|
*/
|
|
73
56
|
function createDataSyncManager(options) {
|
|
74
57
|
var self = this;
|
|
@@ -109,20 +92,8 @@ function createDataSyncManager(options) {
|
|
|
109
92
|
}
|
|
110
93
|
|
|
111
94
|
/**
|
|
112
|
-
*
|
|
113
|
-
*
|
|
114
|
-
* "*body": {
|
|
115
|
-
* "rules_orgs": [{ "*id": "orgid" }, ...],
|
|
116
|
-
* "*rules_products": [{
|
|
117
|
-
* "*productcode": "<productcode-1>",
|
|
118
|
-
* "*ext_entitlement_meta": { "start_date", "*end_date" },
|
|
119
|
-
* "target_roles": ["role"],
|
|
120
|
-
* }],
|
|
121
|
-
* "*ext_user_id": "ext_actor_id",
|
|
122
|
-
* "data": {},
|
|
123
|
-
* "*audit": <boolean>
|
|
124
|
-
* }
|
|
125
|
-
* }
|
|
95
|
+
* Wiki Link for SDK params
|
|
96
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/27_DATASYNCMANAGER-Adapter#updatedatasyncmanagerparams
|
|
126
97
|
*/
|
|
127
98
|
function updateDataSyncManager(options) {
|
|
128
99
|
// Initializing promise
|
|
@@ -171,12 +142,8 @@ function updateDataSyncManager(options) {
|
|
|
171
142
|
}
|
|
172
143
|
|
|
173
144
|
/**
|
|
174
|
-
*
|
|
175
|
-
*
|
|
176
|
-
* "*body": {
|
|
177
|
-
* "*ext_user_id": "string",
|
|
178
|
-
* "*audit": true
|
|
179
|
-
* }
|
|
145
|
+
* Wiki Link for SDK params
|
|
146
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/27_DATASYNCMANAGER-Adapter#deletedatasyncmanagerparams
|
|
180
147
|
*/
|
|
181
148
|
function deleteDataSyncManager(options) {
|
|
182
149
|
var self = this;
|
|
@@ -216,9 +183,8 @@ function deleteDataSyncManager(options) {
|
|
|
216
183
|
}
|
|
217
184
|
|
|
218
185
|
/**
|
|
219
|
-
*
|
|
220
|
-
*
|
|
221
|
-
* }
|
|
186
|
+
* Wiki Link for SDK params
|
|
187
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/27_DATASYNCMANAGER-Adapter#getparticulardatasyncmanagerparams
|
|
222
188
|
*/
|
|
223
189
|
function getParticularDataSyncManager(options) {
|
|
224
190
|
// Initializing promise
|
|
@@ -263,9 +229,8 @@ function getParticularDataSyncManager(options) {
|
|
|
263
229
|
}
|
|
264
230
|
|
|
265
231
|
/**
|
|
266
|
-
*
|
|
267
|
-
*
|
|
268
|
-
* }
|
|
232
|
+
* Wiki Link for SDK params
|
|
233
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/27_DATASYNCMANAGER-Adapter#getalldatasyncmanagersofagroupparams
|
|
269
234
|
*/
|
|
270
235
|
function getAllDataSyncManagersOfAGroup(options) {
|
|
271
236
|
// Initializing promise
|
|
@@ -23,10 +23,6 @@
|
|
|
23
23
|
* Functions for calling Drive-service API.
|
|
24
24
|
************************************************************/
|
|
25
25
|
|
|
26
|
-
/*********************************
|
|
27
|
-
* Setting Up Module Entry Point
|
|
28
|
-
**********************************/
|
|
29
|
-
|
|
30
26
|
var q = require('q');
|
|
31
27
|
var request = require('superagent');
|
|
32
28
|
var Agent = require('agentkeepalive');
|
|
@@ -54,14 +50,10 @@ function documents() {
|
|
|
54
50
|
};
|
|
55
51
|
}
|
|
56
52
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
documentid : 'string', //mandatory
|
|
62
|
-
folderid: 'string', //mandatory
|
|
63
|
-
}
|
|
64
|
-
*/
|
|
53
|
+
/**
|
|
54
|
+
* Wiki Link for SDK params
|
|
55
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/24_DRIVE-Adapter#getaparticulardocumentparams
|
|
56
|
+
*/
|
|
65
57
|
function getAParticularDocument(options) {
|
|
66
58
|
var self = this;
|
|
67
59
|
var dfd = q.defer();
|
|
@@ -99,18 +91,10 @@ function getAParticularDocument(options) {
|
|
|
99
91
|
return dfd.promise;
|
|
100
92
|
}
|
|
101
93
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
folderid: 'string', //mandatory
|
|
107
|
-
classid: 'string',
|
|
108
|
-
productcode: 'string',
|
|
109
|
-
assigned_path_id: 'string',
|
|
110
|
-
item-code: 'string',
|
|
111
|
-
cursor: 'string'
|
|
112
|
-
}
|
|
113
|
-
*/
|
|
94
|
+
/**
|
|
95
|
+
* Wiki Link for SDK params
|
|
96
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/24_DRIVE-Adapter#getalldocumentsinafolderparams
|
|
97
|
+
*/
|
|
114
98
|
function getAllDocumentsInAFolder(options) {
|
|
115
99
|
var self = this;
|
|
116
100
|
var dfd = q.defer();
|
|
@@ -152,31 +136,10 @@ function getAllDocumentsInAFolder(options) {
|
|
|
152
136
|
return dfd.promise;
|
|
153
137
|
}
|
|
154
138
|
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
body: { // mandatory
|
|
160
|
-
orgid: 'string', // mandatory
|
|
161
|
-
classid: 'string',
|
|
162
|
-
productcode: 'string', // mandatory
|
|
163
|
-
dls_user_id: 'string', // mandatory
|
|
164
|
-
collaborator_id: 'string' // optional; mandatory if some OTHER user is updating this document.
|
|
165
|
-
entities: [ // mandatory (Min length 1)
|
|
166
|
-
{
|
|
167
|
-
item_code: 'string',
|
|
168
|
-
folderid: 'string', // mandatory
|
|
169
|
-
documentid: 'string', // mandatory
|
|
170
|
-
tag: 'string',
|
|
171
|
-
timestamp: <epoch>, // mandatory
|
|
172
|
-
ttl: <number>, // optional, default - 3 months
|
|
173
|
-
data: {} // mandatory, state JSON
|
|
174
|
-
},
|
|
175
|
-
...
|
|
176
|
-
]
|
|
177
|
-
}
|
|
178
|
-
}
|
|
179
|
-
*/
|
|
139
|
+
/**
|
|
140
|
+
* Wiki Link for SDK params
|
|
141
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/24_DRIVE-Adapter#createmultipledocumentsparams
|
|
142
|
+
*/
|
|
180
143
|
function createMultipleDocuments(options) {
|
|
181
144
|
var self = this;
|
|
182
145
|
var dfd = q.defer();
|
|
@@ -216,25 +179,10 @@ function createMultipleDocuments(options) {
|
|
|
216
179
|
return dfd.promise;
|
|
217
180
|
}
|
|
218
181
|
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
body: { // mandatory
|
|
224
|
-
collaborator_id: 'string' // optional; mandatory if some OTHER user is updating this document.
|
|
225
|
-
entities: [ // mandatory (Min length 1)
|
|
226
|
-
{
|
|
227
|
-
folderid: 'string', // mandatory
|
|
228
|
-
documentid: 'string', // mandatory
|
|
229
|
-
timestamp: <epoch>, // mandatory
|
|
230
|
-
ttl: <number>,
|
|
231
|
-
data: {}
|
|
232
|
-
},
|
|
233
|
-
...
|
|
234
|
-
]
|
|
235
|
-
}
|
|
236
|
-
}
|
|
237
|
-
*/
|
|
182
|
+
/**
|
|
183
|
+
* Wiki Link for SDK params
|
|
184
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/24_DRIVE-Adapter#updatemultipledocumentsparams
|
|
185
|
+
*/
|
|
238
186
|
function updateMultipleDocuments(options) {
|
|
239
187
|
// Initializing promise
|
|
240
188
|
var deferred = q.defer();
|
|
@@ -277,21 +225,10 @@ function updateMultipleDocuments(options) {
|
|
|
277
225
|
return deferred.promise;
|
|
278
226
|
}
|
|
279
227
|
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
body: { // mandatory
|
|
285
|
-
entities: [ // mandatory (Min length 1)
|
|
286
|
-
{
|
|
287
|
-
folderid: 'string', // mandatory
|
|
288
|
-
documentid: 'string', // mandatory
|
|
289
|
-
},
|
|
290
|
-
...
|
|
291
|
-
]
|
|
292
|
-
}
|
|
293
|
-
}
|
|
294
|
-
*/
|
|
228
|
+
/**
|
|
229
|
+
* Wiki Link for SDK params
|
|
230
|
+
* https://github.com/comprodls/comprodls-sdk-js/wiki/24_DRIVE-Adapter#deletemultipledocumentsparams
|
|
231
|
+
*/
|
|
295
232
|
function deleteMultipleDocuments(options) {
|
|
296
233
|
var self = this;
|
|
297
234
|
var dfd = q.defer();
|