@targetprocess/shared-data-model-client 0.2.0-us817837-mapping.31 → 0.2.0

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/src/v1.json CHANGED
@@ -6,7 +6,7 @@
6
6
  "version": "v1"
7
7
  },
8
8
  "paths": {
9
- "/api/sdm/{entityType}": {
9
+ "/api/sdm/{entityType}/{id}": {
10
10
  "get": {
11
11
  "tags": [
12
12
  "Sdm"
@@ -22,6 +22,15 @@
22
22
  "type": "string"
23
23
  }
24
24
  },
25
+ {
26
+ "name": "id",
27
+ "in": "path",
28
+ "required": true,
29
+ "schema": {
30
+ "type": "integer",
31
+ "format": "int32"
32
+ }
33
+ },
25
34
  {
26
35
  "name": "select",
27
36
  "in": "query",
@@ -71,6 +80,23 @@
71
80
  "type": "string",
72
81
  "nullable": true
73
82
  }
83
+ },
84
+ {
85
+ "name": "result",
86
+ "in": "query",
87
+ "schema": {
88
+ "type": "string",
89
+ "nullable": true
90
+ }
91
+ },
92
+ {
93
+ "name": "isodate",
94
+ "in": "query",
95
+ "schema": {
96
+ "type": "integer",
97
+ "format": "int32",
98
+ "nullable": true
99
+ }
74
100
  }
75
101
  ],
76
102
  "responses": {
@@ -139,13 +165,112 @@
139
165
  ]
140
166
  }
141
167
  },
168
+ "/api/sdm/{entityType}/count": {
169
+ "get": {
170
+ "tags": [
171
+ "Sdm"
172
+ ],
173
+ "summary": "Retrieves Shared Data Model entities count",
174
+ "operationId": "SharedDataCountEndpoint",
175
+ "parameters": [
176
+ {
177
+ "name": "entityType",
178
+ "in": "path",
179
+ "required": true,
180
+ "schema": {
181
+ "type": "string"
182
+ }
183
+ },
184
+ {
185
+ "name": "where",
186
+ "in": "query",
187
+ "schema": {
188
+ "type": "string",
189
+ "nullable": true
190
+ }
191
+ },
192
+ {
193
+ "name": "filter",
194
+ "in": "query",
195
+ "schema": {
196
+ "type": "string",
197
+ "nullable": true
198
+ }
199
+ }
200
+ ],
201
+ "responses": {
202
+ "200": {
203
+ "description": "Success",
204
+ "content": {
205
+ "application/json": {
206
+ "schema": {
207
+ "type": "integer",
208
+ "format": "int32"
209
+ }
210
+ }
211
+ }
212
+ },
213
+ "401": {
214
+ "description": "Unauthorized",
215
+ "content": {
216
+ "application/problem+json": {
217
+ "schema": {
218
+ "$ref": "#/components/schemas/ProblemDetails"
219
+ }
220
+ }
221
+ }
222
+ },
223
+ "403": {
224
+ "description": "Forbidden"
225
+ },
226
+ "400": {
227
+ "description": "Validation error",
228
+ "content": {
229
+ "application/problem+json": {
230
+ "schema": {
231
+ "$ref": "#/components/schemas/HttpValidationProblemDetails"
232
+ }
233
+ }
234
+ }
235
+ },
236
+ "500": {
237
+ "description": "Internal server error",
238
+ "content": {
239
+ "application/problem+json": {
240
+ "schema": {
241
+ "$ref": "#/components/schemas/ProblemDetails"
242
+ }
243
+ }
244
+ }
245
+ },
246
+ "404": {
247
+ "description": "Unable to find resource",
248
+ "content": {
249
+ "application/problem+json": {
250
+ "schema": {
251
+ "$ref": "#/components/schemas/ProblemDetails"
252
+ }
253
+ }
254
+ }
255
+ }
256
+ },
257
+ "security": [
258
+ {
259
+ "JWTBearerAuth": []
260
+ },
261
+ {
262
+ "OAuth2": []
263
+ }
264
+ ]
265
+ }
266
+ },
142
267
  "/api/settings/profile": {
143
268
  "put": {
144
269
  "tags": [
145
270
  "Settings"
146
271
  ],
147
272
  "summary": "Update settings profile",
148
- "operationId": "UpdateProfileEndpoint",
273
+ "operationId": "UpdateProfileSettingsEndpoint",
149
274
  "requestBody": {
150
275
  "x-name": "ProfileDto",
151
276
  "description": "",
@@ -429,12 +554,16 @@
429
554
  "type": "object",
430
555
  "additionalProperties": false
431
556
  },
557
+ "SharedDataCountRequestDto": {
558
+ "type": "object",
559
+ "additionalProperties": false
560
+ },
432
561
  "ProfileDto": {
433
562
  "type": "object",
434
563
  "additionalProperties": false,
435
564
  "required": [
436
565
  "account",
437
- "typeMappings",
566
+ "mappings",
438
567
  "enabled"
439
568
  ],
440
569
  "properties": {
@@ -446,10 +575,10 @@
446
575
  "account": {
447
576
  "type": "string"
448
577
  },
449
- "typeMappings": {
578
+ "mappings": {
450
579
  "type": "array",
451
580
  "items": {
452
- "$ref": "#/components/schemas/TypeMappingDto"
581
+ "$ref": "#/components/schemas/ProfileMappingDto"
453
582
  }
454
583
  },
455
584
  "enabled": {
@@ -457,38 +586,61 @@
457
586
  }
458
587
  }
459
588
  },
589
+ "ProfileMappingDto": {
590
+ "type": "object",
591
+ "additionalProperties": false,
592
+ "required": [
593
+ "name",
594
+ "enabled",
595
+ "typeMappings"
596
+ ],
597
+ "properties": {
598
+ "id": {
599
+ "type": "string",
600
+ "nullable": true
601
+ },
602
+ "name": {
603
+ "type": "string"
604
+ },
605
+ "enabled": {
606
+ "type": "boolean"
607
+ },
608
+ "typeMappings": {
609
+ "type": "array",
610
+ "items": {
611
+ "$ref": "#/components/schemas/TypeMappingDto"
612
+ }
613
+ }
614
+ }
615
+ },
460
616
  "TypeMappingDto": {
461
617
  "type": "object",
462
618
  "additionalProperties": false,
463
619
  "required": [
464
- "id",
465
620
  "sourceType",
466
621
  "targetType",
467
- "fieldMappings",
468
- "isValid"
622
+ "fieldMappings"
469
623
  ],
470
624
  "properties": {
471
625
  "id": {
472
- "type": "string"
626
+ "type": "string",
627
+ "nullable": true
473
628
  },
474
629
  "sourceType": {
475
- "$ref": "#/components/schemas/TpTypeDefDto"
630
+ "$ref": "#/components/schemas/TypeDefDto"
476
631
  },
477
632
  "targetType": {
478
- "$ref": "#/components/schemas/SdmTypeDefDto"
633
+ "$ref": "#/components/schemas/TypeDefDto"
479
634
  },
480
635
  "fieldMappings": {
481
636
  "type": "array",
482
637
  "items": {
483
638
  "$ref": "#/components/schemas/FieldMappingDto"
484
639
  }
485
- },
486
- "isValid": {
487
- "type": "boolean"
488
640
  }
489
641
  }
490
642
  },
491
- "TpTypeDefDto": {
643
+ "TypeDefDto": {
492
644
  "type": "object",
493
645
  "additionalProperties": false,
494
646
  "required": [
@@ -505,6 +657,10 @@
505
657
  },
506
658
  "kind": {
507
659
  "$ref": "#/components/schemas/TypeKind"
660
+ },
661
+ "javaScriptComparator": {
662
+ "type": "string",
663
+ "nullable": true
508
664
  }
509
665
  }
510
666
  },
@@ -542,100 +698,257 @@
542
698
  "Unknown"
543
699
  ]
544
700
  },
545
- "SdmTypeDefDto": {
701
+ "FieldMappingDto": {
546
702
  "type": "object",
547
703
  "additionalProperties": false,
548
704
  "required": [
549
705
  "id",
550
- "name",
551
- "kind"
706
+ "type"
552
707
  ],
553
708
  "properties": {
554
709
  "id": {
555
710
  "type": "string"
556
711
  },
557
- "name": {
558
- "type": "string"
712
+ "type": {
713
+ "$ref": "#/components/schemas/FieldMappingType"
559
714
  },
560
- "kind": {
561
- "$ref": "#/components/schemas/TypeKind"
715
+ "source": {
716
+ "nullable": true,
717
+ "oneOf": [
718
+ {
719
+ "$ref": "#/components/schemas/FieldDefDto"
720
+ }
721
+ ]
722
+ },
723
+ "target": {
724
+ "nullable": true,
725
+ "oneOf": [
726
+ {
727
+ "$ref": "#/components/schemas/FieldDefDto"
728
+ }
729
+ ]
730
+ },
731
+ "sourceRel": {
732
+ "nullable": true,
733
+ "oneOf": [
734
+ {
735
+ "$ref": "#/components/schemas/RelationDto"
736
+ }
737
+ ]
738
+ },
739
+ "targetRel": {
740
+ "nullable": true,
741
+ "oneOf": [
742
+ {
743
+ "$ref": "#/components/schemas/RelationDto"
744
+ }
745
+ ]
562
746
  }
563
747
  }
564
748
  },
565
- "FieldMappingDto": {
749
+ "FieldMappingType": {
750
+ "type": "string",
751
+ "description": "",
752
+ "x-enumNames": [
753
+ "ValueFieldMapping",
754
+ "CollectionFieldMapping",
755
+ "ReferenceToStringFieldMapping",
756
+ "TargetprocessDescriptionMapping",
757
+ "CollectionToStringMapping",
758
+ "RelationFieldMapping",
759
+ "EntityStateMapping",
760
+ "JavaScriptFieldMapping",
761
+ "UserFieldMapping",
762
+ "RoleAssignmentUserFieldMapping",
763
+ "RoleEffortFieldMapping",
764
+ "ConstantFieldMapping",
765
+ "RoleAssignmentsFieldMapping",
766
+ "RoleEffortToRoleEffortFieldMapping"
767
+ ],
768
+ "enum": [
769
+ "ValueFieldMapping",
770
+ "CollectionFieldMapping",
771
+ "ReferenceToStringFieldMapping",
772
+ "TargetprocessDescriptionMapping",
773
+ "CollectionToStringMapping",
774
+ "RelationFieldMapping",
775
+ "EntityStateMapping",
776
+ "JavaScriptFieldMapping",
777
+ "UserFieldMapping",
778
+ "RoleAssignmentUserFieldMapping",
779
+ "RoleEffortFieldMapping",
780
+ "ConstantFieldMapping",
781
+ "RoleAssignmentsFieldMapping",
782
+ "RoleEffortToRoleEffortFieldMapping"
783
+ ]
784
+ },
785
+ "FieldDefDto": {
566
786
  "type": "object",
567
787
  "additionalProperties": false,
568
788
  "required": [
569
789
  "id",
570
- "type",
571
- "source",
572
- "target",
573
- "isValid"
790
+ "name",
791
+ "path",
792
+ "meta"
574
793
  ],
575
794
  "properties": {
576
795
  "id": {
577
796
  "type": "string"
578
797
  },
579
- "type": {
798
+ "name": {
580
799
  "type": "string"
581
800
  },
582
- "source": {
583
- "$ref": "#/components/schemas/TpMappingFieldDefDto"
584
- },
585
- "target": {
586
- "$ref": "#/components/schemas/SdmMappingFieldDefDto"
801
+ "path": {
802
+ "type": "string"
587
803
  },
588
- "isValid": {
589
- "type": "boolean"
804
+ "meta": {
805
+ "$ref": "#/components/schemas/FieldMetaDto"
590
806
  }
591
807
  }
592
808
  },
593
- "TpMappingFieldDefDto": {
809
+ "FieldMetaDto": {
594
810
  "type": "object",
595
811
  "additionalProperties": false,
596
812
  "required": [
813
+ "isReadonly",
597
814
  "kind",
598
- "expression"
815
+ "type",
816
+ "required",
817
+ "attributes",
818
+ "options"
599
819
  ],
600
820
  "properties": {
821
+ "isReadonly": {
822
+ "type": "boolean"
823
+ },
601
824
  "kind": {
602
- "$ref": "#/components/schemas/MappingKind"
825
+ "$ref": "#/components/schemas/FieldKind"
603
826
  },
604
- "expression": {
605
- "type": "string"
827
+ "type": {
828
+ "$ref": "#/components/schemas/TypeDefRefDto"
829
+ },
830
+ "required": {
831
+ "type": "boolean"
832
+ },
833
+ "attributes": {
834
+ "$ref": "#/components/schemas/FieldAttributesDto"
835
+ },
836
+ "multiple": {
837
+ "type": "boolean",
838
+ "nullable": true
839
+ },
840
+ "options": {
841
+ "type": "array",
842
+ "items": {}
843
+ },
844
+ "roundsDate": {
845
+ "type": "boolean",
846
+ "nullable": true
606
847
  }
607
848
  }
608
849
  },
609
- "MappingKind": {
850
+ "FieldKind": {
610
851
  "type": "string",
611
852
  "description": "",
612
853
  "x-enumNames": [
613
- "Property",
614
- "PropertyChain",
615
- "FreeExpression"
854
+ "CollectionFieldMeta",
855
+ "FieldMeta",
856
+ "SelectFieldMeta"
616
857
  ],
617
858
  "enum": [
618
- "Property",
619
- "PropertyChain",
620
- "FreeExpression"
859
+ "CollectionFieldMeta",
860
+ "FieldMeta",
861
+ "SelectFieldMeta"
621
862
  ]
622
863
  },
623
- "SdmMappingFieldDefDto": {
864
+ "TypeDefRefDto": {
624
865
  "type": "object",
625
866
  "additionalProperties": false,
626
867
  "required": [
627
- "kind",
628
- "expression"
868
+ "id",
869
+ "kind"
629
870
  ],
630
871
  "properties": {
872
+ "id": {
873
+ "type": "string"
874
+ },
631
875
  "kind": {
632
- "$ref": "#/components/schemas/MappingKind"
876
+ "$ref": "#/components/schemas/TypeKind"
877
+ }
878
+ }
879
+ },
880
+ "FieldAttributesDto": {
881
+ "type": "object",
882
+ "additionalProperties": false,
883
+ "required": [
884
+ "isExtendable"
885
+ ],
886
+ "properties": {
887
+ "isExtendable": {
888
+ "type": "boolean"
633
889
  },
634
- "expression": {
890
+ "roleId": {
891
+ "type": "string",
892
+ "nullable": true
893
+ }
894
+ }
895
+ },
896
+ "RelationDto": {
897
+ "type": "object",
898
+ "additionalProperties": false,
899
+ "required": [
900
+ "childType",
901
+ "relation"
902
+ ],
903
+ "properties": {
904
+ "childType": {
905
+ "$ref": "#/components/schemas/TypeDefRefDto"
906
+ },
907
+ "field": {
908
+ "nullable": true,
909
+ "oneOf": [
910
+ {
911
+ "$ref": "#/components/schemas/FieldDefDto"
912
+ }
913
+ ]
914
+ },
915
+ "relation": {
916
+ "$ref": "#/components/schemas/RelationDefRefDto"
917
+ }
918
+ }
919
+ },
920
+ "RelationDefRefDto": {
921
+ "type": "object",
922
+ "additionalProperties": false,
923
+ "required": [
924
+ "id"
925
+ ],
926
+ "properties": {
927
+ "id": {
635
928
  "type": "string"
929
+ },
930
+ "direction": {
931
+ "nullable": true,
932
+ "oneOf": [
933
+ {
934
+ "$ref": "#/components/schemas/RelationDirection"
935
+ }
936
+ ]
636
937
  }
637
938
  }
638
939
  },
940
+ "RelationDirection": {
941
+ "type": "string",
942
+ "description": "",
943
+ "x-enumNames": [
944
+ "Inbound",
945
+ "Outbound"
946
+ ],
947
+ "enum": [
948
+ "Inbound",
949
+ "Outbound"
950
+ ]
951
+ },
639
952
  "GetProfileSettingsDto": {
640
953
  "type": "object",
641
954
  "additionalProperties": false,
@@ -652,17 +965,10 @@
652
965
  "type": "object",
653
966
  "additionalProperties": false,
654
967
  "required": [
655
- "sdmTypes",
656
- "tpTypes"
968
+ "types"
657
969
  ],
658
970
  "properties": {
659
- "sdmTypes": {
660
- "type": "array",
661
- "items": {
662
- "$ref": "#/components/schemas/TypeMetaDefDto"
663
- }
664
- },
665
- "tpTypes": {
971
+ "types": {
666
972
  "type": "array",
667
973
  "items": {
668
974
  "$ref": "#/components/schemas/TypeMetaDefDto"
@@ -684,7 +990,7 @@
684
990
  "type": "string"
685
991
  },
686
992
  "kind": {
687
- "$ref": "#/components/schemas/TypeKind"
993
+ "type": "string"
688
994
  },
689
995
  "name": {
690
996
  "type": "string"
@@ -692,39 +998,10 @@
692
998
  "fields": {
693
999
  "type": "array",
694
1000
  "items": {
695
- "$ref": "#/components/schemas/IFieldDef"
1001
+ "$ref": "#/components/schemas/FieldDefDto"
696
1002
  }
697
1003
  }
698
1004
  }
699
- },
700
- "IFieldDef": {
701
- "type": "object",
702
- "x-abstract": true,
703
- "additionalProperties": false,
704
- "required": [
705
- "kind",
706
- "expression"
707
- ],
708
- "properties": {
709
- "kind": {
710
- "$ref": "#/components/schemas/FieldKind"
711
- },
712
- "expression": {
713
- "type": "string"
714
- }
715
- }
716
- },
717
- "FieldKind": {
718
- "type": "string",
719
- "description": "",
720
- "x-enumNames": [
721
- "Simple",
722
- "Ref"
723
- ],
724
- "enum": [
725
- "Simple",
726
- "Ref"
727
- ]
728
1005
  }
729
1006
  },
730
1007
  "securitySchemes": {