@hoodie/account-server
Version:
Account JSON API backed by PouchDB
52 lines (51 loc) • 1.03 kB
JSON
{
"links": {
"self": "http://localhost:80/session"
},
"data": {
"id": "cGF0LWRvZTpCQkZFMzg4MDqp7ppCNngda1JMi7XcyhtaUxf2nA",
"type": "session",
"relationships": {
"account": {
"links": {
"related": "http://localhost:80/session/account"
},
"data": {
"id": "userid123",
"type": "account"
}
}
}
},
"included": [
{
"id": "userid123",
"type": "account",
"attributes": {
"username": "pat-doe",
"roles": [
"mycustomrole"
]
},
"relationships": {
"profile": {
"links": {
"related": "http://localhost:80/session/account/profile"
},
"data": {
"id": "userid123-profile",
"type": "profile"
}
}
}
},
{
"id": "userid123-profile",
"type": "profile",
"attributes": {
"fullName": "pat Doe",
"email": "pat@example.com"
}
}
]
}