# Interface IWorkflowTenant OptimaJet.Workflow.Api.IWorkflowTenant Defines a workflow tenant in a Workflow Engine Web API. In a single-tenant setup registered as a single instance with [WorkflowApiConstants.SingleTenantId](https://api.workflowengine.io/web-api/OptimaJet.Workflow.Api/WorkflowApiConstants/) as its only id. Namespace: [OptimaJet.Workflow.Api](https://api.workflowengine.io/web-api/OptimaJet.Workflow.Api/) ```csharp public interface IWorkflowTenant ``` ## Type Hierarchy - IWorkflowTenant Current type - Implementing types - [WorkflowTenant](https://api.workflowengine.io/web-api/OptimaJet.Workflow.Api/WorkflowTenant/) ## Properties `IReadOnlyCollection Ids { get; }` All logical tenant ids that map to this tenant instance. `WorkflowRuntime WorkflowRuntime { get; }` The workflow runtime instance for this tenant. `IDataProvider DataProvider { get; }` The data provider for this tenant. `WorkflowTenantLifecycleOwnership LifecycleOwnership { get; }` Lifecycle ownership of the tenant, indicating whether the tenant is managed by the workflow engine or externally. ## Methods `Task StartAsync()` Starts the tenant lifecycle before the tenant is published in the tenant registry. ### Returns | Type | Description | | --- | --- | | `Task` | | `Task ShutdownAsync()` Gracefully shuts down the tenant after it is removed from the tenant registry and no active snapshot uses it. ### Returns | Type | Description | | --- | --- | | `Task` | | [Previous IWorkflowRuntimeConfigurator](https://api.workflowengine.io/web-api/OptimaJet.Workflow.Api/IWorkflowRuntimeConfigurator/) [Next IWorkflowTenantFactory](https://api.workflowengine.io/web-api/OptimaJet.Workflow.Api/IWorkflowTenantFactory/)