basyx-python-sdk icon indicating copy to clipboard operation
basyx-python-sdk copied to clipboard

server/app/interfaces/repository.py: Implement missing `/submodels` endpoints

Open moritzsommer opened this issue 6 months ago • 2 comments

Current Situation

Currently, several server endpoints under /submodels are not implemented:

"/$value", methods=["GET"], endpoint=self.not_implemented
"/$path", methods=["GET"], endpoint=self.not_implemented
"/<base64url:submodel_id>", methods=["PATCH"], endpoint=self.not_implemented

According to the Submodel Repository Service OpenAPI Specification, the GET /submodels/$value endpoint should return all Submodels in value only representation.

[...]
responses:
        '200':
          description: Requested Submodels
          content:
            application/json:
              schema:
                $ref: 'https://api.swaggerhub.com/domains/Plattform_i40/Part2-API-Schemas/V3.0.1#/components/schemas/GetSubmodelsValueResult'
[...]

The GET /submodels/$path endpoint should return all Submodels in their path notation.

[...]
responses:
        '200':
          description: Requested Submodels
          content:
            application/json:
              schema:
                $ref: 'https://api.swaggerhub.com/domains/Plattform_i40/Part2-API-Schemas/V3.0.1#/components/schemas/GetPathItemsResult'
[...]

The PATCH /submodels/{submodelIdentifier} endpoint should support the updating of existing submodels.

[...]
responses:
        '204':
          description: Submodel updated successfully
[...]

This issue specifies https://github.com/eclipse-basyx/basyx-python-sdk/issues/439.

Proposed Change

We should evaluate and, if feasible, implement the three missing GET /submodels/$value, GET /submodels/$path and PATCH /submodels/{submodelIdentifier} endpoints according to the specification.

moritzsommer avatar May 10 '26 12:05 moritzsommer

Related to #446

zrgt avatar Aug 28 '26 12:08 zrgt

Superseded by the regrouping by underlying mechanism (see #439):

  • GET /submodels/$value → #644
  • GET /submodels/$path → #643
  • PATCH /submodels/{submodelIdentifier} → #646

Closing in favor of these issues.

zrgt avatar Sep 24 '26 11:09 zrgt