Table of Contents

Interface IConfigurationApi

Namespace: Casewhere.Runtime.DSL.Api
Assembly: Casewhere.Runtime.dll

Get all products

public interface IConfigurationApi : IDslApi

Implements

IDslApi

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

string

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

DslDataClass

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

string

The name of the data class with the specified ID.

GetDataClasses()

Get all data classes

IList<DslDataClass> GetDataClasses()

Returns

IList<DslDataClass>

A set of data classes

GetDataClassesByProduct(string)

Get data classes by product

IList<DslDataClass> GetDataClassesByProduct(string productName)

Parameters

productName string

Product name

Returns

IList<DslDataClass>

A set of data classes

GetDataClassesByTag(string)

Get data classes by tag

IList<DslDataClass> GetDataClassesByTag(string tag)

Parameters

tag string

Tag

Returns

IList<DslDataClass>

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

DslDataSource

A single data source.

GetDataSources()

Get all existing data sources in our system.

IList<DslDataSource> GetDataSources()

Returns

IList<DslDataSource>

A set of data sources

GetDataSourcesByProduct(string)

Get data sources by a product

IList<DslDataSource> GetDataSourcesByProduct(string productName)

Parameters

productName string

Product Name

Returns

IList<DslDataSource>

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

IList<DslDataSource>

A set of data sources

GetDataTriggers()

Get all Data triggers

IList<DslDataTrigger> GetDataTriggers()

Returns

IList<DslDataTrigger>

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

IList<DslDataTrigger>

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

IList<DslDataTrigger>

A list of Data triggers

GetEventTriggers()

Get all Event triggers

IList<DslEventTrigger> GetEventTriggers()

Returns

IList<DslEventTrigger>

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

IList<DslEventTrigger>

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

IList<DslEventTrigger>

A list of Event triggers

GetFiles()

Get all system files with informations.

IList<DslFile> GetFiles()

Returns

IList<DslFile>

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

IList<DslFile>

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

IList<DslFile>

List of DslFile

GetPages(Guid)

Get all pages with workerSiteId.

IList<DslWorkerSitePage> GetPages(Guid workerSiteId)

Parameters

workerSiteId Guid

Id of WorkerSite

Returns

IList<DslWorkerSitePage>

A list of pages

GetPages(string)

Get all pages with worker uri.

IList<DslWorkerSitePage> GetPages(string workerUri)

Parameters

workerUri string

Worker uri

Returns

IList<DslWorkerSitePage>

A list of pages

GetPlugins()

Get all system plugins with informations.

IList<DslPlugin> GetPlugins()

Returns

IList<DslPlugin>

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

IList<DslPlugin>

List of DslPlugin.

GetProducts()

Get all products with informations

IList<DslProduct> GetProducts()

Returns

IList<DslProduct>

List of DslProduct

GetRules()

Get all rules

IList<DslRule> GetRules()

Returns

IList<DslRule>

set of rules

GetRulesByProduct(string)

Get rules by productName

IList<DslRule> GetRulesByProduct(string productName)

Parameters

productName string

product Name

Returns

IList<DslRule>

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

IList<DslRule>

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

IList<DslRule>

set of rules, throws exception if Rule Type is invalid

GetRuntimeApiEndPoint()

Get the worker runtime API endpoint.

string GetRuntimeApiEndPoint()

Returns

string

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

IList<DslWebTrigger>

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

IList<DslWebTrigger>

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

IList<DslWebTrigger>

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

IList<DslWidgetAction>

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

IList<DslWidget>

A list of widgets

GetWorkerSites()

Get all worker sites with informations.

IList<DslWorkerSite> GetWorkerSites()

Returns

IList<DslWorkerSite>

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

IList<DslWorkerSite>

Set of worker sites.

GetWorkflowDefinitions()

Get all workflow definition

IList<DslWorkflowDefinition> GetWorkflowDefinitions()

Returns

IList<DslWorkflowDefinition>

a set of workflow definition

GetWorkflowDefinitionsByProduct(string)

Get workflow definitions by product Name

IList<DslWorkflowDefinition> GetWorkflowDefinitionsByProduct(string productName)

Parameters

productName string

product Name

Returns

IList<DslWorkflowDefinition>

a set of workflow definition

GetWorkflowDefinitionsByTag(string)

Get workflow definitions by tag

IList<DslWorkflowDefinition> GetWorkflowDefinitionsByTag(string tag)

Parameters

tag string

Tag

Returns

IList<DslWorkflowDefinition>

a set of workflow definition