Closed BohnSeb closed 9 months ago
Hi @BohnSeb,
The API "Post /shells" only creates the AAS based on the payload. As the payload includes only the submodel references, the submodels need to be explicitely created via API "Post /submodels". In this API, you can provide the "aasIdentifier", i.e., AAS Id of the AAS to which the submodel needs to be added (Screenshot 1). After this step, you can try doanloading the package, which will include the submodels as well.
Please refer https://github.com/eclipse-aaspe/aasx-server/issues/224 for more details.
Screenshot 1:
When a Shell is created via a POST request to the /shells endpoint, there is also a package that get's created and can be viewed on the webUI of the blazor server. When you download this package via GET request and try to open it in the package explorer it doesn't contain the linked submodel of the shell. To fix this behaviour it would be nice to automatically include all refs of the shell into the AASX package as well. Another and maybe even cleaner solution would be to provide the possibility to add Submodels or even additional shells into an existing AASX package.