Automation API allows working with workflows and various trigger options.
npm install @dynatrace-sdk/client-automation

Manage and run workflows with the AutomationEngine API.
``bash`
npm install @dynatrace-sdk/client-automation
- Visit SDK for Typescript guide in the Dynatrace Developer
- Ask a question in the Dynatrace Community
This SDK is distributed under the Apache License, Version 2.0, see LICENSE for more information.
Full API reference for the latest version of the SDK is also available at the Dynatrace Developer.
`js`
import { actionExecutionsClient } from '@dynatrace-sdk/client-automation';
Required scope: automation:workflows:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this action execution. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|ActionExecution|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { actionExecutionsClient } from "@dynatrace-sdk/client-automation";
const data =
await actionExecutionsClient.getActionExecution({
id: "...",
});
`
Required scope: automation:workflows:read
Returns the log output of a specific ActionExecution.
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this action execution. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { actionExecutionsClient } from "@dynatrace-sdk/client-automation";
const data =
await actionExecutionsClient.getActionExecutionLog({
id: "...",
});
`
`js`
import { actionsSampleResultClient } from '@dynatrace-sdk/client-automation';
> ⚠️ Deprecated
Required scope: automation:workflows:read
#### Parameters
| Name | Type |
| --- | --- |
|config.actionIdentifier*required|string|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { actionsSampleResultClient } from "@dynatrace-sdk/client-automation";
const data =
await actionsSampleResultClient.getActionSampleResult({
actionIdentifier: "...",
});
`
`js`
import { businessCalendarsClient } from '@dynatrace-sdk/client-automation';
Required scope: automation:calendars:write
#### Parameters
| Name | Type |
| --- | --- |
|config.body*required|BusinessCalendarCreate|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|BusinessCalendarResponse|201||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { businessCalendarsClient } from "@dynatrace-sdk/client-automation";
const data =
await businessCalendarsClient.createBusinessCalendar({
body: { title: "..." },
});
`
Required scope: automation:calendars:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.id*required|string|A UUID string identifying this business calendar. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|204|No response body|
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { businessCalendarsClient } from "@dynatrace-sdk/client-automation";
const data =
await businessCalendarsClient.deleteBusinessCalendar({
id: "...",
});
`
Required scope: automation:calendars:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.body*required|DuplicationRequest| |
|config.id*required|string|A UUID string identifying this business calendar. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|BusinessCalendarResponse|201||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { businessCalendarsClient } from "@dynatrace-sdk/client-automation";
const data =
await businessCalendarsClient.duplicateBusinessCalendar({
id: "...",
body: {},
});
`
Required scope: automation:calendars:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.id*required|string|A UUID string identifying this business calendar. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|BusinessCalendarResponse|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { businessCalendarsClient } from "@dynatrace-sdk/client-automation";
const data =
await businessCalendarsClient.getBusinessCalendar({
id: "...",
});
`
Required scope: automation:calendars:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.id*required|string|A UUID string identifying this business calendar. |
|config.version*required|string| Pattern: ^\[\\d]+$|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|BusinessCalendarResponse|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { businessCalendarsClient } from "@dynatrace-sdk/client-automation";
const data =
await businessCalendarsClient.getBusinessCalendarHistoryRecord(
{ id: "...", version: "..." },
);
`
Required scope: automation:calendars:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.all|boolean|When false, the latest historical record is not returned. |
|config.id*required|string|A UUID string identifying this business calendar. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|PaginatedChangeHistory|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { businessCalendarsClient } from "@dynatrace-sdk/client-automation";
const data =
await businessCalendarsClient.getBusinessCalendarHistoryRecords(
{ id: "..." },
);
`
Required scope: automation:calendars:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.limit|number|Number of results to return per page. |
|config.offset|number|The initial index from which to return the results. |
|config.ordering|string|Which field to use when ordering the results. |
|config.search|string|A search term. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|PaginatedBusinessCalendarResponseList|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { businessCalendarsClient } from "@dynatrace-sdk/client-automation";
const data =
await businessCalendarsClient.getBusinessCalendars();
`
Required scope: automation:calendars:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.body*required|BusinessCalendarUpdate| |
|config.id*required|string|A UUID string identifying this business calendar. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|BusinessCalendarResponse|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { businessCalendarsClient } from "@dynatrace-sdk/client-automation";
const data =
await businessCalendarsClient.patchBusinessCalendar({
id: "...",
body: {},
});
`
Required scope: automation:calendars:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.id*required|string|A UUID string identifying this business calendar. |
|config.version*required|string| Pattern: ^\[\\d]+$|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|BusinessCalendarResponse|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { businessCalendarsClient } from "@dynatrace-sdk/client-automation";
const data =
await businessCalendarsClient.restoreBusinessCalendarHistoryRecord(
{ id: "...", version: "..." },
);
`
Required scope: automation:calendars:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.body*required|BusinessCalendarUpdate| |
|config.id*required|string|A UUID string identifying this business calendar. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|BusinessCalendarResponse|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { businessCalendarsClient } from "@dynatrace-sdk/client-automation";
const data =
await businessCalendarsClient.updateBusinessCalendar({
id: "...",
body: {},
});
`
`js`
import { eventTriggersClient } from '@dynatrace-sdk/client-automation';
> ⚠️ Deprecated
Required scope: automation:workflows:read
#### Parameters
| Name | Type |
| --- | --- |
|config.body*required|EventTriggerPreviewRequest|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|EventTriggerPreviewResponse|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { eventTriggersClient } from "@dynatrace-sdk/client-automation";
const data = await eventTriggersClient.previewFilter({
body: {
triggerConfiguration: {
type: "event",
value: { query: "..." },
},
},
});
`
`js`
import { executionsClient } from '@dynatrace-sdk/client-automation';
Required scope: automation:workflows:run
Tries to cancel an Execution.
Can only be done, if the Execution is in an active state.
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this execution. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|204|No response body|
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.cancelExecution({
id: "...",
});
`
Required scope: automation:workflows:run
Cancels task execution.
Canceling action executions cause the task to be cancelled, which
causes the workflow to be canceled.
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.executionId*required|string| |
|config.id*required|string|Task name |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200|No response body|
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.cancelTaskExecution({
executionId: "...",
id: "...",
});
`
Required scope: automation:workflows:read
Get all event logs
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this execution. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|EventLogs|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getAllEventLogs({
id: "...",
});
`
Required scope: automation:workflows:read
Get execution
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this execution. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Execution|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getExecution({
id: "...",
});
`
Required scope: automation:workflows:read
Return list of actions assigned to tasks in a given Execution.
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this execution. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getExecutionActions({
id: "...",
});
`
Required scope: automation:workflows:read
Gets the execution log
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this execution. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getExecutionLog({
id: "...",
});
`
Required scope: automation:workflows:read
Get list of executions (executions of draft and simple workflows aren't included in the response).
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.limit|number|Number of results to return per page. |
|config.offset|number|The initial index from which to return the results. |
|config.ordering|string|Which field to use when ordering the results. |
|config.parentExecution|string| |
|config.parentWorkflow|string| |
|config.schedule|Array<string>|Multiple values may be separated by commas. |
|config.search|string|A search term. |
|config.startedAtGte|string| |
|config.startedAtLte|string| |
|config.state|Array<string>|Multiple values may be separated by commas. |
|config.subworkflowOfTask|string|Filter executions by parentExecution/task. |
|config.trigger|string| |
|config.triggerType|string| |
|config.user|Array<string>|Multiple values may be separated by commas. |
|config.workflow|Array<string>|Multiple values may be separated by commas. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|PaginatedExecutionList|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getExecutions();
`
Required scope: automation:workflows:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.executionId*required|string| |
|config.id*required|string|Task name |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|TaskExecution|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getTaskExecution({
executionId: "...",
id: "...",
});
`
Required scope: automation:workflows:read
Returns merged inputs from all ActionExecutions belonging to the TaskExecution.
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.executionId*required|string| |
|config.id*required|string|Task name |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getTaskExecutionInput({
executionId: "...",
id: "...",
});
`
Required scope: automation:workflows:read
Returns the log output of a specific task.
This can be large as its the STDOUT of the Action
as defined by the user.
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.executionId*required|string| |
|config.id*required|string|Task name |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getTaskExecutionLog({
executionId: "...",
id: "...",
});
`
Required scope: automation:workflows:read
Returns merged results from all ActionExecutions belonging to the TaskExecution.
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.executionId*required|string| |
|config.id*required|string|Task name |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getTaskExecutionResult({
executionId: "...",
id: "...",
});
`
Required scope: automation:workflows:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.executionId*required|string| |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|TaskExecutions|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getTaskExecutions({
executionId: "...",
});
`
Required scope: automation:workflows:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.executionId*required|string| |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|TaskTransitions|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.getTransitions({
executionId: "...",
});
`
Required scope: automation:workflows:run
Pauses an Execution.
Can only be done, if the Execution is in an active state.
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this execution. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|204|No response body|
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.pauseExecution({
id: "...",
});
`
Required scope: automation:workflows:run
Resumes an Execution.
Can only be done, if the Execution is in an inactive state.
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this execution. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|204|No response body|
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { executionsClient } from "@dynatrace-sdk/client-automation";
const data = await executionsClient.resumeExecution({
id: "...",
});
`
`js`
import { schedulesClient } from '@dynatrace-sdk/client-automation';
Required scope: automation:workflows:read
Returns the list of countries that can be used to look up the holiday calendar
#### Returns
| Return type | Status code | Description |
|---|---|---|
|CountryList|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulesClient.getCountries();
`
Required scope: automation:workflows:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.from|string|From date in ISO format |
|config.key*required|string|The country name |
|config.to|string|To date in ISO format |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|HolidayCalendarList|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulesClient.getHolidayCalendar({
key: "...",
});
`
Required scope: automation:workflows:read
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulesClient.getTimezones();
`
> ⚠️ Deprecated
Required scope: automation:workflows:read
#### Parameters
| Name | Type |
| --- | --- |
|config.body*required|SchedulePreviewRequest|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|SchedulePreviewResponse|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulesClient.previewSchedule({
body: {
schedule: {
trigger: { type: "cron", cron: "0 0 *" },
},
},
});
`
`js`
import { schedulingRulesClient } from '@dynatrace-sdk/client-automation';
Required scope: automation:rules:write
#### Parameters
| Name | Type |
| --- | --- |
|config.body*required|RuleCreate|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Rule|201||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulingRulesClient.createRule({
body: { title: "...", ruleType: "rrule" },
});
`
Required scope: automation:rules:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.id*required|string|A UUID string identifying this rule. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|204|No response body|
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulingRulesClient.deleteRule({
id: "...",
});
`
Required scope: automation:rules:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.body*required|DuplicationRequest| |
|config.id*required|string|A UUID string identifying this rule. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Rule|201||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulingRulesClient.duplicateRule({
id: "...",
body: {},
});
`
Required scope: automation:rules:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.id*required|string|A UUID string identifying this rule. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Rule|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulingRulesClient.getRule({
id: "...",
});
`
Required scope: automation:rules:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.id*required|string|A UUID string identifying this rule. |
|config.version*required|string| Pattern: ^\[\\d]+$|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Rule|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data =
await schedulingRulesClient.getRuleHistoryRecord({
id: "...",
version: "...",
});
`
Required scope: automation:rules:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.all|boolean|When false, the latest historical record is not returned. |
|config.id*required|string|A UUID string identifying this rule. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|PaginatedChangeHistory|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data =
await schedulingRulesClient.getRuleHistoryRecords({
id: "...",
});
`
Required scope: automation:rules:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.limit|number|Number of results to return per page. |
|config.offset|number|The initial index from which to return the results. |
|config.ordering|string|Which field to use when ordering the results. |
|config.search|string|A search term. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|PaginatedRuleList|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulingRulesClient.getRules();
`
Required scope: automation:rules:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.body*required|RuleUpdate| |
|config.id*required|string|A UUID string identifying this rule. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Rule|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulingRulesClient.patchRule({
id: "...",
body: {},
});
`
> ⚠️ Deprecated
Required scope: automation:workflows:read
#### Parameters
| Name | Type |
| --- | --- |
|config.body*required|RulePreviewCreate|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|RulePreviewResponse|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulingRulesClient.previewRule({
body: {
ruleType: "rrule",
rrule: { freq: "YEARLY", datestart: "..." },
},
});
`
Required scope: automation:rules:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.id*required|string|A UUID string identifying this rule. |
|config.version*required|string| Pattern: ^\[\\d]+$|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Rule|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data =
await schedulingRulesClient.restoreRuleHistoryRecord({
id: "...",
version: "...",
});
`
Required scope: automation:rules:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.body*required|RuleUpdate| |
|config.id*required|string|A UUID string identifying this rule. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Rule|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { schedulingRulesClient } from "@dynatrace-sdk/client-automation";
const data = await schedulingRulesClient.updateRule({
id: "...",
body: {},
});
`
`js`
import { settingsClient } from '@dynatrace-sdk/client-automation';
> ⚠️ Deprecated
Required scope: automation:workflows:read
Get service users who could be used as workflow actor (deprecated).
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { settingsClient } from "@dynatrace-sdk/client-automation";
const data = await settingsClient.getServiceUsers();
`
> ⚠️ Deprecated
Required scope: automation:workflows:read
Get system settings
#### Returns
| Return type | Status code | Description |
|---|---|---|
|GetSettingsResponse|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { settingsClient } from "@dynatrace-sdk/client-automation";
const data = await settingsClient.getSettings();
`
> ⚠️ Deprecated
Required scope: automation:workflows:read
Get current user effective permissions.
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { settingsClient } from "@dynatrace-sdk/client-automation";
const data = await settingsClient.getUserPermissions();
`
> ⚠️ Deprecated
Required scope: automation:workflows:read
Get user-specific settings
#### Returns
| Return type | Status code | Description |
|---|---|---|
|UserSettings|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { settingsClient } from "@dynatrace-sdk/client-automation";
const data = await settingsClient.getUserSettings();
`
> ⚠️ Deprecated
Required scope: automation:workflows:read
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|202|No response body|
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { settingsClient } from "@dynatrace-sdk/client-automation";
const data = await settingsClient.updateAuthorizations();
`
`js`
import { versionClient } from '@dynatrace-sdk/client-automation';
Required scope: automation:workflows:read
#### Returns
| Return type | Status code | Description |
|---|---|---|
|VersionResponse|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { versionClient } from "@dynatrace-sdk/client-automation";
const data = await versionClient.getVersion();
`
`js`
import { workflowsClient } from '@dynatrace-sdk/client-automation';
Required scope: automation:workflows:write
Creates a workflow and sets usages
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.body*required|WorkflowCreate| |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Workflow|201||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { workflowsClient } from "@dynatrace-sdk/client-automation";
const data = await workflowsClient.createWorkflow({
body: { title: "...", throttle: { isLimitHit: false } },
});
`
Required scope: automation:workflows:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this workflow. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|204|No response body|
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { workflowsClient } from "@dynatrace-sdk/client-automation";
const data = await workflowsClient.deleteWorkflow({
id: "...",
});
`
Required scope: automation:workflows:write
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.body*required|DuplicationRequest| |
|config.id*required|string|A UUID string identifying this workflow. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Workflow|201||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { workflowsClient } from "@dynatrace-sdk/client-automation";
const data = await workflowsClient.duplicateWorkflow({
id: "...",
body: {},
});
`
Required scope: automation:workflows:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this workflow. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|WorkflowExport|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { workflowsClient } from "@dynatrace-sdk/client-automation";
const data = await workflowsClient.exportWorkflow({
id: "...",
});
`
Required scope: automation:workflows:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this workflow. |
|config.version*required|string| Pattern: ^\[\\d]+$|
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Workflow|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { workflowsClient } from "@dynatrace-sdk/client-automation";
const data =
await workflowsClient.exportWorkflowHistoryRecord({
id: "...",
version: "...",
});
`
Required scope: automation:workflows:read
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this workflow. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|Workflow|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { workflowsClient } from "@dynatrace-sdk/client-automation";
const data = await workflowsClient.getWorkflow({
id: "...",
});
`
Required scope: automation:workflows:read
Return list of actions assigned to tasks in a given Workflow.
#### Parameters
| Name | Type | Description |
| --- | --- | --- |
|config.adminAccess|boolean|Allow access to all workflows/executions - additionally requires automation:workflows:admin |
|config.id*required|string|A UUID string identifying this workflow. |
#### Returns
| Return type | Status code | Description |
|---|---|---|
|void|200||
#### Throws
| Error Type | Error Message |
|---|---|
|ErrorEnvelopeError||
Code example
`ts
import { workflowsClient } from "@dynatrace-sdk/client-automation";
const data = await workflowsClient.getWorkflowActions({
id: "...",
});
``