1

I am newbie to using hypermedia rest API (on openproject).

I retrieved from HATEOAS (Hypermedia As The Engine Of Application State) with javascript and show the result to HTML but not known how.

Example for my api url:

http://<my_domain>/target/api/v3/projects/design/work_packages

I have followed https://www.chillyfacts.com/javascript-send-http-getpost-request-read-json-response but javascript only work for JSON, can't work for "HAL + JSON"

==> My Question:

  1. Can javascript work with HATEOAS?

    • (If have) Which libraries on javascript to use?

    • (if not) Which programming language work with hal+json?

  2. Which programming language for design HATEOAS on the server-side?

< This is my api in openproject >

Thanks!

Tank Min
  • 48
  • 5
  • HATEOAS basically describes the HTML/HTTP Internet around 1995. JavaScript is essentially a great example of a thing that the original REST paper was arguing *against*. People now who talk about "REST" really aren't talking about REST as originally envisioned. The term is essentially meaningless in 2020, and yes I know I'm making an iconoclastic statement. – Pointy Jul 14 '20 at 23:47
  • thanks for your info so much! – Tank Min Jul 15 '20 at 11:23

1 Answers1

1

I already have the answer! I have used angular2 programming language with the Typescript (https://angular.io) and saw:

  1. Very easy to render data from the Typescript (process the logic) to HTML
  2. The library for work with the HATEOAS API is the "ketting" (https://github.com/badgateway/ketting/wiki/Getting-Started)

==> So, this topic was resolved!

Tank Min
  • 48
  • 5