{"id":22859940,"url":"https://github.com/reelyactive/json-silo","last_synced_at":"2025-04-30T17:46:20.128Z","repository":{"id":21738917,"uuid":"25060702","full_name":"reelyactive/json-silo","owner":"reelyactive","description":"Data silo for digital twins in context-aware physical spaces.  We believe in an open Internet of Things.","archived":false,"fork":false,"pushed_at":"2024-08-07T20:14:28.000Z","size":1569,"stargazers_count":9,"open_issues_count":1,"forks_count":5,"subscribers_count":13,"default_branch":"master","last_synced_at":"2025-04-18T16:39:22.830Z","etag":null,"topics":["digital-twins","json-ld","pareto-anywhere","personal-data-store","schema-org"],"latest_commit_sha":null,"homepage":"https://www.reelyactive.com/context-aware-physical-spaces/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/reelyactive.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null}},"created_at":"2014-10-11T02:41:22.000Z","updated_at":"2024-08-07T20:08:06.000Z","dependencies_parsed_at":"2023-01-13T21:39:27.205Z","dependency_job_id":null,"html_url":"https://github.com/reelyactive/json-silo","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reelyactive%2Fjson-silo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reelyactive%2Fjson-silo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reelyactive%2Fjson-silo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reelyactive%2Fjson-silo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/reelyactive","download_url":"https://codeload.github.com/reelyactive/json-silo/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251754235,"owners_count":21638481,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["digital-twins","json-ld","pareto-anywhere","personal-data-store","schema-org"],"created_at":"2024-12-13T09:08:29.559Z","updated_at":"2025-04-30T17:46:20.088Z","avatar_url":"https://github.com/reelyactive.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"json-silo\n=========\n\n\nA lightweight digital twins store and API for the IoT\n-----------------------------------------------------\n\nThe __json-silo__ is a digital twins store and an accessory module of [Pareto Anywhere](https://www.reelyactive.com/pareto/anywhere/) open source middleware for [context-aware physical spaces](https://www.reelyactive.com/context-aware-physical-spaces/).\n\n![Overview of json-silo](https://reelyactive.github.io/json-silo/images/overview.png)\n\nSpecifically, the __json-silo__ stores \"stories\" which are machine-readable representations of people, products, places, etc. in the form of JSON-LD and Schema.org.  Additionally, it provides a simple mechanism for file storage and retrieval, for any accompanying metadata such as images.  The __json-silo__ can run standalone, even on resource-constrained devices.\n\n\nInstallation\n------------\n\n    npm install json-silo\n\n\nHello json-silo!\n----------------\n\n    npm start\n\nBrowse to [localhost:3001/json-silo/](http://localhost:3001/json-silo/) and observe the json-silo logo.  Interact with the json-silo via its REST API.\n\n\nREST API\n--------\n\nThe __json-silo__'s REST API includes the following two base routes:\n- /stories _for retrieving/specifying digital twins_\n- /store _for storing and retrieving metadata such as /images_\n\n\n### POST /stories\n\nCreate a story.  The _id_ of the created story is provided in the response.\n\n#### Example request\n\n| Method | Route    | Content-Type     |\n|:-------|:---------|:-----------------|\n| POST   | /stories | application/json |\n\n    {\n      \"@context\": {\n        \"schema\": \"https://schema.org/\"\n      },\n      \"@graph\": [\n        {\n          \"@id\": \"person\",\n          \"@type\": \"schema:Person\",\n          \"schema:givenName\": \"barnowl\"\n        }\n      ]\n    }\n\n#### Example response\n\n    {\n      \"_meta\": {\n        \"message\": \"ok\",\n        \"statusCode\": 200\n      },\n      \"_links\": {\n        \"self\": {\n          \"href\": \"http://localhost:3000/stories\"\n        }\n      },\n      \"stories\": {\n        \"barnowl\": {\n          \"@context\": {\n            \"schema\": \"https://schema.org/\"\n          },\n          \"@graph\": [\n            {\n              \"@id\": \"person\",\n              \"@type\": \"schema:Person\",\n              \"schema:givenName\": \"barnowl\"\n            }\n          ]\n        }\n      }\n    }\n\n\n### GET /stories/{id}\n\nRetrieve the story with the given _id_.\n\n#### Example request\n\n| Method | Route            | Content-Type     |\n|:-------|:-----------------|:-----------------|\n| GET    | /stories/barnowl | application/json |\n\n#### Example response\n\n    {\n      \"_meta\": {\n        \"message\": \"ok\",\n        \"statusCode\": 200\n      },\n      \"_links\": {\n        \"self\": {\n          \"href\": \"http://localhost:3000/stories/barnowl\"\n        }\n      },\n      \"stories\": {\n        \"barnowl\": {\n          \"@context\": {\n            \"schema\": \"https://schema.org/\"\n          },\n          \"@graph\": [\n            {\n              \"@id\": \"person\",\n              \"@type\": \"schema:Person\",\n              \"schema:givenName\": \"barnowl\"\n            }\n          ]\n        }\n      }\n    }\n\n\n### POST /store/images\n\nUpload an image to the store.  The _id_ (modified filename) of the uploaded image is provided in the response.  The image is modified using [sharp](https://github.com/lovell/sharp) to conform to standard dimensions before it is stored on the filesystem.\n\n#### Example request\n\n| Method | Route         | Content-Type        |\n|:-------|:--------------|:--------------------|\n| POST   | /store/images | multipart/form-data |\n\n\n### GET /store/images/{id}\n\nRetrieve the image with the given _id_ (filename).\n\n#### Example request\n\n| Method | Route                      | Content-Type        |\n|:-------|:---------------------------|:--------------------|\n| POST   | /store/images/12345678.jpg | multipart/form-data |\n\n\nWhat's in a name?\n-----------------\n\nThe __json-silo__ is exactly that: a data silo for [JSON](https://en.wikipedia.org/wiki/JSON)!  Simple enough, right?  So why does it have a grain silo with a hockey mask for a mascot?\n\nAt reelyActive we've always been outspoken about the need for an open Internet of Things as opposed to a bunch of siloed applications.  In 2013, on social media we recycled the [\"More cowbell\" meme](https://en.wikipedia.org/wiki/More_cowbell) with an image of Will Ferrell banging on a grain silo with the caption [\"The Internet of Things does not need More Silo\"](https://reelyactive.github.io/images/moreSilo.jpg).  When it came time to create a mascot for the __json-silo__, we decided to start with that grain silo.\n\nNow, how do you visually represent JSON in association with a grain silo?  Sure, we could have slapped the official JSON logo on that silo, but where's the fun in that?  Instead, for those of us who grew up in the eighties, hearing \"JSON\" out of context (pun intended) evokes the image of [Jason Voorhees](https://en.wikipedia.org/wiki/Jason_Voorhees) from the Friday the 13th series of films, specifically the iconic hockey goaltender mask he wore.  Not only does that \"Jason\" mask make for a silly visual pun, it also gives a nod to our hometown heritage, where [Jacques Plante](https://en.wikipedia.org/wiki/Jacques_Plante) of the Montreal Canadiens was the first goaltender to wear such a mask full-time, which would later become standard practice.  We'd be pleased to see the use of personal data lockers become standard practice too.\n\n![json-silo logo](https://reelyactive.github.io/json-silo/images/json-silo-bubble.png)\n\n\nWhat's next?\n------------\n\n__json-silo__ v1.0.0 was released in August 2019, superseding all earlier versions, the latest of which remains available in the [release-0.5 branch](https://github.com/reelyactive/json-silo/tree/release-0.5) and as [json-silo@0.5.2 on npm](https://www.npmjs.com/package/json-silo/v/0.5.2).\n\n__json-silo__ v1.1.0 migrates to [ESMapDB](https://github.com/reelyactive/esmapdb) from [NeDB](https://github.com/louischatriot/nedb).  If upgrading from a previous version, any stored stories will need to be recreated.\n\n\nContributing\n------------\n\nDiscover [how to contribute](CONTRIBUTING.md) to this open source project which upholds a standard [code of conduct](CODE_OF_CONDUCT.md).\n\n\nSecurity\n--------\n\nConsult our [security policy](SECURITY.md) for best practices using this open source software and to report vulnerabilities.\n\n\nLicense\n-------\n\nMIT License\n\nCopyright (c) 2014-2024 [reelyActive](https://www.reelyactive.com)\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR \nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, \nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE \nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER \nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, \nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN \nTHE SOFTWARE.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freelyactive%2Fjson-silo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Freelyactive%2Fjson-silo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freelyactive%2Fjson-silo/lists"}