Skip to content

Instantly share code, notes, and snippets.

@clakech
Last active August 29, 2015 14:06
Show Gist options
  • Save clakech/34aef266419a1bd9c131 to your computer and use it in GitHub Desktop.
Save clakech/34aef266419a1bd9c131 to your computer and use it in GitHub Desktop.
{
id: "4d49ca82",
model: {
href: "/foundation/v2/modelTypes/Product/models/140"
}
attribute: [
{
href: "/foundation/v2/attributes/title",
value: [
"Find the rabbit"
]
},
{
href: "/foundation/v2/attributes/images",
value: [
{
href: "/business/v2/media/images/b28551d4"
},
{
href: "/business/v2/media/images/dsfg879"
}
]
},
{
href: "/foundation/v2/attributes/relatives",
value: [
{
href: "/business/v2/families/b28551d4",
model: {
href: "/foundation/v2/modelTypes/Product/models/140"
},
attribute: [
{
href: "/foundation/v2/attributes/title",
value: [
"This is the voice"
]
}
]
},
{
href: "/business/v2/families/b2dfsg1d4",
model: {
href: "/foundation/v2/modelTypes/Product/models/142"
},
attribute: [
{
href: "/foundation/v2/attributes/title",
value: [
"Allez les bleus!"
]
}
]
}
]
}
]
}
@OlivierCroisier
Copy link

Alexandre Bertails était passé au Bordeaux JUG nous expliquer JSON-LD, une sorte de XML Schema adapté à JSON. Ca permet de définir la structure et le type des attributs de chaque entité, au sein d'un contexte particulier. Au moins avec ça, on sait ce qu'on parse.

http://json-ld.org/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment