[MGNLREST-219] Create rest endpoint that returns results from a template (ie FTL) Created: 18/Dec/19  Updated: 12/Apr/21

Status: Open
Project: Magnolia REST Framework
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Story Priority: Neutral
Reporter: Christopher Zimmermann Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)

 Description   

As a developer I need to create an endpoint that returns results generated by a template script, so that I can fulfill the complex headless requirements of my projects.

Notes

Headless projects can require advanced results that should be computed on the server rather then the client. Delivery endpoints only deliver content (stored in Magnolia and potentially elsewhere) - but cannot return calculated values or items based on a registry for example.

Using templates to generate REST response gives developers access to the full range of power in Magnolia - from FTL templating to templating functions to JS models, allowing them to solve any headless usecase.

A developer could do that in a regular Magnolia page now - but that is not ideal because it can be confusing for users of the pages app - and it is harder to setup for the developer because it depends on adding content, not just using light development. Also it makes controlling access better and more consistent with other REST endpoints.

These endpoints should work like the delivery endpoints in that they are simply configured in a light module.



 Comments   
Comment by Christopher Zimmermann [ 18/Dec/19 ]

Also might fulfill the requirement I've seen elsewhere of doing custom JCR queries in a delivery enpdoint. But maybe thats better handled as an improvement to the delivery endpoint.

Generated at Mon Feb 12 06:57:48 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.