💾 Install • 🎮 Quick start • 🔧 Configuration • 😍 Acknowledgements • 🌐 Links • 👤 Contributing • 💼 License
🚧 Zenroom is a software part of the DECODE project about data-ownership and technological sovereignty. Our effort is that of improving people's awareness of how their data is processed by algorithms, as well facilitate the work of developers to create along privacy by design principles using algorithms that can be deployed in any situation without any change.
🚩 Table of Contents (click to expand)
git clone https://github.com/dyne/restroom
cd restroom
yarn install
To start using restroom you need to run the restroom server. Some configuration are needed first, look here to define your ENVIRONMENT VARIABLES before running the server.
Then run
yarn start
now all your zencode smart contracts are available as GET and POST
with the name of the file without the .zen
extension
(eg. random.zen
will be served as /api/random
endpoint)
When the server is run, the configured folder is loaded and parsed and a openapi (ex swagger) definition is serverd on the index page.
Each time you hit the /
index page, the openapi definitions are updated,
this means that when you add new contracts into the SMART_CONTRACTS
folder they automatically appear into the swagger definition and are testable via the GUI.
The client is not necessary since you can use the tool you want to make http GET/POST calls but is a handy tool to test the endpoints.
By running ./restroom-cli --help
you'll get the extensive documentation.
./restroom-cli get random
./restroom-cli get somezencode -c ./conf -d ./data.json -k ./keys.json
Restroom follows the Twelve factor app principles hence all the configuration are via Environment variables.
This is the entry point directory to place your zencodes to run.
NB. As per now all the contracts must end with the .zen
suffix and the result of the contract should be a valid JSON
The port to attach the server. default: 3000
The host to bind the server default: 0.0.0.0
SMART_CONTRACTS=/home/src/restroom/zencode
PORT=8000
HOST=127.0.0.1
Copyright © 2019 by Dyne.org foundation, Amsterdam
Designed, written and maintained by Puria Nafisi Azizi.
Special thanks to Jaromil for his special contributions and for the idea.
Image in README courtesy of Old book illustrations
Please first take a look at the Dyne.org - Contributor License Agreement then
- 🔀 FORK IT
- Create your feature branch
git checkout -b feature/branch
- Commit your changes
git commit -am 'Add some fooBar'
- Push to the branch
git push origin feature/branch
- Create a new Pull Request
- 🙏 Thank you
restroom - Easy REST API builder executing Zencode
Copyright (c) 2020 Dyne.org foundation, Amsterdam
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.