This repository has been archived by the owner on Jan 9, 2023. It is now read-only.
This repository has been archived by the owner on Jan 9, 2023. It is now read-only.
Create new Tenant and Admin user #243
Open
Description
🚀 Feature Proposal
Add API to create new tenant and user.
Motivation
When a user starts HospitalRun (auto-hosted instance) or goes to app.hospitalrun.io
for the first time, it will be presented with a "create new user form". The route receives user base info and tenant info
Upon request, this route:
- adds user to CouchDB;
- creates a new database on CouchDB for the tenant, using tenant.name and adding unique code;
- adds base entities to the db, such as ICD10;
- sets permissions to the newly database for the user.
Example
{
"user": "cuzzo",
"password": "something_strong",
"tenant": {
"name": "",
"address": <standardAddressObject>,
},
...
}