OpenWGA 7.11 - OpenWGA Concepts and Features
Design and development » REST web service » The REST APIsThe HDBModel API
The HDBModel API provides data of HDBModel-enabled data-driven apps in a way that is oriented at the models hierarchy. Just like the regular HDBModel API does for content stores the HDBModel REST API hides content management features that are not applicable for data-driven apps, like multi-language content, content types etc.
You find the HDBModel API under URI path /rest/v1/dbs/<databaseKey>/hdbmodel when it's enabled.
Operations and their URLs
Operation | URL | HTTP Method | Request Data |
---|---|---|---|
Storage: Retrieve content collection of root storage | /hdbmodel/{storageId} | GET | |
Storage: Retrieve content collection of child storage | ...Parent-Content-URL/{storageId} | GET | |
Content: Create content | ...Parent-Storage-URL | POST | { ... resource data ... } |
Content: Read/Update/Delete content | ...Parent-Storage-URL/{contentId} | GET/PUT/DELETE |
On PUT: { ... resource data ... } |
Content: Lookup by page key | /hdbmodel/$byPageKey/{pageKey} | GET | |
Content: Retrieve collection of content versions | ...Content-URL/$versions} | GET | |
Content: Retrieve a non-released content version | ...Content-URL/$versions/{versionNumber}} | GET | |
Content files: Retrieve files attachmed to a content | ...Parent-Content-URL/$files | GET | |
Content files: Read/create/update/delete files | ...Parent-Content-URL/$files/{$fileName} | GET/PUT/PUT/DELETE |
On PUT: Binary file data |
Content relation groups: Retrieve relation groups of a content | ...Parent-Content-URL/$relgroups | GET | |
Content relation groups: Read/create/update/delete relation groups | ...Parent-Content-URL/$relgroups/{groupName} | GET/PUT/PUT/DELETE |
On PUT: { ... resource data ... } |
Model: Retrieve model definition root | /hdbmodel/$model | GET | |
Model: Retrieve model definition for a content | /hdbmodel/$model/lookup?pageKey={pageKey} | GET |
Special resources
The HDBModel API also uses relation groups in with equal structure as described for the The CMS API.
Additionally there are model definition resources that are actually JSON serialisations of the definition tags used in hdb-model.xml.