basyx-typescript-sdk 0.1.11 → 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/README.md +13 -0
- package/bundle/index.js +157 -108
- package/bundle/index.js.map +1 -1
- package/dist/clients/AasRepositoryClient.d.ts +78 -79
- package/dist/clients/AasRepositoryClient.js +115 -107
- package/dist/index.d.ts +2 -0
- package/dist/index.js +2 -0
- package/dist/lib/base64Url.d.ts +32 -0
- package/dist/lib/base64Url.js +62 -0
- package/dist/models/aas-repository.d.ts +58 -3
- package/package.json +3 -2
|
@@ -1,158 +1,157 @@
|
|
|
1
1
|
import type { AssetAdministrationShell, AssetInformation, Reference } from '@aas-core-works/aas-core3.0-typescript/types';
|
|
2
|
-
import {
|
|
3
|
-
import { GetAllAssetAdministrationShellsResponse, getAllSubmodelReferencesResponse } from '../models/aas-repository';
|
|
2
|
+
import { AasIdentifierOptions, DeleteSubmodelReferenceByIdOptions, GetAllAssetAdministrationShellsOptions, GetAllAssetAdministrationShellsResponse, GetAllSubmodelReferencesOptions, GetAllSubmodelReferencesResponse, PostAssetAdministrationShellOptions, PostSubmodelReferenceOptions, PutAssetAdministrationShellOptions, PutAssetInformationOptions, PutThumbnailOptions } from '../models/aas-repository';
|
|
4
3
|
export declare class AasRepositoryClient {
|
|
5
4
|
/**
|
|
6
5
|
* Returns all Asset Administration Shells
|
|
7
6
|
*
|
|
8
|
-
* @async
|
|
9
7
|
* @function getAllAssetAdministrationShells
|
|
10
|
-
* @param
|
|
11
|
-
* @param
|
|
12
|
-
* @param
|
|
13
|
-
* @param
|
|
14
|
-
* @param
|
|
15
|
-
* @param
|
|
8
|
+
* @param {GetAllAssetAdministrationShellsOptions} options - Options object.
|
|
9
|
+
* @param {string} options.baseUrl - The API base URL
|
|
10
|
+
* @param {Headers} [options.headers] - Request headers
|
|
11
|
+
* @param {string[]} [options.assetIds] - A list of specific Asset identifiers. Every single value asset identifier is a base64-url-encoded
|
|
12
|
+
* @param {string} [options.idShort] - The Asset Administration Shell's IdShort
|
|
13
|
+
* @param {number} [options.limit] - The maximum number of elements in the response array
|
|
14
|
+
* @param {string} [options.cursor] - A server-generated identifier retrieved from pagingMetadata that specifies from which position the result listing should continue
|
|
16
15
|
* @returns {Promise<GetAllAssetAdministrationShellsResponse>} Requested Asset Administration Shells
|
|
17
16
|
*/
|
|
18
|
-
getAllAssetAdministrationShells(
|
|
17
|
+
getAllAssetAdministrationShells({ baseUrl, headers, assetIds, idShort, limit, cursor, }: GetAllAssetAdministrationShellsOptions): Promise<GetAllAssetAdministrationShellsResponse>;
|
|
19
18
|
/**
|
|
20
19
|
* Creates a new Asset Administration Shell
|
|
21
20
|
*
|
|
22
|
-
* @async
|
|
23
21
|
* @function postAssetAdministrationShell
|
|
24
|
-
* @param
|
|
25
|
-
* @param
|
|
26
|
-
* @param
|
|
22
|
+
* @param {PostAssetAdministrationShellOptions} options - Options object.
|
|
23
|
+
* @param {string} options.baseUrl - The API base URL
|
|
24
|
+
* @param {AssetAdministrationShell} options.assetAdministrationShell - Asset Administration Shell object
|
|
25
|
+
* @param {Headers} [options.headers] - Request headers
|
|
27
26
|
* @returns {Promise<AssetAdministrationShell>} Asset Administration Shell created successfully
|
|
28
27
|
*/
|
|
29
|
-
postAssetAdministrationShell(
|
|
28
|
+
postAssetAdministrationShell({ baseUrl, assetAdministrationShell, headers, }: PostAssetAdministrationShellOptions): Promise<AssetAdministrationShell>;
|
|
30
29
|
/**
|
|
31
30
|
* Deletes an Asset Administration Shell
|
|
32
31
|
*
|
|
33
|
-
* @async
|
|
34
32
|
* @function deleteAssetAdministrationShellById
|
|
35
|
-
* @param
|
|
36
|
-
* @param
|
|
37
|
-
* @param
|
|
33
|
+
* @param {AasIdentifierOptions} options - Options object.
|
|
34
|
+
* @param {string} options.baseUrl - The API base URL
|
|
35
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
36
|
+
* @param {Headers} [options.headers] - Request headers
|
|
38
37
|
* @returns {Promise<void>} Asset Administration Shell deleted successfully
|
|
39
38
|
*/
|
|
40
|
-
deleteAssetAdministrationShellById(
|
|
39
|
+
deleteAssetAdministrationShellById({ baseUrl, aasIdentifier, headers }: AasIdentifierOptions): Promise<void>;
|
|
41
40
|
/**
|
|
42
41
|
* Returns a specific Asset Administration Shell
|
|
43
42
|
*
|
|
44
|
-
* @async
|
|
45
43
|
* @function getAssetAdministrationShellById
|
|
46
|
-
* @param
|
|
47
|
-
* @param
|
|
48
|
-
* @param
|
|
44
|
+
* @param {AasIdentifierOptions} options - Options object.
|
|
45
|
+
* @param {string} options.baseUrl - The API base URL
|
|
46
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
47
|
+
* @param {Headers} [options.headers] - Request headers
|
|
49
48
|
* @returns {Promise<AssetAdministrationShell>} Requested Asset Administration Shell
|
|
50
49
|
*/
|
|
51
|
-
getAssetAdministrationShellById(
|
|
50
|
+
getAssetAdministrationShellById({ baseUrl, aasIdentifier, headers, }: AasIdentifierOptions): Promise<AssetAdministrationShell>;
|
|
52
51
|
/**
|
|
53
52
|
* Updates an existing Asset Administration Shell
|
|
54
53
|
*
|
|
55
|
-
* @async
|
|
56
54
|
* @function putAssetAdministrationShellById
|
|
57
|
-
* @param
|
|
58
|
-
* @param
|
|
59
|
-
* @param
|
|
60
|
-
* @param
|
|
55
|
+
* @param {PutAssetAdministrationShellOptions} options - Options object.
|
|
56
|
+
* @param {string} options.baseUrl - The API base URL
|
|
57
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
58
|
+
* @param {AssetAdministrationShell} options.assetAdministrationShell - Asset Administration Shell object
|
|
59
|
+
* @param {Headers} [options.headers] - Request headers
|
|
61
60
|
* @returns {Promise<void>} Asset Administration Shell updated successfully
|
|
62
61
|
*/
|
|
63
|
-
putAssetAdministrationShellById(
|
|
62
|
+
putAssetAdministrationShellById({ baseUrl, aasIdentifier, assetAdministrationShell, headers, }: PutAssetAdministrationShellOptions): Promise<void>;
|
|
64
63
|
/**
|
|
65
64
|
* Returns the Asset Information
|
|
66
65
|
*
|
|
67
|
-
* @async
|
|
68
66
|
* @function getAssetInformation
|
|
69
|
-
* @param
|
|
70
|
-
* @param
|
|
71
|
-
* @param
|
|
67
|
+
* @param {AasIdentifierOptions} options - Options object.
|
|
68
|
+
* @param {string} options.baseUrl - The API base URL
|
|
69
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
70
|
+
* @param {Headers} [options.headers] - Request headers
|
|
72
71
|
* @returns {Promise<AssetInformation>} Requested Asset Information
|
|
73
72
|
*/
|
|
74
|
-
getAssetInformation(
|
|
73
|
+
getAssetInformation({ baseUrl, aasIdentifier, headers }: AasIdentifierOptions): Promise<AssetInformation>;
|
|
75
74
|
/**
|
|
76
75
|
* Updates the Asset Information
|
|
77
76
|
*
|
|
78
|
-
* @async
|
|
79
77
|
* @function putAssetInformation
|
|
80
|
-
* @param
|
|
81
|
-
* @param
|
|
82
|
-
* @param
|
|
83
|
-
* @param
|
|
78
|
+
* @param {PutAssetInformationOptions} options - Options object.
|
|
79
|
+
* @param {string} options.baseUrl - The API base URL
|
|
80
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
81
|
+
* @param {AssetInformation} options.assetInformation - Asset Information object
|
|
82
|
+
* @param {Headers} [options.headers] - Request headers
|
|
84
83
|
* @returns {Promise<void>} Asset Information updated successfully
|
|
85
84
|
*/
|
|
86
|
-
putAssetInformation(
|
|
85
|
+
putAssetInformation({ baseUrl, aasIdentifier, assetInformation, headers, }: PutAssetInformationOptions): Promise<void>;
|
|
87
86
|
/**
|
|
88
87
|
* Deletes the Thumbnail
|
|
89
88
|
*
|
|
90
|
-
* @async
|
|
91
89
|
* @function deleteThumbnail
|
|
92
|
-
* @param
|
|
93
|
-
* @param
|
|
94
|
-
* @param
|
|
90
|
+
* @param {AasIdentifierOptions} options - Options object.
|
|
91
|
+
* @param {string} options.baseUrl - The API base URL
|
|
92
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
93
|
+
* @param {Headers} [options.headers] - Request headers
|
|
95
94
|
* @returns {Promise<void>} Thumbnail deletion successful
|
|
96
95
|
*/
|
|
97
|
-
deleteThumbnail(
|
|
96
|
+
deleteThumbnail({ baseUrl, aasIdentifier, headers }: AasIdentifierOptions): Promise<void>;
|
|
98
97
|
/**
|
|
99
98
|
* Returns the Thumbnail
|
|
100
99
|
*
|
|
101
|
-
* @async
|
|
102
100
|
* @function getThumbnail
|
|
103
|
-
* @param
|
|
104
|
-
* @param
|
|
105
|
-
* @param
|
|
101
|
+
* @param {AasIdentifierOptions} options - Options object.
|
|
102
|
+
* @param {string} options.baseUrl - The API base URL
|
|
103
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
104
|
+
* @param {Headers} [options.headers] - Request headers
|
|
106
105
|
* @returns {Promise<Blob | File>} The thumbnail of the Asset Information.
|
|
107
106
|
*/
|
|
108
|
-
getThumbnail(
|
|
107
|
+
getThumbnail({ baseUrl, aasIdentifier, headers }: AasIdentifierOptions): Promise<Blob | File>;
|
|
109
108
|
/**
|
|
110
109
|
* Updates the Thumbnail
|
|
111
110
|
*
|
|
112
|
-
* @async
|
|
113
111
|
* @function putThumbnail
|
|
114
|
-
* @param
|
|
115
|
-
* @param
|
|
116
|
-
* @param
|
|
117
|
-
* @param
|
|
112
|
+
* @param {PutThumbnailOptions} options - Options object.
|
|
113
|
+
* @param {string} options.baseUrl - The API base URL
|
|
114
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
115
|
+
* @param {AssetinformationThumbnailBody} options.thumbnail - Thumbnail to upload
|
|
116
|
+
* @param {Headers} [options.headers] - Request headers
|
|
118
117
|
* @returns {Promise<void>} Thumbnail updated successfully
|
|
119
118
|
*/
|
|
120
|
-
putThumbnail(
|
|
119
|
+
putThumbnail({ baseUrl, aasIdentifier, thumbnail, headers }: PutThumbnailOptions): Promise<void>;
|
|
121
120
|
/**
|
|
122
121
|
* Returns all submodel references
|
|
123
122
|
*
|
|
124
|
-
* @async
|
|
125
123
|
* @function getAllSubmodelReferences
|
|
126
|
-
* @param
|
|
127
|
-
* @param
|
|
128
|
-
* @param
|
|
129
|
-
* @param
|
|
130
|
-
* @param
|
|
131
|
-
* @
|
|
124
|
+
* @param {GetAllSubmodelReferencesOptions} options - Options object.
|
|
125
|
+
* @param {string} options.baseUrl - The API base URL
|
|
126
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
127
|
+
* @param {Headers} [options.headers] - Request headers
|
|
128
|
+
* @param {number} [options.limit] - The maximum number of elements in the response array
|
|
129
|
+
* @param {string} [options.cursor] - A server-generated identifier retrieved from pagingMetadata that specifies from which position the result listing should continue
|
|
130
|
+
* @returns {Promise<GetAllSubmodelReferencesResponse>} Requested submodel references
|
|
132
131
|
*/
|
|
133
|
-
getAllSubmodelReferences(
|
|
132
|
+
getAllSubmodelReferences({ baseUrl, aasIdentifier, headers, limit, cursor, }: GetAllSubmodelReferencesOptions): Promise<GetAllSubmodelReferencesResponse>;
|
|
134
133
|
/**
|
|
135
134
|
* Creates a submodel reference at the Asset Administration Shell
|
|
136
135
|
*
|
|
137
|
-
* @async
|
|
138
136
|
* @function postSubmodelReference
|
|
139
|
-
* @param
|
|
140
|
-
* @param
|
|
141
|
-
* @param
|
|
142
|
-
* @param
|
|
143
|
-
* @
|
|
137
|
+
* @param {PostSubmodelReferenceOptions} options - Options object.
|
|
138
|
+
* @param {string} options.baseUrl - The API base URL
|
|
139
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
140
|
+
* @param {Reference} options.submodelReference - Reference to the Submodel
|
|
141
|
+
* @param {Headers} [options.headers] - Request headers
|
|
142
|
+
* @returns {Promise<Reference>} Submodel reference created successfully
|
|
144
143
|
*/
|
|
145
|
-
postSubmodelReference(
|
|
144
|
+
postSubmodelReference({ baseUrl, aasIdentifier, submodelReference, headers, }: PostSubmodelReferenceOptions): Promise<Reference>;
|
|
146
145
|
/**
|
|
147
146
|
* Deletes the submodel reference from the Asset Administration Shell. Does not delete the submodel itself!
|
|
148
147
|
*
|
|
149
|
-
* @async
|
|
150
148
|
* @function deleteSubmodelReferenceById
|
|
151
|
-
* @param
|
|
152
|
-
* @param
|
|
153
|
-
* @param
|
|
154
|
-
* @param
|
|
149
|
+
* @param {DeleteSubmodelReferenceByIdOptions} options - Options object.
|
|
150
|
+
* @param {string} options.baseUrl - The API base URL
|
|
151
|
+
* @param {string} options.aasIdentifier - The Asset Administration Shell's unique id
|
|
152
|
+
* @param {string} options.submodelIdentifier - The Submodel's unique id
|
|
153
|
+
* @param {Headers} [options.headers] - Request headers
|
|
155
154
|
* @returns {Promise<void>} Submodel reference deleted successfully
|
|
156
155
|
*/
|
|
157
|
-
deleteSubmodelReferenceById(
|
|
156
|
+
deleteSubmodelReferenceById({ baseUrl, aasIdentifier, submodelIdentifier, headers, }: DeleteSubmodelReferenceByIdOptions): Promise<void>;
|
|
158
157
|
}
|