Interface IConfigurationApi
Namespace: Casewhere.Runtime.DSL.Api
Assembly: Casewhere.Runtime.dll
Get all products
public interface IConfigurationApi : IDslApi
Implements
Extension Methods
ObjectExtension.ConvertToBsonValue(object), EnumExtensions.DeepClone<IConfigurationApi>(IConfigurationApi)
Examples
var configurationApi = ctx.Use<IConfigurationApi>();
var products = configurationApi.GetProducts();
Methods
GetApiEndpoint()
Get the worker API endpoint.
string GetApiEndpoint()
Returns
The API endpoint.
Examples
var configurationApi = ctx.Use<IConfigurationApi>();
var apiEndpoint = configurationApi.GetApiEndpoint();
Log.Info("GetApiEndpoint: {apiEndpoint}", apiEndpoint);
// Log show: GetApiEndpoint: "https://api-local.casewhere.com/api/v0.1/"
GetDataClassByName(string)
Get data class by name.
DslDataClass GetDataClassByName(string name)
Parameters
name
string
The name of the data class.
Returns
The data class with the specified name.
GetDataClassNameById(Guid)
Get data class name by ID.
string GetDataClassNameById(Guid id)
Parameters
id
Guid
The ID of the data class.
Returns
The name of the data class with the specified ID.
GetDataClasses()
Get all data classes
IList<DslDataClass> GetDataClasses()
Returns
A set of data classes
GetDataClassesByProduct(string)
Get data classes by product
IList<DslDataClass> GetDataClassesByProduct(string productName)
Parameters
productName
string
Product name
Returns
A set of data classes
GetDataClassesByTag(string)
Get data classes by tag
IList<DslDataClass> GetDataClassesByTag(string tag)
Parameters
tag
string
Tag
Returns
A set of data classes
GetDataSourceByName(string)
Get data source with the specified name.
DslDataSource GetDataSourceByName(string name)
Parameters
name
string
Name of data source.
Returns
A single data source.
GetDataSources()
Get all existing data sources in our system.
IList<DslDataSource> GetDataSources()
Returns
A set of data sources
GetDataSourcesByProduct(string)
Get data sources by a product
IList<DslDataSource> GetDataSourcesByProduct(string productName)
Parameters
productName
string
Product Name
Returns
A set of data sources
GetDataSourcesByTag(string)
Get data sources by a tag
IList<DslDataSource> GetDataSourcesByTag(string tag)
Parameters
tag
string
Tag argument specifies tag name is based on filtering
Returns
A set of data sources
GetDataTriggers()
Get all Data triggers
IList<DslDataTrigger> GetDataTriggers()
Returns
A list of Data triggers
GetDataTriggersByProduct(string)
Get all Data triggers assigned with a specified product name.
IList<DslDataTrigger> GetDataTriggersByProduct(string productName)
Parameters
productName
string
Product Name
Returns
A list of Data triggers
GetDataTriggersByTag(string)
Get all Data triggers assigned with a specified Tag.
IList<DslDataTrigger> GetDataTriggersByTag(string tag)
Parameters
tag
string
Tag
Returns
A list of Data triggers
GetEventTriggers()
Get all Event triggers
IList<DslEventTrigger> GetEventTriggers()
Returns
A list of Event triggers
GetEventTriggersByProduct(string)
Get all Event triggers assigned with a specified product name.
IList<DslEventTrigger> GetEventTriggersByProduct(string productName)
Parameters
productName
string
Product Name
Returns
A list of Event triggers
GetEventTriggersByTag(string)
Get all Event triggers assigned with a specified Tag.
IList<DslEventTrigger> GetEventTriggersByTag(string tag)
Parameters
tag
string
Tag
Returns
A list of Event triggers
GetFiles()
Get all system files with informations.
IList<DslFile> GetFiles()
Returns
List of DslFile
GetFilesByProduct(string)
Get system files with informations in provided product. If exist product, return suitable system files. Otherwise, return empty list.
IList<DslFile> GetFilesByProduct(string productName)
Parameters
productName
string
Name of exist product.
Returns
List of DslFile
GetFilesByTag(string)
Get system files with informations in provided tag. If exist product, return suitable system files. Otherwise, return empty list.
IList<DslFile> GetFilesByTag(string tag)
Parameters
tag
string
Tag of file.
Returns
List of DslFile
GetPages(Guid)
Get all pages with workerSiteId.
IList<DslWorkerSitePage> GetPages(Guid workerSiteId)
Parameters
workerSiteId
Guid
Id of WorkerSite
Returns
A list of pages
GetPages(string)
Get all pages with worker uri.
IList<DslWorkerSitePage> GetPages(string workerUri)
Parameters
workerUri
string
Worker uri
Returns
A list of pages
GetPlugins()
Get all system plugins with informations.
IList<DslPlugin> GetPlugins()
Returns
List of DslPlugin.
GetPluginsByProduct(string)
Get plugins with informations in provided product. If exist product, return suitable plugins. Otherwise, return empty list.
IList<DslPlugin> GetPluginsByProduct(string productName)
Parameters
productName
string
Name of exist product.
Returns
List of DslPlugin.
GetProducts()
Get all products with informations
IList<DslProduct> GetProducts()
Returns
List of DslProduct
GetRules()
Get all rules
IList<DslRule> GetRules()
Returns
set of rules
GetRulesByProduct(string)
Get rules by productName
IList<DslRule> GetRulesByProduct(string productName)
Parameters
productName
string
product Name
Returns
set of rules
GetRulesByProduct(string, string)
Get rules by product Name and Rule type
IList<DslRule> GetRulesByProduct(string productName, string type)
Parameters
productName
string
product Name
type
string
rule Type
Returns
set of rules, throws exception if Rule Type is invalid
GetRulesByType(string)
Get rules by type of rule
IList<DslRule> GetRulesByType(string type)
Parameters
type
string
type of rules
Returns
set of rules, throws exception if Rule Type is invalid
GetRuntimeApiEndPoint()
Get the worker runtime API endpoint.
string GetRuntimeApiEndPoint()
Returns
The runtime API endpoint.
Examples
var configurationApi = ctx.Use<IConfigurationApi>();
var runtimeApiEndPoint = configurationApi.GetRuntimeApiEndPoint();
Log.Info("GetRuntimeApiEndPoint: {runtimeApiEndPoint}", runtimeApiEndPoint);
// Log show: GetRuntimeApiEndPoint: "https://api-local.casewhere.com/external/v0.1/"
GetWebTriggers()
Get all Web triggers
IList<DslWebTrigger> GetWebTriggers()
Returns
A list of Web triggers
GetWebTriggersByProduct(string)
Get all Web triggers assigned with a specified product name.
IList<DslWebTrigger> GetWebTriggersByProduct(string productName)
Parameters
productName
string
Product Name
Returns
A list of Web trigger
GetWebTriggersByTag(string)
Get all Web triggers assigned with a specified Tag.
IList<DslWebTrigger> GetWebTriggersByTag(string tag)
Parameters
tag
string
Tag
Returns
A list of Web trigger
GetWidgetActions(string)
Get all widget actions with widgetId
IList<DslWidgetAction> GetWidgetActions(string widgetId)
Parameters
widgetId
string
Id of widget
Returns
A list of widget actions
GetWidgets(string)
Get all widgets with page name.
IList<DslWidget> GetWidgets(string pageName)
Parameters
pageName
string
Name of page
Returns
A list of widgets
GetWorkerSites()
Get all worker sites with informations.
IList<DslWorkerSite> GetWorkerSites()
Returns
set of worker sites.
GetWorkerSitesByProduct(string)
Get worker sites with informations in provided product.
IList<DslWorkerSite> GetWorkerSitesByProduct(string productName)
Parameters
productName
string
Name of product.
Returns
Set of worker sites.
GetWorkflowDefinitions()
Get all workflow definition
IList<DslWorkflowDefinition> GetWorkflowDefinitions()
Returns
a set of workflow definition
GetWorkflowDefinitionsByProduct(string)
Get workflow definitions by product Name
IList<DslWorkflowDefinition> GetWorkflowDefinitionsByProduct(string productName)
Parameters
productName
string
product Name
Returns
a set of workflow definition
GetWorkflowDefinitionsByTag(string)
Get workflow definitions by tag
IList<DslWorkflowDefinition> GetWorkflowDefinitionsByTag(string tag)
Parameters
tag
string
Tag
Returns
a set of workflow definition