官术网_书友最值得收藏!

HATEOAS

HATEOAS is a way that the client can interact with the response by navigating within it through the hierarchy in order to get complementary information.

For example, here the client makes a GET call to the order URI :

GET https://<HOST>/orders/1234

The response comes with a navigation link to the items within the 1234 order, as in the following code block:

{
id : 1234,
any-other-json-fields...,
links": [
{
"href": "1234/items",
"rel": "items",
"type" : "GET"
}
]
}

What happens here is that the link fields allow the client to navigate until 1234/items in order to see all the items that belong to the 1234 order.

主站蜘蛛池模板: 高唐县| 克山县| 仁化县| 武威市| 宁蒗| 金堂县| 昭苏县| 墨江| 昌都县| 文山县| 奎屯市| 太白县| 施秉县| 天柱县| 姜堰市| 蛟河市| 隆化县| 兴仁县| 亳州市| 凉城县| 张家港市| 绥阳县| 陆川县| 保定市| 正宁县| 义乌市| 澄城县| 新平| 建湖县| 宁陵县| 财经| 南康市| 安顺市| 洱源县| 辉南县| 肃宁县| 赤城县| 五原县| 海城市| 柳河县| 康乐县|