Skip to main content

Witboost Computational Governance API (1.1.0)

The Witboost Computational Governance is a service responsible for managing policies and metrics that are used to evaluate resources.

It is a central service that allows the governance team to define policies and metrics that will check each resource in Witboost.

API Usage

The API allows the governance team to create, update, and delete policies and metrics programmatically.

It also allows the users of these APIs to evaluate resources against these policies and metrics.

In order to contact the Witboost Computational Governance endpoints, you must authenticate using a valid JWT token. For more information, check this page.

GovernancePlatform

All the governance platform related operations

Evaluate a resource against all policy that apply to its resource_type

Authorizations:
ServiceAccountAuth
Request Body schema: application/json
required

A resource to be evaluated

id
required
string

A unique identifier of the resource.

displayName
string
version
string

Version of the resource. This is an optional field that can be used to differentiate multiple versions of the same resource.

environment
required
string
resourceType
required
string
descriptor
required
string
labels
Array of strings

Labels to be attached to the evaluation report.

Responses

Request samples

Content type
application/json
{
  • "id": "string",
  • "displayName": "string",
  • "version": "string",
  • "environment": "string",
  • "resourceType": "string",
  • "descriptor": "string",
  • "labels": [
    ]
}

Response samples

Content type
application/json
{
  • "reportId": "string"
}

Registers a new Metric in the Witboost Computational Governance

Authorizations:
ServiceAccountAuth
Request Body schema: application/json
required

A metric object to be registered

name
required
string

Name of the metric. This is also used for display purposes.

description
required
string

Description of the metric

context
required
string (ContextEnum)
Enum: "global" "local"
strategy
required
string (StrategyEnum)
Enum: "default" "previous_vs_current" "none"

Execution strategy of the governance entity

engine
required
string (EngineEnum)
Enum: "cue" "remote" "governanceAgent" "none"
trigger
required
string (TriggerEnum)
Enum: "active" "passive"
timing
required
string (TimingEnum)
Enum: "deployment" "runtime"
interactionType
required
string (InteractionTypeEnum)
Enum: "user2user" "user2platform"
required
Array of objects (SelectorModel)
preprocessing
Array of strings
resourceType
required
string

Resource type compatible to this metric

tags
required
Array of strings

Descriptive tags to add contextual information on the metric

environment
required
string

Environment where this metric gets executed

cronExpression
string

Cron expression in Quartz-like syntax with 6 fields that go from seconds to day of week in the following order: Seconds (0-59), Minutes (0-59), Hour of Day (0-23), Day of Month (1-31), Month (1-12), Day Of Week (0-6 where 0 is Monday). The following special characters are not allowed: L, W, LW, #. Time zone: UTC

externalUrl
string

The external URL to be contacted to trigger the execution of the metric

object (DomainModel)
required
object (ThresholdModel)
additionalMetadata
required
string

Responses

Request samples

Content type
application/json
{
  • "name": "string",
  • "description": "string",
  • "context": "global",
  • "strategy": "default",
  • "engine": "cue",
  • "trigger": "active",
  • "timing": "deployment",
  • "interactionType": "user2user",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "resourceType": "string",
  • "tags": [
    ],
  • "environment": "string",
  • "cronExpression": "string",
  • "externalUrl": "string",
  • "domain": {
    },
  • "thresholds": {
    },
  • "additionalMetadata": "string"
}

Response samples

Content type
application/json
{
  • "id": "string",
  • "groupId": "string",
  • "status": "draft",
  • "name": "string",
  • "description": "string",
  • "context": "global",
  • "interactionType": "user2user",
  • "trigger": "active",
  • "timing": "deployment",
  • "version": 0,
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "tags": [
    ],
  • "externalUrl": "string",
  • "strategy": "default",
  • "engine": "cue",
  • "resourceType": "string",
  • "cueScript": "string",
  • "governanceAgentSpec": {
    },
  • "severity": "info",
  • "environment": "string",
  • "cronExpression": "string",
  • "thresholds": {
    },
  • "domain": {
    },
  • "additionalMetadata": "string"
}

Retrieves the registered metrics

Authorizations:
ServiceAccountAuth
query Parameters
id-in
string
Example: id-in=metric-1,metric-2

Filter by metric ids (comma-separated)

env
string
Example: env=development,production

Filter by policy environments (comma-separated)

text
string
Example: text=my metric description

Filter by name or description (case-insensitive, partial match)

status
string
Example: status=enabled,grace

Filter by statuses (comma-separated)

strategy
string
Example: strategy=default,previous_vs_current

Filter by strategy (comma-separated)

timing
string
Example: timing=deployment,runtime

Filter by timings (comma-separated)

trigger
string
Example: trigger=active,passive

Filter by triggers (comma-separated)

context
string
Example: context=global,local

Filter by contexts (comma-separated)

resource-type
string
Example: resource-type=dataproduct,biproject

Filter by resource-types (comma-separated)

sort-by
string
Default: "creation_time"
Enum: "id" "group_id" "version" "name" "description" "context" "strategy" "timing" "status" "creation_time" "update_time" "cron_expression" "interaction_type" "resource_type" "preprocessing" "engine" "trigger" "severity" "external_url" "environment" "domain"

Field name to sort by

sort-order
string
Default: "asc"
Enum: "asc" "desc"

Sort order

limit
integer
Default: 25

Maximum number of items to return

offset
integer
Default: 0

Number of items to skip

Responses

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

Updates a metric status in the Witboost Computational Governance

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

metric unique ID

Request Body schema: application/json
required

The desired status for the metric

status
required
string (StatusEnum)
Enum: "draft" "grace" "disabled_grace" "enabled" "disabled" "deprecated" "deleted"

Status of the governance entity

Responses

Request samples

Content type
application/json
{
  • "status": "draft"
}

Response samples

Content type
application/json
{
  • "id": "string",
  • "groupId": "string",
  • "status": "draft",
  • "name": "string",
  • "description": "string",
  • "context": "global",
  • "interactionType": "user2user",
  • "trigger": "active",
  • "timing": "deployment",
  • "version": 0,
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "tags": [
    ],
  • "externalUrl": "string",
  • "strategy": "default",
  • "engine": "cue",
  • "resourceType": "string",
  • "cueScript": "string",
  • "governanceAgentSpec": {
    },
  • "severity": "info",
  • "environment": "string",
  • "cronExpression": "string",
  • "thresholds": {
    },
  • "domain": {
    },
  • "additionalMetadata": "string"
}

Updates a metric

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

metric unique ID

Request Body schema: application/json
required

A metric object to be update

groupId
required
string
name
required
string

Name of the metric. This is also used for display purposes.

version
required
integer
description
required
string

Description of the metric

context
required
string (ContextEnum)
Enum: "global" "local"
strategy
required
string (StrategyEnum)
Enum: "default" "previous_vs_current" "none"

Execution strategy of the governance entity

engine
required
string (EngineEnum)
Enum: "cue" "remote" "governanceAgent" "none"
trigger
required
string (TriggerEnum)
Enum: "active" "passive"
timing
required
string (TimingEnum)
Enum: "deployment" "runtime"
interactionType
required
string (InteractionTypeEnum)
Enum: "user2user" "user2platform"
required
Array of objects (SelectorModel)
preprocessing
Array of strings
resourceType
required
string

Resource type compatible to this metric

tags
required
Array of strings

Descriptive tags to add contextual information on the metric

environment
required
string

Environment where this metric gets executed

cronExpression
string

Cron expression in Quartz-like syntax with 6 fields that go from seconds to day of week in the following order: Seconds (0-59), Minutes (0-59), Hour of Day (0-23), Day of Month (1-31), Month (1-12), Day Of Week (0-6 where 0 is Monday). The following special characters are not allowed: L, W, LW, #. Time zone: UTC

externalUrl
string

The external URL to be contacted to trigger the execution of the metric

object (DomainModel)
object (ThresholdModel)
additionalMetadata
required
string

Responses

Request samples

Content type
application/json
{
  • "groupId": "string",
  • "name": "string",
  • "version": 0,
  • "description": "string",
  • "context": "global",
  • "strategy": "default",
  • "engine": "cue",
  • "trigger": "active",
  • "timing": "deployment",
  • "interactionType": "user2user",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "resourceType": "string",
  • "tags": [
    ],
  • "environment": "string",
  • "cronExpression": "string",
  • "externalUrl": "string",
  • "domain": {
    },
  • "thresholds": {
    },
  • "additionalMetadata": "string"
}

Response samples

Content type
application/json
{
  • "id": "string",
  • "groupId": "string",
  • "status": "draft",
  • "name": "string",
  • "description": "string",
  • "context": "global",
  • "interactionType": "user2user",
  • "trigger": "active",
  • "timing": "deployment",
  • "version": 0,
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "tags": [
    ],
  • "externalUrl": "string",
  • "strategy": "default",
  • "engine": "cue",
  • "resourceType": "string",
  • "cueScript": "string",
  • "governanceAgentSpec": {
    },
  • "severity": "info",
  • "environment": "string",
  • "cronExpression": "string",
  • "thresholds": {
    },
  • "domain": {
    },
  • "additionalMetadata": "string"
}

Clones a metric and bumps its version

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

metric unique ID

Responses

Response samples

Content type
application/json
{
  • "id": "string",
  • "groupId": "string",
  • "status": "draft",
  • "name": "string",
  • "description": "string",
  • "context": "global",
  • "interactionType": "user2user",
  • "trigger": "active",
  • "timing": "deployment",
  • "version": 0,
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "tags": [
    ],
  • "externalUrl": "string",
  • "strategy": "default",
  • "engine": "cue",
  • "resourceType": "string",
  • "cueScript": "string",
  • "governanceAgentSpec": {
    },
  • "severity": "info",
  • "environment": "string",
  • "cronExpression": "string",
  • "thresholds": {
    },
  • "domain": {
    },
  • "additionalMetadata": "string"
}

Test a metric against its resource perimeter

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

Metric ID

Request Body schema: application/json
required

Additional options for the test

Array of objects (SelectorModel)

Additional selectors to restrict the resources perimeter

Array
description
required
string
path
required
string
values
required
Array of strings

Responses

Request samples

Content type
application/json
{
  • "filters": [
    ]
}

Response samples

Content type
application/json
{
  • "reportId": "string"
}

Push a set of evaluation results for a metric in the Governance Platform

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

passive metric unique ID

query Parameters
environment
required
string

Environment to which these evaluation correspond to

Request Body schema: application/json
required

A list of evaluation results to generate a report. Each result is the consequence of a metric evaluating a resource.

Important! If the provided resource is not already registered in WCG, it will be registered as a primary resource (i.e., a resource within the scope of a perimeter resolver) associated with the resource type of the given metric.

Array
required
object (PushResourceRequestModel)
required
object (MetricResultModel)

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
{
  • "id": "string",
  • "environment": "string",
  • "evaluationScope": "evaluation",
  • "evaluationResults": [
    ],
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "status": "completedWithSuccess"
}

Registers a new Policy in the Witboost Computational Governance

Authorizations:
ServiceAccountAuth
Request Body schema: application/json
required

A policy object to be registered

name
required
string

Name of the policy. This is also used for display purposes.

description
required
string

Description of the policy

context
required
string (ContextEnum)
Enum: "global" "local"
strategy
required
string (StrategyEnum)
Enum: "default" "previous_vs_current" "none"

Execution strategy of the governance entity

engine
required
string (EngineEnum)
Enum: "cue" "remote" "governanceAgent" "none"
trigger
required
string (TriggerEnum)
Enum: "active" "passive"
timing
required
string (TimingEnum)
Enum: "deployment" "runtime"
interactionType
required
string (InteractionTypeEnum)
Enum: "user2user" "user2platform"
required
Array of objects (SelectorModel)
preprocessing
Array of strings
resourceType
required
string

Resource type compatible to this policy

tags
required
Array of strings

Descriptive tags to add contextual information on the policy

environment
required
string

Environment where this policy gets executed

cronExpression
string

Cron expression in Quartz-like syntax with 6 fields that go from seconds to day of week in the following order: Seconds (0-59), Minutes (0-59), Hour of Day (0-23), Day of Month (1-31), Month (1-12), Day Of Week (0-6 where 0 is Monday). The following special characters are not allowed: L, W, LW, #. Time zone: UTC

externalUrl
string

If engine is remote, this field contains the external URL to be contacted to trigger the execution of the policy

cueScript
string

If engine is cue, this field contains the CUE script

object (GovernanceAgentSpecModel)
severity
required
string (SeverityEnum)
Enum: "info" "warning" "error"

Describes the severity of the governance entity in case of a failing condition

additionalMetadata
required
string

Responses

Request samples

Content type
application/json
{
  • "name": "string",
  • "description": "string",
  • "context": "global",
  • "strategy": "default",
  • "engine": "cue",
  • "trigger": "active",
  • "timing": "deployment",
  • "interactionType": "user2user",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "resourceType": "string",
  • "tags": [
    ],
  • "environment": "string",
  • "cronExpression": "string",
  • "externalUrl": "string",
  • "cueScript": "string",
  • "governanceAgentSpec": {
    },
  • "severity": "info",
  • "additionalMetadata": "string"
}

Response samples

Content type
application/json
{
  • "id": "string",
  • "groupId": "string",
  • "status": "draft",
  • "name": "string",
  • "description": "string",
  • "context": "global",
  • "interactionType": "user2user",
  • "trigger": "active",
  • "timing": "deployment",
  • "version": 0,
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "tags": [
    ],
  • "externalUrl": "string",
  • "strategy": "default",
  • "engine": "cue",
  • "resourceType": "string",
  • "cueScript": "string",
  • "governanceAgentSpec": {
    },
  • "severity": "info",
  • "environment": "string",
  • "cronExpression": "string",
  • "thresholds": {
    },
  • "domain": {
    },
  • "additionalMetadata": "string"
}

Retrieves the registered policies

Authorizations:
ServiceAccountAuth
query Parameters
id-in
string
Example: id-in=policy-1,policy-2

Filter by policy ids (comma-separated)

env
string
Example: env=development,production

Filter by policy environments (comma-separated)

text
string
Example: text=my policy description

Filter by name or description (case-insensitive, partial match)

status
string
Example: status=enabled,grace

Filter by statuses (comma-separated)

severity
string
Example: severity=warning,error

Filter by severities (comma-separated)

strategy
string
Example: strategy=default,previous_vs_current

Filter by strategy (comma-separated)

engine
string
Example: engine=cue,remote

Filter by engines (comma-separated)

timing
string
Example: timing=deployment,runtime

Filter by timings (comma-separated)

trigger
string
Example: trigger=active,passive

Filter by triggers (comma-separated)

context
string
Example: context=global,local

Filter by contexts (comma-separated)

resource-type
string
Example: resource-type=dataproduct,biproject

Filter by resource-types (comma-separated)

sort-by
string
Default: "creation_time"
Enum: "id" "group_id" "version" "name" "description" "context" "strategy" "timing" "status" "creation_time" "update_time" "cron_expression" "interaction_type" "resource_type" "preprocessing" "engine" "trigger" "severity" "external_url" "environment" "domain"

Field name to sort by

sort-order
string
Default: "asc"
Enum: "asc" "desc"

Sort order

limit
integer
Default: 25

Maximum number of items to return

offset
integer
Default: 0

Number of items to skip

Responses

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

Updates a policy status

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

policy unique ID

Request Body schema: application/json
required

The desired status for the policy

status
required
string (StatusEnum)
Enum: "draft" "grace" "disabled_grace" "enabled" "disabled" "deprecated" "deleted"

Status of the governance entity

Responses

Request samples

Content type
application/json
{
  • "status": "draft"
}

Response samples

Content type
application/json
{
  • "id": "string",
  • "groupId": "string",
  • "status": "draft",
  • "name": "string",
  • "description": "string",
  • "context": "global",
  • "interactionType": "user2user",
  • "trigger": "active",
  • "timing": "deployment",
  • "version": 0,
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "tags": [
    ],
  • "externalUrl": "string",
  • "strategy": "default",
  • "engine": "cue",
  • "resourceType": "string",
  • "cueScript": "string",
  • "governanceAgentSpec": {
    },
  • "severity": "info",
  • "environment": "string",
  • "cronExpression": "string",
  • "thresholds": {
    },
  • "domain": {
    },
  • "additionalMetadata": "string"
}

Test a policy against its resource perimeter or a given resource.

When the request body does not contain the "resource" object, the policy is tested against its resource perimeter. Otherwise, when the request body contains a valid "resource" object (with id, environment, resourceType and descriptor as required fields), the policy is tested only against this resource, ignoring of any additional filters

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

Policy ID

Request Body schema: application/json
required

Additional options for the test

Array of objects (SelectorModel)

Additional selectors to restrict the resources perimeter

object (ResourceEvaluationModel)

Responses

Request samples

Content type
application/json
Example

When the request body is empty, the policy is tested against its resource perimeter.

{ }

Response samples

Content type
application/json
{
  • "reportId": "string"
}

Updates a policy

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

policy unique ID

Request Body schema: application/json
required

A policy object to be update

groupId
required
string
name
required
string

Name of the policy. This is also used for display purposes.

version
required
integer
description
required
string

Description of the policy

context
required
string (ContextEnum)
Enum: "global" "local"
strategy
required
string (StrategyEnum)
Enum: "default" "previous_vs_current" "none"

Execution strategy of the governance entity

engine
required
string (EngineEnum)
Enum: "cue" "remote" "governanceAgent" "none"
trigger
required
string (TriggerEnum)
Enum: "active" "passive"
timing
required
string (TimingEnum)
Enum: "deployment" "runtime"
interactionType
required
string (InteractionTypeEnum)
Enum: "user2user" "user2platform"
required
Array of objects (SelectorModel)
preprocessing
Array of strings
resourceType
required
string

Resource type compatible to this policy

tags
required
Array of strings

Descriptive tags to add contextual information on the policy

environment
required
string

Environment where this policy gets executed

cronExpression
string

Cron expression in Quartz-like syntax with 6 fields that go from seconds to day of week in the following order: Seconds (0-59), Minutes (0-59), Hour of Day (0-23), Day of Month (1-31), Month (1-12), Day Of Week (0-6 where 0 is Monday). The following special characters are not allowed: L, W, LW, #. Time zone: UTC

externalUrl
string

If engine is remote, this field contains the external URL to be contacted to trigger the execution of the policy

cueScript
string

If engine is cue, this field contains the CUE script

object (GovernanceAgentSpecModel)
severity
required
string (SeverityEnum)
Enum: "info" "warning" "error"

Describes the severity of the governance entity in case of a failing condition

additionalMetadata
required
string

Responses

Request samples

Content type
application/json
{
  • "groupId": "string",
  • "name": "string",
  • "version": 0,
  • "description": "string",
  • "context": "global",
  • "strategy": "default",
  • "engine": "cue",
  • "trigger": "active",
  • "timing": "deployment",
  • "interactionType": "user2user",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "resourceType": "string",
  • "tags": [
    ],
  • "environment": "string",
  • "cronExpression": "string",
  • "externalUrl": "string",
  • "cueScript": "string",
  • "governanceAgentSpec": {
    },
  • "severity": "info",
  • "additionalMetadata": "string"
}

Response samples

Content type
application/json
{
  • "id": "string",
  • "groupId": "string",
  • "status": "draft",
  • "name": "string",
  • "description": "string",
  • "context": "global",
  • "interactionType": "user2user",
  • "trigger": "active",
  • "timing": "deployment",
  • "version": 0,
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "tags": [
    ],
  • "externalUrl": "string",
  • "strategy": "default",
  • "engine": "cue",
  • "resourceType": "string",
  • "cueScript": "string",
  • "governanceAgentSpec": {
    },
  • "severity": "info",
  • "environment": "string",
  • "cronExpression": "string",
  • "thresholds": {
    },
  • "domain": {
    },
  • "additionalMetadata": "string"
}

Clones a policy and bumps its version

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

policy unique ID

Responses

Response samples

Content type
application/json
{
  • "id": "string",
  • "groupId": "string",
  • "status": "draft",
  • "name": "string",
  • "description": "string",
  • "context": "global",
  • "interactionType": "user2user",
  • "trigger": "active",
  • "timing": "deployment",
  • "version": 0,
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "selectors": [
    ],
  • "preprocessing": [
    ],
  • "tags": [
    ],
  • "externalUrl": "string",
  • "strategy": "default",
  • "engine": "cue",
  • "resourceType": "string",
  • "cueScript": "string",
  • "governanceAgentSpec": {
    },
  • "severity": "info",
  • "environment": "string",
  • "cronExpression": "string",
  • "thresholds": {
    },
  • "domain": {
    },
  • "additionalMetadata": "string"
}

Push a set of evaluation results for a policy in the Governance Platform

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

passive policy unique ID

query Parameters
environment
required
string

Environment to which these evaluation correspond to

Request Body schema: application/json
required

A list of evaluation results to generate a report. Each result is the consequence of a policy evaluating a resource.

Important! If the provided resource is not already registered in WCG, it will be registered as a primary resource (i.e., a resource within the scope of a perimeter resolver) associated with the resource type of the given policy.

Array
required
object (PushResourceRequestModel)
required
object (PolicyResultModel)

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
{
  • "id": "string",
  • "environment": "string",
  • "evaluationScope": "evaluation",
  • "evaluationResults": [
    ],
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "status": "completedWithSuccess"
}

Get an evaluation report by ID

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

Report id

Responses

Response samples

Content type
application/json
{
  • "id": "string",
  • "environment": "string",
  • "evaluationScope": "evaluation",
  • "evaluationResults": [
    ],
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "status": "completedWithSuccess"
}

Get an evaluation report status by ID

Authorizations:
ServiceAccountAuth
path Parameters
id
required
string

Report id

Responses

Response samples

Content type
application/json
{
  • "id": "string",
  • "environment": "string",
  • "evaluationScope": "evaluation",
  • "creationTime": "2019-08-24T14:15:22Z",
  • "updateTime": "2019-08-24T14:15:22Z",
  • "status": "completedWithSuccess"
}

Find and schedule active policies with an attached cron expression

Authorizations:
ServiceAccountAuth

Responses

Response samples

Content type
application/json
{
  • "error": "string",
  • "code": "string",
  • "userMessage": "string",
  • "input": "string",
  • "inputErrorField": "string",
  • "moreInfo": {
    }
}

Gets the list of names of existing Resource Types Deprecated

Deprecation notice: Replaced by /v2/resource-types

Authorizations:
ServiceAccountAuth

Responses

Response samples

Content type
application/json
{
  • "resourceTypes": [
    ]
}

Registers or updates a resource type

Authorizations:
ServiceAccountAuth
Request Body schema: application/json
required
name
required
string

Unique resource type name and identifier

displayName
string

Resource type display name. It defaults to name if not specified

object

Information about the shape of descriptors of this resource type

object

Details about the service implementing the perimeter resolver API

cuePreprocessScript
string

Responses

Request samples

Content type
application/json
{
  • "name": "my-resource-type",
  • "displayName": "My Resource Type",
  • "descriptorConfiguration": {
    },
  • "resolverConfiguration": {
    },
  • "cuePreprocessScript": "string"
}

Response samples

Content type
application/json
{
  • "name": "my-resource-type",
  • "displayName": "My Resource Type",
  • "descriptorConfiguration": {
    },
  • "resolverConfiguration": {
    },
  • "cuePreprocessScript": "string"
}

Gets the list of the existing Resource types

Authorizations:
ServiceAccountAuth

Responses

Response samples

Content type
application/json
{
  • "resourceTypes": [
    ]
}

Retrieves the configuration of a resource type

Authorizations:
ServiceAccountAuth
path Parameters
resourceType
required
string
Example: my-resource-type

Resource type name

Responses

Response samples

Content type
application/json
{
  • "name": "my-resource-type",
  • "displayName": "My Resource Type",
  • "descriptorConfiguration": {
    },
  • "resolverConfiguration": {
    },
  • "cuePreprocessScript": "string"
}

Computes a list of policies with the highest failure rate in a given date interval

Authorizations:
ServiceAccountAuth
Request Body schema: application/json
required
environment
required
string
limit
required
integer [ 1 .. 50 ]
Default: 10

Maximum number of policies to be returned.

startDate
required
string <date-time>

Lower bound of the date interval (inclusive)

endDate
required
string <date-time>

Upper bound of the date interval (inclusive)

includePolicyDetails
required
boolean
Default: false

Whether to include full policy details in the results or just policy ids (faster)

Responses

Request samples

Content type
application/json
{
  • "environment": "string",
  • "limit": 10,
  • "startDate": "2019-08-24T14:15:22Z",
  • "endDate": "2019-08-24T14:15:22Z",
  • "includePolicyDetails": false
}

Response samples

Content type
application/json
[
  • {
    }
]

Computes policy execution stats

Authorizations:
ServiceAccountAuth
Request Body schema: application/json
required
environment
required
string
startDate
required
string <date-time>

Lower bound of the date interval (inclusive)

endDate
required
string <date-time>

Upper bound of the date interval (inclusive)

Responses

Request samples

Content type
application/json
{
  • "environment": "string",
  • "startDate": "2019-08-24T14:15:22Z",
  • "endDate": "2019-08-24T14:15:22Z"
}

Response samples

Content type
application/json
[
  • {
    }
]

Computes failed policy evaluation stats

Authorizations:
ServiceAccountAuth
Request Body schema: application/json
required
environment
required
string
startDate
required
string <date-time>

Lower bound of the date interval (inclusive)

endDate
required
string <date-time>

Upper bound of the date interval (inclusive)

reportLabels
Array of strings

If defined, only failed executions linked to an evaluation report containing all these labels will be included in the computation

Responses

Request samples

Content type
application/json
{
  • "environment": "string",
  • "startDate": "2019-08-24T14:15:22Z",
  • "endDate": "2019-08-24T14:15:22Z",
  • "reportLabels": [
    ]
}

Response samples

Content type
application/json
[
  • {
    }
]

Registers new resources

Registers the provided resources if not already registered. If a resource already exists, it will be left unmodified and will not be included in the response.

Authorizations:
ServiceAccountAuth
Request Body schema: application/json
required
Array of objects

Resources with a resource type among the ones registered in WCG. Their descriptor is directly provided by a perimeter resolver.

Array of objects

Resources derived from a primary resource (the origin resource). Their descriptor is not directly provided by a perimeter resolver, but it is derived by applying transformations to their origin's descriptor.

Responses

Request samples

Content type
application/json
{
  • "primaryResources": [
    ],
  • "derivedResources": [
    ]
}

Response samples

Content type
application/json
{
  • "registeredResources": [
    ]
}

Returns a registered resource

Authorizations:
ServiceAccountAuth
path Parameters
externalId
required
string
Example: urn:dmb:dp:my-domain:my-resource:0

Resource external id

query Parameters
environment
required
string
Example: environment=development

Resource environment

Responses

Response samples

Content type
application/json
{
  • "identifier": {
    },
  • "kind": "PRIMARY",
  • "resourceType": "dataproduct",
  • "originExternalId": "urn:dmb:dp:my-domain:my-origin-resource:0"
}

Updates the evaluation status of a resource

Updates the evaluation status of a resource in relation to a governance entity. If the evaluation status is not currently tracked, it will be registered.

Authorizations:
ServiceAccountAuth
path Parameters
externalId
required
string
Example: urn:dmb:dp:my-domain:my-resource:0

Resource external id

governanceEntityId
required
string
Example: 2b3a16c4-5b2a-49a3-8cb7-ecb35c9a1b0a

Governance entity id

query Parameters
environment
required
string
Example: environment=development

Resource environment

Request Body schema: application/json
required
object

If newValue is null (default), the result scheduling will be cancelled. The new result deadline is defined as follows:

  • if the current result deadline is defined and has expired (i.e., results are overdue), the new deadline can extend the previous one but cannot shorten it. Otherwise, the new deadline is computed starting from the current time and so it gets set in the future
  • if the current result deadline is defined and has not expired (i.e., is in the future), the new deadline is also computed starting from the current time
object

If newValue is null (default), the value will be cleared

Responses

Request samples

Content type
application/json
{
  • "resultScheduling": {
    },
  • "lastResultId": {
    }
}

Response samples

Content type
application/json
{
  • "identifier": {
    },
  • "resultScheduling": {
    },
  • "lastResultId": "3580fd57-c673-4682-891e-eccb20b7a2d4"
}

Retrieves the evaluation status of one or more resources

Authorizations:
ServiceAccountAuth
Request Body schema: application/json
required
required
object (FindResourceStatusRequestFilters)
required
object (FindResourceStatusRequestResultOptions)

Responses

Request samples

Content type
application/json
{
  • "filters": {
    },
  • "resultOptions": {
    }
}

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

Analyzes an evaluation report to update the evaluation status of one or more resources

Authorizations:
ServiceAccountAuth
path Parameters
reportId
required
string

Evaluation report id

Responses

Response samples

Content type
application/json
{
  • "errors": [
    ],
  • "code": "string",
  • "userMessage": "string",
  • "input": "string",
  • "inputErrorField": "string",
  • "moreInfo": {
    }
}