API-specifications

Open Product provides two API, one for Product’s and one for Producttype’s. Both of these API’s are to be a recommended standard as of ….. The specifications can be found below.

API

Specification version(s)

Product API

0.0.2

Producttype API

0.0.2

In addition, Open Product can work with Notificaties API. Open Product uses Open Notificaties by default but this can be disabled using NOTIFICATIONS_DISABLED (see Environment configuration reference).

REST API design rules

The Open Product API is compliant with most of the NLGov REST API Design Rules:

Functional rules

Functional Rules

Rule

Compliant

Remarks

core/naming-resources

Yes

core/naming-collections

Yes

core/interface-language

Yes

core/hide-implementation

Yes

core/http-safety

Yes

core/stateless

Yes

core/nested-child

Yes

  • Nested resources are used for translations of producttype & content (READ is done through the normal get action with the Accept-Language header).

  • Prijs, Link and Bestand can only exist in the context of a Producttype but are not nested and have their own endpoint.

  • Other resources that consist of a few fields are done nested within ProductType or Product itself (product document, producttype verzoektype, proces, actie, etc..)

core/resource-operations

Yes

core/doc-language

Yes

core/deprecation-schedule

No

core/transition-period

No

Old docker version are available

core/changelog

Yes

development changelog`_

core/geospatial

Yes

Not used

Technical rules

Technical Rules

Rule

Compliant

Remarks

core/no-trailing-slash

Yes

core/http-methods

Yes

core/doc-openapi

Yes

API spec

core/publish-openapi

Yes

core/uri-version

Yes

core/semver

Yes

core/version-header

Yes

core/transport-security

Partially

Open Product is missing the headers Cache-Control: no-store & Access-Control-Allow-Origin from API Design Rules Module: Transport Security