Questions tagged [hateoas]

Hypermedia As The Engine Of Application State (HATEOAS) is a constraint of the REST application architecture.

The principle of HATEOAS is that a client interacts with a network application entirely through hypermedia provided dynamically by application servers. A REST client needs no prior knowledge about how to interact with any particular application or server beyond a generic understanding of hypermedia.

40 questions
64
votes
5 answers

What does HATEOAS offer for discoverability and decoupling besides ability to change your URL structure more or less freely?

Lately I've been reading about Hypermedia as the Engine of Application State (HATEOAS), the constraint that is claimed to make a web API "truly RESTful". It boils down to basically including links with every response to the possible transitions you…
Botond Balázs
  • 1,463
  • 2
  • 12
  • 13
38
votes
3 answers

What's the point with HATEOAS on the client-side?

As I currently understand HATEOAS is basically all about sending together with each response links with information about what to do next. One simple example is easily found on the internet: a banking system together with an account resource. The…
user1620696
  • 4,817
  • 7
  • 31
  • 46
22
votes
4 answers

What is the need for 'discoverability' in a REST API when the clients are not advanced enough to make use of it anyway?

The various talks I have watched and tutorials I scanned on REST seem to stress something called 'discoverability'. To my limited understanding, the term seems to mean that a client should be able to go to http://URL - and automatically get a list…
Aditya M P
  • 605
  • 5
  • 15
15
votes
5 answers

Is REST and HATEOAS a good architecture for web services?

If I understand correctly, REST was formalized by Roy Fielding as a descriptive model of the architecture of the web. AFAIK Fielding didn't claim REST was any good, he was just describing the de-facto architecture of the web. The web had already at…
JacquesB
  • 57,310
  • 21
  • 127
  • 176
11
votes
2 answers

What does "HATEOAS" have to do with Application State?

HATEOAS is an acronym for "Hypermedia As The Engine Of Application State". What is the "Engine of Application State" referring to, and particularly - how is "hypermedia" the engine of it? As far as I have been able to understand, HATEOAS, and…
GreenAsJade
  • 426
  • 2
  • 13
10
votes
3 answers

Are there strategies for discovering REST services using HATEOAS?

When building a REST service with the HATEOAS constraint, it's very easy to advertise the existence of resources through linking. You make a GET to the root of my site and I respond with the root document listing all the first-tier resources: { …
Paul Turner
  • 878
  • 6
  • 18
9
votes
2 answers

"Invalid operation" status code in a HATEOAS REST API

In a HATEOAS API links are returned which represent possible state transitions. A conforming client should just be retrieving and following those links, but if a non-conforming client is constructing URIs rather than following the supplied links…
FinnNk
  • 5,799
  • 3
  • 28
  • 32
8
votes
4 answers

Advantages of HATEOAS based RESTful service

There is a scenario, where we have two commercial applications that are so called REST based(java) but not HATEOAS compliant. Development activity is out-sourced to vendor Development phase of project is done and planning for functional testing. We…
mohet
  • 89
  • 6
7
votes
3 answers

HATEOAS vs Frontend app GUI

I've just found HATEOAS. I think I kind of understand what is stands for, but something is not clear to me. There is nowhere to be found how can I create the consuming client in HTML. I can imagine that for some links I will generate buttons, for…
Zveratko
  • 179
  • 4
5
votes
4 answers

How to expose field constraints using HATEOAS?

For example we have entity object: { "id": 10, "name": "First object", "status": "new", "manager_id": 200, "links": [ { "href": "self", "type" : "PUT", } ] } How can the API express…
mikhail
  • 163
  • 3
5
votes
1 answer

Does discoverability in HATEOAS require the information must be machine readable, or can it just be human readable?

I'm trying to understand the concepts of HATEOAS (Hypermedia As The Engine Of Application State) in REST. The following have been very useful: What does HATEOAS offer for discoverability and decoupling besides ability to change your URL structure…
Simon Elms
  • 427
  • 4
  • 11
4
votes
3 answers

HATEOAS APIs and front end development

We are developing a tool from scratch based on a Spring backend and VueJs frontend. I am primarily working on the backend and came to know about the HATEOAS principle of developing REST APIs and adopted it. I will confess that one of the reasons for…
4
votes
3 answers

Why do RESTful services that implement HATEOAS provide a self-relationship link?

I'm learning about HATEOAS and I noticed that every implementation always seems to implement a self-relationship first. For example a common response object might look like { title: "The Wonderful Wizard of Oz", author: "L. Frank Baum" links:…
3
votes
4 answers

What's the ideal way to send a success message in the response of a HATEOAS Rest Api?

I am using HATEOAS architecture in my rest application and want to send internationalized success message that will be directly consumed by the client. I know we can just add a key in the response but want to know what is the ideal way…
3
votes
3 answers

HATEOAS links with client defined parameters, how to represent?

I'm wondering how best to model in a HATEOAS based API links that allow the client to set parameters. E.g. imagine a search response that returns a list of producst and then refinements that can be performed on them: { "results" : { ... …
Sutty1000
  • 1,379
  • 1
  • 12
  • 15
1
2 3