---
title: New Relic Agent actions
source: https://docs.newrelic.com/docs/workflow-automation/setup-and-configure/actions-catalog/newrelic/newrelic-agent
---

This page provides a comprehensive reference for New Relic agent actions available in the workflow automation actions catalog. These actions enable you to run agents configured in Agentic Platform.

## Agent actions

### Run agent [#newrelic-agent-run]

Runs an Agent configured in Agentic Platform.

#### Inputs

| Input field   | Optionality | Type   | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| ------------- | ----------- | ------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **prompt**    | Required    | String | A prompt is simply your instruction to an AI Agent. It's the question you ask or the command you give to get a specific result.                                                                                                                                                                                                                                                                                                                                                                                                   |
| **agentId**   | Required    | String | A unique identifier for the agent, including its version. Format: must start with a letter or underscore and may only contain letters, numbers, underscores, or hyphens.                                                                                                                                                                                                                                                                                                                                                          |
| **threadId**  | Optional    | String | A unique identifier for the conversation thread in UUID format.                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| **context**   | Optional    | List   | Additional contextual information for the request. Constraints and requirements: - **Structure**: Each element within the list must be an object strictly containing a `description` and a corresponding `value`. - **Capacity**: A maximum of 10 contextual items may be provided per request. - **Security**: Inclusion of secret references within this field is strictly prohibited. Example: ```yaml context:   - description: accountId     value: "12345678"   - description: slack_channel_id     value: "CXXXXXXXXX" ``` |
| **selectors** | Optional    | List   | The selectors to get the only specified parameters as output. Example: ```yaml selectors:   - name: success     expression: .success   - name: error     expression: .errorMessage   - name: response     expression: .response.finalAnswer ```                                                                                                                                                                                                                                                                                   |

#### Outputs

| Output field     | Type    | Description                |
| ---------------- | ------- | -------------------------- |
| **response**     | Object  | Response of the agent      |
| **success**      | Boolean | Status of the request.     |
| **errorMessage** | String  | Failure reason as message. |

#### Example

```yaml
name: demo-run-agent
description: Run newrelic word problem agent
steps:
  - name: runAgent
    type: action
    action: newrelic.agent.run
    version: '1'
    inputs:
      prompt: Sum of prime number less than 100
      agentId: word_problem_agent
      context:
        - description: accountId
          value: "12345678"
        - description: slack_channel_id
          value: "CXXXXXXXXX"
      selectors:
        - name: success
          expression: .success
        - name: error
          expression: .errorMessage
        - name: response
          expression: .response
```
