Creating 3rd Generation Web APIs with Hydra

Creating 3rd Generation
Web APIs with Hydra
Markus Lanthaler
Graz University ofTechnology
Creating 3rd Generation Web APIs with Hydra
Level 0:The Swamp of POX
Level 1: Resources
Level 2: HTTPVerbs
Level 3: Hypermedia Controls
Using Web APIs is still challenging
- Layered system
Result: tightly coupled & brittle systems
REST + Linked Data: a match made!?
Semaphobia!?
Creating 3rd Generation Web APIs with Hydra
Creating 3rd Generation Web APIs with Hydra
Resource
Link
Form
Class
Operation
Hydra
Creating 3rd Generation Web APIs with Hydra
{
"id": "cso29ax",
"title": "WWW2013",
"description": "Presentation for dev track",
"is_open": true,
"created_at": "2012-11-26T04:49:44Z"
}
http://example.com/issues/cso29ax
http://example.com/issue/{id}/comments/
{
"id": "cso29ax",
"title": "WWW2013",
"description": "Presentation for dev track",
"is_open": true,
"created_at": "2012-11-26T04:49:44Z",
"comments": "/issues/cso29ax/comments/"
}
http://example.com/issues/cso29ax
{
"@context": "/ctx/context.jsonld",
"id": "cso29ax",
"title": "WWW2013",
"description": "Presentation for dev track",
"is_open": true,
"created_at": "2012-11-26T04:49:44Z",
"comments": "/issues/cso29ax/comments/"
}
http://example.com/issues/cso29ax
{
"@context": {
...
"is_open": "http://example.com/vocab#isOpen",
"comments": {
"@id": "http://example.com/vocab#comments",
"@type": "@id"
}
}
}
http://example.com/ctx/context.jsonld
{
"@context": "/ctx/context.jsonld",
"id": "cso29ax",
"title": "WWW2013",
"description": "Presentation for dev track",
"is_open": true,
"created_at": "2012-11-26T04:49:44Z",
"comments": "/issues/cso29ax/comments/"
}
http://example.com/issues/cso29ax
{
"@id": "#comments",
"@type": "hydra:Link",
...
}
{
"@id": "#comments",
"@type": "hydra:Link",
"supportedOperations": [
{
"@id": "#create-comment",
"@type": "hydra:CreateResourceOperation",
"label": "Creates a new comment",
"method": "POST",
"expects": "#Comment",
"returns": "#Comment"
}
]
}
{
"@id": "#Comment",
"@type": "hydra:Class",
"supportedProperties": [
{
"property": "#text",
"required": true,
"readonly": false,
"writeonly": false
}
]
}
Creating 3rd Generation Web APIs with Hydra
Hydra Console
Creating 3rd Generation Web APIs with Hydra
Creating 3rd Generation Web APIs with Hydra
Creating 3rd Generation Web APIs with Hydra
Creating 3rd Generation Web APIs with Hydra
© 2013, Markus Lanthaler. Some Rights Reserved.
http://creativecommons.org/licenses/by-nc-sa/3.0/
Thank You
Questions?
Markus Lanthaler
http://www.markus-lanthaler.com
@MarkusLanthaler
mail@markus-lanthaler.com
Image Credits
(1) http://www.flickr.com/photos/joeshlabotnik/3707230247/
(2) http://onlyhdwallpapers.com/high-definition-wallpaper/903850/
(4) http://www.flickr.com/photos/kaptainkobold/3203311346/
(6) http://www.flickr.com/photos/joyoflife/1570126182/
(8) http://en.wikipedia.org/wiki/The_Scream
(9) http://www.vonwong.com/ (with permission)
1 of 28

More Related Content

Viewers also liked(20)

A Deep Dive into JSON-LD and HydraA Deep Dive into JSON-LD and Hydra
A Deep Dive into JSON-LD and Hydra
Markus Lanthaler9.8K views
Developing FOSDEM CompanionDeveloping FOSDEM Companion
Developing FOSDEM Companion
cbeyls1.2K views
Limewood Event - VMware Limewood Event - VMware
Limewood Event - VMware
BlueChipICT746 views
System Center 2012 - January Licensing UpdateSystem Center 2012 - January Licensing Update
System Center 2012 - January Licensing Update
Softchoice Corporation1.8K views
Cassandra Introduction & FeaturesCassandra Introduction & Features
Cassandra Introduction & Features
Phil Peace951 views
SQL Server Performans İpuçlarıSQL Server Performans İpuçları
SQL Server Performans İpuçları
turgaysahtiyan7K views

Similar to Creating 3rd Generation Web APIs with Hydra(20)

Recently uploaded(20)

The Research Portal of Catalonia: Growing more (information) & more (services)The Research Portal of Catalonia: Growing more (information) & more (services)
The Research Portal of Catalonia: Growing more (information) & more (services)
CSUC - Consorci de Serveis Universitaris de Catalunya51 views
CXL at OCPCXL at OCP
CXL at OCP
CXL Forum183 views
ChatGPT and AI for Web DevelopersChatGPT and AI for Web Developers
ChatGPT and AI for Web Developers
Maximiliano Firtman152 views
Green Leaf Consulting: Capabilities DeckGreen Leaf Consulting: Capabilities Deck
Green Leaf Consulting: Capabilities Deck
GreenLeafConsulting170 views
Web Dev - 1 PPT.pdfWeb Dev - 1 PPT.pdf
Web Dev - 1 PPT.pdf
gdsczhcet48 views
METHOD AND SYSTEM FOR PREDICTING OPTIMAL LOAD FOR WHICH THE YIELD IS MAXIMUM ...METHOD AND SYSTEM FOR PREDICTING OPTIMAL LOAD FOR WHICH THE YIELD IS MAXIMUM ...
METHOD AND SYSTEM FOR PREDICTING OPTIMAL LOAD FOR WHICH THE YIELD IS MAXIMUM ...
Prity Khastgir IPR Strategic India Patent Attorney Amplify Innovation23 views

Creating 3rd Generation Web APIs with Hydra