{"action":"opened","issue":{"url":"https://api.github.com/repos/ssbc/scuttlebot/issues/233","labels_url":"https://api.github.com/repos/ssbc/scuttlebot/issues/233/labels{/name}","comments_url":"https://api.github.com/repos/ssbc/scuttlebot/issues/233/comments","events_url":"https://api.github.com/repos/ssbc/scuttlebot/issues/233/events","html_url":"https://github.com/ssbc/scuttlebot/issues/233","id":106128200,"number":233,"title":"using scuttlebot as a backend for a data api","user":{"login":"ahdinosaur","id":719605,"avatar_url":"https://avatars.githubusercontent.com/u/719605?v=3","gravatar_id":"","url":"https://api.github.com/users/ahdinosaur","html_url":"https://github.com/ahdinosaur","followers_url":"https://api.github.com/users/ahdinosaur/followers","following_url":"https://api.github.com/users/ahdinosaur/following{/other_user}","gists_url":"https://api.github.com/users/ahdinosaur/gists{/gist_id}","starred_url":"https://api.github.com/users/ahdinosaur/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ahdinosaur/subscriptions","organizations_url":"https://api.github.com/users/ahdinosaur/orgs","repos_url":"https://api.github.com/users/ahdinosaur/repos","events_url":"https://api.github.com/users/ahdinosaur/events{/privacy}","received_events_url":"https://api.github.com/users/ahdinosaur/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-09-12T04:21:01Z","updated_at":"2015-09-12T04:21:01Z","closed_at":null,"body":"to throw some spaghetti at my [suggested product angle](https://github.com/ssbc/scuttlebot/issues/146#issuecomment-103306434), i'm curious to see if it's possible and/or practical to use scuttlebot as a backend database, as with [holodex](https://github.com/open-app/holodex) [[demo](http://holodex.enspiral.com)] i'm [planning to re-build our data api](https://github.com/open-app/holodex/issues/80).\r\n\r\nin the interest of practicality, i'm not aiming to achieve the ssb utopia where every agent (person or group) manages their own keys, their own feed, :sunny: and :rainbow:. rather, there should be a spectrum from the current way apps are deployed (on public servers controlled by a single agent but isolated from other servers) to the utopia, so developers can slowly migrate their users without interrupting the existing service.\r\n\r\nsome terminology:\r\n\r\n- agent: a person or a group\r\n- member: an agent who is part of a group\r\n- host: an agent who runs a pub server that manages feeds for its members\r\n\r\n> [notes from a previous self:](https://github.com/open-app/core/blob/05a22ab1705a34fa74b2794ca2069aa46cca0d8d/notes.md)\r\n> - every agent should have complete control of their data and how it is shared. they have to trust their host (either them or a group they are a member of) who actually stores the data to enforce their control.\r\n> - i've been thinking about nodes as agents, which includes people or groups (or projects which i think are short-term groups). then, as not every agent wants to host themselves in the network, group agents can host their members. we can achieve federated querying amongst network-of-networks with http://linkeddatafragments.org/.\r\n\r\nin our current use case, [Enspiral](http://enspiral.com) would be a host agent for [the people and groups within Enspiral](http://holodex.enspiral.com). however, any of these members may be their own host, thus creating a federated mesh of hosts where each host has access to all the data of its recursive members. for the Holodex implementation, i imagine \"being a host\" would be running the Holodex app on a public server, where we use scuttlebot as a backend to handle data operations (on each agent's feed), replication (across hosts), and queries (linked data), which we use to export a standard http / websocket api interface.\r\n\r\nso, @dominictarr, some documentation on how to use scuttlebot as a data api backend would be magical. :sparkles: "}}