Skip to content

Commit 41cb213

Browse files
authored
Merge pull request #22625 from newrelic/workflow-automation-minor-updates
Updating the structure of the APIs for Workflow Automation
2 parents 5aacd23 + 22c58b9 commit 41cb213

File tree

118 files changed

+2376
-12048
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

118 files changed

+2376
-12048
lines changed

src/content/docs/workflow-automation/create-a-workflow-automation/create-your-own.mdx

Lines changed: 47 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,17 @@ Understand these fundamentals before you build:
9191
`${{ .steps.getAlert.outputs.entityGuid }}`
9292
</td>
9393
</tr>
94+
<tr>
95+
<td>
96+
Assign
97+
</td>
98+
<td>
99+
Initialize and assign values to variables for use in subsequent steps
100+
</td>
101+
<td>
102+
Use `type: assign` to set variables like strings, integers, booleans, maps, and lists
103+
</td>
104+
</tr>
94105
<tr>
95106
<td>
96107
Switches
@@ -104,7 +115,7 @@ Understand these fundamentals before you build:
104115
</tr>
105116
<tr>
106117
<td>
107-
[Loops](/docs/workflow-automation/workflow-examples#loop-structure)
118+
[Loops](/docs/workflow-automation/workflow-examples/basic-patterns/loops)
108119
</td>
109120
<td>
110121
Process lists or poll for completion
@@ -195,7 +206,7 @@ Four essential patterns handle most automation scenarios. Each pattern is demons
195206
196207
**Use loops when:** Processing multiple items or repeating actions
197208
198-
For detailed information about loop structure, parameters, and advanced usage (including break/continue), see [Loop structure](/docs/workflow-automation/workflow-examples#loop-structure).
209+
For detailed information about loop structure, parameters, and advanced usage (including break/continue), see [Loop structure](/docs/workflow-automation/workflow-examples/basic-patterns/loops).
199210
200211
**Key syntax:**
201212
```yaml
@@ -277,8 +288,41 @@ For detailed information about loop structure, parameters, and advanced usage (i
277288

278289
**See it in action:** All sections demonstrate data passing—each step builds on previous results.
279290

291+
### Variable assignment with assign
292+
293+
The assign step type allows you to initialize and assign values to variables that can be used in subsequent workflow steps. This step supports multiple data types including strings, integers, booleans, maps (objects), and lists (arrays).
294+
295+
**Basic structure:**
296+
297+
```yaml
298+
- name: <step_name>
299+
type: assign
300+
inputs:
301+
<variable_name>: <value_or_expression>
302+
```
303+
304+
**Example:**
305+
306+
```yaml
307+
- name: variableInitialization
308+
type: assign
309+
inputs:
310+
stringVar: "${{ .workflowInputs.initialValue }}"
311+
intVar: "${{ .workflowInputs.anotherValue }}"
312+
concatenationVar: "${{ .workflowInputs.initialValue }} - concatenated"
313+
booleanVar: true
314+
mapVar:
315+
key1: "value1"
316+
key2: "${{ .workflowInputs.initialValue }}"
317+
listVar:
318+
- "listItem1"
319+
- "${{ .workflowInputs.initialValue }}"
320+
- "${{ .workflowInputs.anotherValue }}"
321+
statusCode: ${{ .steps.runAction.outputs.statusCode }}
322+
```
323+
280324
<Callout variant="tip">
281-
**Want complete pattern examples?** See [Workflow examples](/docs/workflow-automation/workflow-examples) for additional patterns including error handling, retries, and complex integrations.
325+
**Want complete pattern examples?** See [Workflow examples](/docs/workflow-automation/workflow-examples/workflow-examples) for additional patterns including error handling, retries, and complex integrations.
282326
</Callout>
283327

284328
## Example walkthrough: Auto-resize EC2 with approval [#example-walkthrough]

src/content/docs/workflow-automation/create-a-workflow-automation/managing-workflow.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,5 +134,5 @@ Remove workflows you no longer need.
134134

135135
## What's next
136136

137-
- **[Workflow examples](/docs/workflow-automation/workflow-examples)**: Learn from real-world automation scenarios.
137+
- **[Workflow examples](/docs/workflow-automation/workflow-examples/workflow-examples)**: Learn from real-world automation scenarios.
138138
- **[Troubleshooting](/docs/workflow-automation/troubleshooting)**: Fix credential errors, integration issues, and workflow failures.

src/content/docs/workflow-automation/create-a-workflow-automation/start-schedule.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ Select the right approach for your use case:
7878
**API**: [StartWorkflowRun](/docs/workflow-automation/workflow-automation-apis/start-workflow-run)
7979
</td>
8080
<td>
81-
**API**: [CreateSchedule](/docs/workflow-automation/workflow-automation-apis)
81+
**API**: [CreateSchedule](/docs/workflow-automation/workflow-automation-apis/create-schedule)
8282
</td>
8383
</tr>
8484
</tbody>
@@ -193,7 +193,7 @@ The mutation returns a `runId` (for example, `7bd25287-2af8-42e1-b783-80f4e760a4
193193

194194
## Schedule workflows [#scheduled]
195195

196-
Schedule workflows to run automatically at specific times using the [CreateSchedule API](/docs/workflow-automation/workflow-automation-apis). Scheduled workflows run recurring tasks without manual intervention.
196+
Schedule workflows to run automatically at specific times using the [CreateSchedule API](/docs/workflow-automation/workflow-automation-apis/create-schedule). Scheduled workflows run recurring tasks without manual intervention.
197197

198198
**When to schedule workflows:**
199199
- Regular health checks
@@ -356,7 +356,7 @@ After creating a schedule:
356356
- **Update schedule**: Use the UpdateSchedule API to change frequency or inputs
357357
- **Delete schedule**: Use the DeleteSchedule API to stop recurring runs
358358

359-
For complete API documentation, see [Workflow Automation APIs](/docs/workflow-automation/workflow-automation-apis).
359+
For complete API documentation, see [Workflow Automation APIs](/docs/workflow-automation/workflow-automation-apis/using-workflow-automation-api).
360360

361361
## What's next
362362

src/content/docs/workflow-automation/introduction-to-workflow.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ Workflow Automation connects New Relic with your existing tools to automate inci
6565
</tbody>
6666
</table>
6767

68-
Browse the [workflow examples](/docs/workflow-automation/workflow-examples) page for detailed scenarios and ready-to-use templates.
68+
Browse the [workflow examples](/docs/workflow-automation/workflow-examples/workflow-examples) page for detailed scenarios and ready-to-use templates.
6969

7070
## Get started
7171

src/content/docs/workflow-automation/limitations-and-faq/workflow-best-practices.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ Make workflows easy to understand.
246246

247247
Explain what, when, and who:
248248

249-
<Callout variant="info">
249+
<Callout variant="important">
250250
Automatically resizes EC2 instances when CPU exceeds 80% for 10 minutes. Notifies DevOps team via Slack. Used by on-call engineers to manage infrastructure costs.
251251
</Callout>
252252

src/content/docs/workflow-automation/setup-and-configuration/actions-catalog.mdx renamed to src/content/docs/workflow-automation/setup-and-configuration/actions-catalog/actions-catalog.mdx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ tags:
66
- workflow automation actions
77
- actions catalog
88
metaDescription: "Browse workflow automation actions by category, provider, or use case to automate your infrastructure and integrations"
9+
redirects:
10+
- /docs/workflow-automation/setup-and-configuration/actions-catalog/
911
freshnessValidatedDate: never
1012
---
1113

@@ -412,6 +414,6 @@ Helper actions for data transformation, script execution, and common utilities.
412414

413415
## What's next
414416

415-
- **[Workflow examples](/docs/workflow-automation/workflow-examples)**: See real-world workflow examples using these actions.
417+
- **[Workflow examples](/docs/workflow-automation/workflow-examples/workflow-examples)**: See real-world workflow examples using these actions.
416418
- **[Use a template](/docs/workflow-automation/create-a-workflow-automation/use-a-template)**: Deploy pre-configured workflows for common scenarios.
417419
- **[Create your own workflow](/docs/workflow-automation/create-a-workflow-automation/create-your-own)**: Build custom workflows from scratch.

src/content/docs/workflow-automation/setup-and-configuration/actions-catalog/aws/aws-execute-api.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -326,4 +326,4 @@ See [Set up AWS credentials](/docs/workflow-automation/setup-and-configuration/s
326326
</TabsPages>
327327
</Tabs>
328328
329-
For more workflow examples using AWS Execute API, see the [Workflow examples](/docs/workflow-automation/workflow-examples) page.
329+
For more workflow examples using AWS Execute API, see the [Workflow examples](/docs/workflow-automation/workflow-examples/workflow-examples) page.

src/content/docs/workflow-automation/setup-and-configuration/actions-catalog/http/http-delete.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ All HTTP requests performed by Workflow Automation automatically include the fol
4343
</thead>
4444
<tbody>
4545
<tr>
46-
<td>`x-abuse-info`</td>
46+
<td>`X-Abuse-Info`</td>
4747
<td>`Request sent by a New Relic WorkflowAutomation. {runId}`<br/>where `{runId}` is the workflow run ID</td>
4848
</tr>
4949
<tr>

src/content/docs/workflow-automation/setup-and-configuration/actions-catalog/http/http-get.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ All HTTP requests performed by Workflow Automation automatically include the fol
4343
</thead>
4444
<tbody>
4545
<tr>
46-
<td>`x-abuse-info`</td>
46+
<td>`X-Abuse-Info`</td>
4747
<td>`Request sent by a New Relic WorkflowAutomation. {runId}`<br/>where `{runId}` is the workflow run ID</td>
4848
</tr>
4949
<tr>
@@ -105,7 +105,7 @@ All HTTP requests performed by Workflow Automation automatically include the fol
105105
<td>**url**</td>
106106
<td>Required</td>
107107
<td>String</td>
108-
<td>The target URL for the request. The scheme must be included: `https://example.com`. See [using workflow inputs](/docs/workflow-automation/workflow-examples/#using-workflow-inputs) for dynamic values.</td>
108+
<td>The target URL for the request. The scheme must be included: `https://example.com`. See [using workflow inputs](/docs/workflow-automation/workflow-examples/basic-patterns/workflow-inputs) for dynamic values.</td>
109109
</tr>
110110
<tr>
111111
<td>**urlParams**</td>

src/content/docs/workflow-automation/setup-and-configuration/actions-catalog/http/http-post.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ All HTTP requests performed by Workflow Automation automatically include the fol
4343
</thead>
4444
<tbody>
4545
<tr>
46-
<td>`x-abuse-info`</td>
46+
<td>`X-Abuse-Info`</td>
4747
<td>`Request sent by a New Relic WorkflowAutomation. {runId}`<br/>where `{runId}` is the workflow run ID</td>
4848
</tr>
4949
<tr>

0 commit comments

Comments
 (0)