Hi there,
I’m having trouble getting a Rovo agent to invoke a CREATE
action. For example, I’m simply trying to get a Rovo agent to create a random Jira issue, but it doesn’t want to invoke the action.
Here is the manifest file:
modules:
rovo:agent:
- key: test-creator
name: Story Creator
description: A Rovo agent that will create a random story
prompt: >
You are an Agile expert, tasked with creatig and saving them into Jira.
Some instructions begin with "DEBUG: ", indicating its purpose is to help debug the state. Debugging is enabled so perform these instructions.
To do this, follow these steps:
1. Check if the current issue ID and the project ID are available in the context. If not, get them.
2. Come up with a random Title, Description and Acceptance Criteria for the story.
3. Confirm the details with the user.
4. Call the `create-issue` action to create the issue in Jira. The response will contain the ID of the newly created issue.
5. DEBUG: Provide the user with an explanation of what parameters and values you passed to the `create-issue` action.
6. Respond to the user by giving them a url to the newly created issue. You can find the id as a result of the invocation in step 4.
conversationStarters:
- Create a story
actions:
- create-issue
action:
- key: create-issue
name: Create an issue given the Title and Description
function: createIssue
actionVerb: CREATE
description: >
When a user asks to create an issue, this action creates the issue and returns the ID
inputs:
issueType:
title: Issue type
type: string
required: true
description: The type of the issue, e.g. 10001
title:
title: Issue Title
type: string
required: true
description: "The title of the Issue"
description:
title: Description
type: string
required: true
description: "The description and Acceptance Criteria of the Issue"
function:
- key: createIssue
handler: index.createIssue
permissions:
scopes:
- read:jira-work
- write:jira-work
- storage:app
app:
runtime:
name: nodejs20.x
id: ari:cloud:ecosystem::app/xxx-xxx
And here is the index.ts
file:
export async function createIssue(payload, requestContext): Promise<string> {
console.log("create issue", payload, requestContext);
const parentId = payload.context.jira.issueId;
const projectId = payload.context.jira.projectId;
return "does not matter";
}
When I invoke the agent, I get the following, and no data is logged to the console:
Am I doing something wrong here?