basyx-typescript-sdk 2.3.0 → 2.4.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.
Files changed (62) hide show
  1. package/README.md +68 -1
  2. package/bundle/index.cjs +1421 -91
  3. package/bundle/index.cjs.map +1 -1
  4. package/bundle/index.mjs +1353 -92
  5. package/bundle/index.mjs.map +1 -1
  6. package/dist/clients/AasRegistryClient.d.ts +20 -0
  7. package/dist/clients/AasRegistryClient.js +40 -0
  8. package/dist/clients/AasRepositoryClient.d.ts +20 -0
  9. package/dist/clients/AasRepositoryClient.js +40 -0
  10. package/dist/clients/ConceptDescriptionRepositoryClient.d.ts +20 -0
  11. package/dist/clients/ConceptDescriptionRepositoryClient.js +40 -0
  12. package/dist/clients/SubmodelRegistryClient.d.ts +20 -0
  13. package/dist/clients/SubmodelRegistryClient.js +40 -0
  14. package/dist/clients/SubmodelRepositoryClient.d.ts +20 -0
  15. package/dist/clients/SubmodelRepositoryClient.js +40 -0
  16. package/dist/generated/AasRegistryService/apis/AssetAdministrationShellRegistryAPIApi.d.ts +14 -1
  17. package/dist/generated/AasRegistryService/apis/AssetAdministrationShellRegistryAPIApi.js +29 -0
  18. package/dist/generated/AasRegistryService/models/index.d.ts +374 -0
  19. package/dist/generated/AasRegistryService/models/index.js +6 -0
  20. package/dist/generated/AasRepositoryService/apis/AssetAdministrationShellRepositoryAPIApi.d.ts +14 -1
  21. package/dist/generated/AasRepositoryService/apis/AssetAdministrationShellRepositoryAPIApi.js +29 -0
  22. package/dist/generated/AasRepositoryService/models/index.d.ts +381 -0
  23. package/dist/generated/AasRepositoryService/models/index.js +7 -0
  24. package/dist/generated/ConceptDescriptionRepositoryService/apis/ConceptDescriptionRepositoryAPIApi.d.ts +14 -1
  25. package/dist/generated/ConceptDescriptionRepositoryService/apis/ConceptDescriptionRepositoryAPIApi.js +29 -0
  26. package/dist/generated/ConceptDescriptionRepositoryService/models/index.d.ts +381 -0
  27. package/dist/generated/ConceptDescriptionRepositoryService/models/index.js +7 -0
  28. package/dist/generated/SubmodelRegistryService/apis/SubmodelRegistryAPIApi.d.ts +14 -1
  29. package/dist/generated/SubmodelRegistryService/apis/SubmodelRegistryAPIApi.js +29 -0
  30. package/dist/generated/SubmodelRegistryService/models/index.d.ts +381 -0
  31. package/dist/generated/SubmodelRegistryService/models/index.js +7 -0
  32. package/dist/generated/SubmodelRepositoryService/apis/SubmodelRepositoryAPIApi.d.ts +14 -1
  33. package/dist/generated/SubmodelRepositoryService/apis/SubmodelRepositoryAPIApi.js +29 -0
  34. package/dist/generated/SubmodelRepositoryService/models/index.d.ts +381 -0
  35. package/dist/generated/SubmodelRepositoryService/models/index.js +7 -0
  36. package/dist/lib/endpointConfiguration.d.ts +71 -0
  37. package/dist/lib/endpointConfiguration.js +101 -0
  38. package/dist/lib/errorHandler.js +9 -4
  39. package/dist/lib/index.d.ts +1 -0
  40. package/dist/lib/index.js +2 -0
  41. package/dist/lib/queryJsonization.d.ts +17 -0
  42. package/dist/lib/queryJsonization.js +309 -0
  43. package/dist/lib/queryRequests.d.ts +24 -0
  44. package/dist/lib/queryRequests.js +44 -0
  45. package/dist/models/Query.d.ts +378 -0
  46. package/dist/models/Query.js +430 -0
  47. package/dist/models/QueryResult.d.ts +22 -0
  48. package/dist/models/QueryResult.js +1 -0
  49. package/dist/models/index.d.ts +2 -0
  50. package/dist/models/index.js +2 -0
  51. package/dist/services/AasService.d.ts +15 -4
  52. package/dist/services/AasService.js +38 -40
  53. package/dist/services/SubmodelService.d.ts +9 -8
  54. package/dist/services/SubmodelService.js +17 -34
  55. package/dist/services/index.d.ts +1 -0
  56. package/dist/utils/DescriptorUtils.d.ts +27 -1
  57. package/dist/utils/DescriptorUtils.js +65 -27
  58. package/dist/utils/ServiceDescriptionUtils.d.ts +30 -0
  59. package/dist/utils/ServiceDescriptionUtils.js +43 -0
  60. package/dist/utils/index.d.ts +2 -0
  61. package/dist/utils/index.js +2 -0
  62. package/package.json +1 -1
@@ -677,6 +677,182 @@ export interface LevelType {
677
677
  */
678
678
  max: boolean;
679
679
  }
680
+ /**
681
+ *
682
+ * @export
683
+ * @interface LogicalExpression
684
+ */
685
+ export interface LogicalExpression {
686
+ /**
687
+ *
688
+ * @type {Array<LogicalExpression>}
689
+ * @memberof LogicalExpression
690
+ */
691
+ $and?: Array<LogicalExpression>;
692
+ /**
693
+ *
694
+ * @type {Array<MatchExpression>}
695
+ * @memberof LogicalExpression
696
+ */
697
+ $match?: Array<MatchExpression>;
698
+ /**
699
+ *
700
+ * @type {Array<LogicalExpression>}
701
+ * @memberof LogicalExpression
702
+ */
703
+ $or?: Array<LogicalExpression>;
704
+ /**
705
+ *
706
+ * @type {LogicalExpression}
707
+ * @memberof LogicalExpression
708
+ */
709
+ $not?: LogicalExpression | null;
710
+ /**
711
+ *
712
+ * @type {Array<Value>}
713
+ * @memberof LogicalExpression
714
+ */
715
+ $eq?: Array<Value>;
716
+ /**
717
+ *
718
+ * @type {Array<Value>}
719
+ * @memberof LogicalExpression
720
+ */
721
+ $ne?: Array<Value>;
722
+ /**
723
+ *
724
+ * @type {Array<Value>}
725
+ * @memberof LogicalExpression
726
+ */
727
+ $gt?: Array<Value>;
728
+ /**
729
+ *
730
+ * @type {Array<Value>}
731
+ * @memberof LogicalExpression
732
+ */
733
+ $ge?: Array<Value>;
734
+ /**
735
+ *
736
+ * @type {Array<Value>}
737
+ * @memberof LogicalExpression
738
+ */
739
+ $lt?: Array<Value>;
740
+ /**
741
+ *
742
+ * @type {Array<Value>}
743
+ * @memberof LogicalExpression
744
+ */
745
+ $le?: Array<Value>;
746
+ /**
747
+ *
748
+ * @type {Array<StringValue>}
749
+ * @memberof LogicalExpression
750
+ */
751
+ $contains?: Array<StringValue>;
752
+ /**
753
+ *
754
+ * @type {Array<StringValue>}
755
+ * @memberof LogicalExpression
756
+ */
757
+ '$starts-with'?: Array<StringValue>;
758
+ /**
759
+ *
760
+ * @type {Array<StringValue>}
761
+ * @memberof LogicalExpression
762
+ */
763
+ '$ends-with'?: Array<StringValue>;
764
+ /**
765
+ *
766
+ * @type {Array<StringValue>}
767
+ * @memberof LogicalExpression
768
+ */
769
+ $regex?: Array<StringValue>;
770
+ /**
771
+ *
772
+ * @type {boolean}
773
+ * @memberof LogicalExpression
774
+ */
775
+ $boolean?: boolean;
776
+ }
777
+ /**
778
+ *
779
+ * @export
780
+ * @interface MatchExpression
781
+ */
782
+ export interface MatchExpression {
783
+ /**
784
+ *
785
+ * @type {Array<MatchExpression>}
786
+ * @memberof MatchExpression
787
+ */
788
+ $match?: Array<MatchExpression>;
789
+ /**
790
+ *
791
+ * @type {Array<Value>}
792
+ * @memberof MatchExpression
793
+ */
794
+ $eq?: Array<Value>;
795
+ /**
796
+ *
797
+ * @type {Array<Value>}
798
+ * @memberof MatchExpression
799
+ */
800
+ $ne?: Array<Value>;
801
+ /**
802
+ *
803
+ * @type {Array<Value>}
804
+ * @memberof MatchExpression
805
+ */
806
+ $gt?: Array<Value>;
807
+ /**
808
+ *
809
+ * @type {Array<Value>}
810
+ * @memberof MatchExpression
811
+ */
812
+ $ge?: Array<Value>;
813
+ /**
814
+ *
815
+ * @type {Array<Value>}
816
+ * @memberof MatchExpression
817
+ */
818
+ $lt?: Array<Value>;
819
+ /**
820
+ *
821
+ * @type {Array<Value>}
822
+ * @memberof MatchExpression
823
+ */
824
+ $le?: Array<Value>;
825
+ /**
826
+ *
827
+ * @type {Array<StringValue>}
828
+ * @memberof MatchExpression
829
+ */
830
+ $contains?: Array<StringValue>;
831
+ /**
832
+ *
833
+ * @type {Array<StringValue>}
834
+ * @memberof MatchExpression
835
+ */
836
+ '$starts-with'?: Array<StringValue>;
837
+ /**
838
+ *
839
+ * @type {Array<StringValue>}
840
+ * @memberof MatchExpression
841
+ */
842
+ '$ends-with'?: Array<StringValue>;
843
+ /**
844
+ *
845
+ * @type {Array<StringValue>}
846
+ * @memberof MatchExpression
847
+ */
848
+ $regex?: Array<StringValue>;
849
+ /**
850
+ *
851
+ * @type {boolean}
852
+ * @memberof MatchExpression
853
+ */
854
+ $boolean?: boolean;
855
+ }
680
856
  /**
681
857
  *
682
858
  * @export
@@ -859,6 +1035,70 @@ export declare const ProtocolInformationSecurityAttributesInnerTypeEnum: {
859
1035
  readonly W3CDid: "W3C_DID";
860
1036
  };
861
1037
  export type ProtocolInformationSecurityAttributesInnerTypeEnum = typeof ProtocolInformationSecurityAttributesInnerTypeEnum[keyof typeof ProtocolInformationSecurityAttributesInnerTypeEnum];
1038
+ /**
1039
+ *
1040
+ * @export
1041
+ * @interface Query
1042
+ */
1043
+ export interface Query {
1044
+ /**
1045
+ *
1046
+ * @type {string}
1047
+ * @memberof Query
1048
+ */
1049
+ $select?: string;
1050
+ /**
1051
+ *
1052
+ * @type {LogicalExpression}
1053
+ * @memberof Query
1054
+ */
1055
+ $condition: LogicalExpression | null;
1056
+ }
1057
+ /**
1058
+ *
1059
+ * @export
1060
+ * @interface QueryResultAssetAdministrationShellDescriptor
1061
+ */
1062
+ export interface QueryResultAssetAdministrationShellDescriptor {
1063
+ /**
1064
+ *
1065
+ * @type {QueryResultAssetAdministrationShellDescriptorPagingMetadata}
1066
+ * @memberof QueryResultAssetAdministrationShellDescriptor
1067
+ */
1068
+ paging_metadata: QueryResultAssetAdministrationShellDescriptorPagingMetadata;
1069
+ /**
1070
+ *
1071
+ * @type {Array<AssetAdministrationShellDescriptor>}
1072
+ * @memberof QueryResultAssetAdministrationShellDescriptor
1073
+ */
1074
+ result?: Array<AssetAdministrationShellDescriptor>;
1075
+ }
1076
+ /**
1077
+ *
1078
+ * @export
1079
+ * @interface QueryResultAssetAdministrationShellDescriptorPagingMetadata
1080
+ */
1081
+ export interface QueryResultAssetAdministrationShellDescriptorPagingMetadata {
1082
+ /**
1083
+ *
1084
+ * @type {string}
1085
+ * @memberof QueryResultAssetAdministrationShellDescriptorPagingMetadata
1086
+ */
1087
+ cursor?: string;
1088
+ /**
1089
+ *
1090
+ * @type {string}
1091
+ * @memberof QueryResultAssetAdministrationShellDescriptorPagingMetadata
1092
+ */
1093
+ resultType?: QueryResultAssetAdministrationShellDescriptorPagingMetadataResultTypeEnum;
1094
+ }
1095
+ /**
1096
+ * @export
1097
+ */
1098
+ export declare const QueryResultAssetAdministrationShellDescriptorPagingMetadataResultTypeEnum: {
1099
+ readonly AssetAdministrationShellDescriptor: "AssetAdministrationShellDescriptor";
1100
+ };
1101
+ export type QueryResultAssetAdministrationShellDescriptorPagingMetadataResultTypeEnum = typeof QueryResultAssetAdministrationShellDescriptorPagingMetadataResultTypeEnum[keyof typeof QueryResultAssetAdministrationShellDescriptorPagingMetadataResultTypeEnum];
862
1102
  /**
863
1103
  *
864
1104
  * @export
@@ -975,6 +1215,31 @@ export interface SpecificAssetId {
975
1215
  */
976
1216
  externalSubjectId?: Reference;
977
1217
  }
1218
+ /**
1219
+ *
1220
+ * @export
1221
+ * @interface StringValue
1222
+ */
1223
+ export interface StringValue {
1224
+ /**
1225
+ *
1226
+ * @type {string}
1227
+ * @memberof StringValue
1228
+ */
1229
+ $field?: string;
1230
+ /**
1231
+ *
1232
+ * @type {string}
1233
+ * @memberof StringValue
1234
+ */
1235
+ $strVal?: string;
1236
+ /**
1237
+ *
1238
+ * @type {Value}
1239
+ * @memberof StringValue
1240
+ */
1241
+ $strCast?: Value | null;
1242
+ }
978
1243
  /**
979
1244
  *
980
1245
  * @export
@@ -1036,6 +1301,115 @@ export interface SubmodelDescriptor {
1036
1301
  */
1037
1302
  extensions?: Array<Extension>;
1038
1303
  }
1304
+ /**
1305
+ *
1306
+ * @export
1307
+ * @interface Value
1308
+ */
1309
+ export interface Value {
1310
+ /**
1311
+ *
1312
+ * @type {string}
1313
+ * @memberof Value
1314
+ */
1315
+ $field?: string;
1316
+ /**
1317
+ *
1318
+ * @type {string}
1319
+ * @memberof Value
1320
+ */
1321
+ $strVal?: string;
1322
+ /**
1323
+ *
1324
+ * @type {number}
1325
+ * @memberof Value
1326
+ */
1327
+ $numVal?: number;
1328
+ /**
1329
+ *
1330
+ * @type {string}
1331
+ * @memberof Value
1332
+ */
1333
+ $hexVal?: string;
1334
+ /**
1335
+ *
1336
+ * @type {string}
1337
+ * @memberof Value
1338
+ */
1339
+ $dateTimeVal?: string;
1340
+ /**
1341
+ *
1342
+ * @type {string}
1343
+ * @memberof Value
1344
+ */
1345
+ $timeVal?: string;
1346
+ /**
1347
+ *
1348
+ * @type {boolean}
1349
+ * @memberof Value
1350
+ */
1351
+ $boolean?: boolean;
1352
+ /**
1353
+ *
1354
+ * @type {Value}
1355
+ * @memberof Value
1356
+ */
1357
+ $strCast?: Value | null;
1358
+ /**
1359
+ *
1360
+ * @type {Value}
1361
+ * @memberof Value
1362
+ */
1363
+ $numCast?: Value | null;
1364
+ /**
1365
+ *
1366
+ * @type {Value}
1367
+ * @memberof Value
1368
+ */
1369
+ $hexCast?: Value | null;
1370
+ /**
1371
+ *
1372
+ * @type {Value}
1373
+ * @memberof Value
1374
+ */
1375
+ $boolCast?: Value | null;
1376
+ /**
1377
+ *
1378
+ * @type {Value}
1379
+ * @memberof Value
1380
+ */
1381
+ $dateTimeCast?: Value | null;
1382
+ /**
1383
+ *
1384
+ * @type {Value}
1385
+ * @memberof Value
1386
+ */
1387
+ $timeCast?: Value | null;
1388
+ /**
1389
+ *
1390
+ * @type {string}
1391
+ * @memberof Value
1392
+ */
1393
+ $dayOfWeek?: string;
1394
+ /**
1395
+ *
1396
+ * @type {string}
1397
+ * @memberof Value
1398
+ */
1399
+ $dayOfMonth?: string;
1400
+ /**
1401
+ *
1402
+ * @type {string}
1403
+ * @memberof Value
1404
+ */
1405
+ $month?: string;
1406
+ /**
1407
+ *
1408
+ * @type {string}
1409
+ * @memberof Value
1410
+ */
1411
+ $year?: string;
1412
+ }
1039
1413
  /**
1040
1414
  *
1041
1415
  * @export
@@ -141,6 +141,12 @@ export const ProtocolInformationSecurityAttributesInnerTypeEnum = {
141
141
  RfcTlsa: 'RFC_TLSA',
142
142
  W3CDid: 'W3C_DID'
143
143
  };
144
+ /**
145
+ * @export
146
+ */
147
+ export const QueryResultAssetAdministrationShellDescriptorPagingMetadataResultTypeEnum = {
148
+ AssetAdministrationShellDescriptor: 'AssetAdministrationShellDescriptor'
149
+ };
144
150
  /**
145
151
  *
146
152
  * @export
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../../runtime';
13
- import type { AssetAdministrationShell, AssetInformation, BaseOperationResult, GetAssetAdministrationShellsResult, GetPathItemsResult, GetReferencesResult, GetSubmodelElementsMetadataResult, GetSubmodelElementsResult, GetSubmodelElementsValueResult, OperationRequest, OperationRequestValueOnly, OperationResult, OperationResultValueOnly, Reference, Submodel, SubmodelElement, SubmodelElementMetadata, SubmodelElementValue, SubmodelMetadata } from '../models/index';
13
+ import type { AssetAdministrationShell, AssetInformation, BaseOperationResult, GetAssetAdministrationShellsResult, GetPathItemsResult, GetReferencesResult, GetSubmodelElementsMetadataResult, GetSubmodelElementsResult, GetSubmodelElementsValueResult, OperationRequest, OperationRequestValueOnly, OperationResult, OperationResultValueOnly, Query, QueryResultAssetAdministrationShell, Reference, Submodel, SubmodelElement, SubmodelElementMetadata, SubmodelElementValue, SubmodelMetadata } from '../models/index';
14
14
  export interface DeleteAssetAdministrationShellByIdRequest {
15
15
  aasIdentifier: string;
16
16
  }
@@ -289,6 +289,11 @@ export interface PutThumbnailAasRepositoryRequest {
289
289
  fileName?: string;
290
290
  file?: Blob;
291
291
  }
292
+ export interface QueryAssetAdministrationShellsRequest {
293
+ limit?: number;
294
+ cursor?: string;
295
+ query?: Query;
296
+ }
292
297
  /**
293
298
  *
294
299
  */
@@ -703,6 +708,14 @@ export declare class AssetAdministrationShellRepositoryAPIApi extends runtime.Ba
703
708
  /**
704
709
  */
705
710
  putThumbnailAasRepository(requestParameters: PutThumbnailAasRepositoryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
711
+ /**
712
+ * Returns all Asset Administration Shells that conform to the input query
713
+ */
714
+ queryAssetAdministrationShellsRaw(requestParameters: QueryAssetAdministrationShellsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<QueryResultAssetAdministrationShell>>;
715
+ /**
716
+ * Returns all Asset Administration Shells that conform to the input query
717
+ */
718
+ queryAssetAdministrationShells(requestParameters?: QueryAssetAdministrationShellsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<QueryResultAssetAdministrationShell>;
706
719
  }
707
720
  /**
708
721
  * @export
@@ -1696,6 +1696,35 @@ export class AssetAdministrationShellRepositoryAPIApi extends runtime.BaseAPI {
1696
1696
  async putThumbnailAasRepository(requestParameters, initOverrides) {
1697
1697
  await this.putThumbnailAasRepositoryRaw(requestParameters, initOverrides);
1698
1698
  }
1699
+ /**
1700
+ * Returns all Asset Administration Shells that conform to the input query
1701
+ */
1702
+ async queryAssetAdministrationShellsRaw(requestParameters, initOverrides) {
1703
+ const queryParameters = {};
1704
+ if (requestParameters['limit'] != null) {
1705
+ queryParameters['limit'] = requestParameters['limit'];
1706
+ }
1707
+ if (requestParameters['cursor'] != null) {
1708
+ queryParameters['cursor'] = requestParameters['cursor'];
1709
+ }
1710
+ const headerParameters = {};
1711
+ headerParameters['Content-Type'] = 'application/json';
1712
+ const response = await this.request({
1713
+ path: `/query/shells`,
1714
+ method: 'POST',
1715
+ headers: headerParameters,
1716
+ query: queryParameters,
1717
+ body: requestParameters['query'],
1718
+ }, initOverrides);
1719
+ return new runtime.JSONApiResponse(response);
1720
+ }
1721
+ /**
1722
+ * Returns all Asset Administration Shells that conform to the input query
1723
+ */
1724
+ async queryAssetAdministrationShells(requestParameters = {}, initOverrides) {
1725
+ const response = await this.queryAssetAdministrationShellsRaw(requestParameters, initOverrides);
1726
+ return await response.value();
1727
+ }
1699
1728
  }
1700
1729
  /**
1701
1730
  * @export