Use the Tenants API for manipulating Weavy tenants.


Some methods are long running and will return a reference to a job which you can use to get updated information about the progress of the job. Optionally you can supply a callback url which will get called once the long running job finishes.


The API exposes the following methods.

Method Path Description
GET /api/tenants Search for tenants.
GET /api/tenants/{id} Gets the tenant with the specified id.
GET /api/tenants/{name}/get Gets the tenant with the specified name.
PATCH /api/tenants/{id} Updates metadata about a tenant.
POST /api/tenants Create a tenant by deploying a build.
GET /api/tenants/{id}/appsettings Gets the appSettings in Azure for an tenant.
PUT /api/tenants/{id}/appsettings Sets the appSettings in Azure for a tenant.
POST /api/tenants/{id}/upgrade Ugrade a tenant by deploying a new build to it.
POST /api/tenants/{id}/backup Backs up the database for a tenant.
GET /api/tenants/{id}/stats Gets statistics about a tenant.
POST /api/tenants/{id}/delete Deletes a tenant along with all related Azure resources.
POST /api/tenants/{id}/start Starts a tenant in Azure.
POST /api/tenants/{id}/stop Stops an tenant in Azure.
POST /api/tenants/{id}/lock Locks a tenant to prevent accidental deletion.
POST /api/tenants/{id}/unlock Unlocks a tenant to enable deletion.
GET /api/tenants/{id}/retention Returns the long term retention policy for the database that belongs to the tenant.
PUT /api/tenants/{id}/retention Upserts the retention settings for the database.
POST /api/tenants/{id}/restore Restores the database using point-in-time restore or a specific long term backup.
GET /api/tenants/{name}/available Gets a value indicating if the tenant name is available or taken.
GET /api/tenants/{licenseKey}/profile Returns the publishing profile in XML format for the tenant with the supplied license key. See: https://docs.microsoft.com/en-us/visualstudio/deployment/tutorial-import-publish-settings-azure?view=vs-2019