# Sprint Velocity Report From Jira for Each Client

A software development agency gives each client an agent that reads the client's Jira after each sprint and reports velocity: committed, completed and why.

[Run this on Rush](https://cloud.getrush.ai/run/sprint-velocity-report-for-each-client/atlassian/). Opens the console with this prompt ready to send. Connect Atlassian there first.

## What the agent does

This is for a software development agency that builds products for several clients at once, each in the client's own Jira site with its own board, sprint length and estimation habits. After each sprint the delivery lead owes the client a velocity update: how many story points the team committed to, how many it finished, the average over recent sprints, and an honest reason when the numbers move. Jira's velocity chart shows the bars but not the reasons, and the reasons are buried in changelogs: an estimate raised mid-sprint, a ticket pulled in on day three, a story split in two. The agency gives each client an agent that reads those changes and drafts the update.

The agency connects its own Atlassian site once and saves the agent as a template with `POST /o/{org}/agents`, naming `atlassian`, a sign-in to `https://mcp.atlassian.com/v2/mcp`, and instructions that allow reads only. When a client engagement starts, the agency's client portal calls `POST /o/{org}/agents {"template": "<template id>", "name": "velocity-<client id>"}` and `POST /o/{org}/agents/{agent}/connections {"type": "mcp", "name": "atlassian"}`, and the client's engineering lead signs in through the `authorize_url`. Atlassian's docs say the server uses OAuth 2.1 and respects the person's existing permissions, so the agent sees the boards that person can see.

A run starts with `getAccessibleAtlassianResources` for the site's `cloudId`, then `listJiraBoards` to find the board by name and `getJiraBoardConfig` for its columns and the statuses mapped to the last one, which is what done means on that board. `listJiraBoardSprints` filtered to closed gives the last six sprints with their dates. The estimate is a custom field whose name varies by project type, so the agent looks it up with `getJiraIssueTypeMetaWithFields` instead of guessing. For each sprint it runs `searchJiraIssuesUsingJql` with `sprint = <id>`, and calls `listJiraIssueChangelogs` on each issue to read when it entered the sprint, its estimate at sprint start and at close, and when it reached a done status.

From that it counts committed points (issues in the sprint at its start, at their estimate then), completed points (issues in a done status when the sprint closed, at their estimate then), points added after start, points removed, and estimate changes during the sprint. It averages completed points over the closed sprints and lists the issues behind every gap between committed and completed. Atlassian groups tools by permission, and the instructions keep the run to the `read_jira` and `search_jira` tools through `discover` and `executeRead`; it creates, edits, transitions or comments on nothing.

## Start it with one API call

`POST https://api.phoenix.so/o/{org}/sessions`

```json
{
  "agent": "<agent id>",
  "input": "Sprint velocity for board \"MOBILE\" after sprint \"Mobile 2026-23\" closed. Read only: use only read and search tools, and create, edit, transition or comment on nothing. Get the cloudId with getAccessibleAtlassianResources. Find the board with listJiraBoards, read getJiraBoardConfig and treat statuses mapped to its last column as done. List the last 6 closed sprints with listJiraBoardSprints. Find the story points field with getJiraIssueTypeMetaWithFields for Story; if no estimate field exists, stop and say so. For each sprint run searchJiraIssuesUsingJql with sprint = <id>, and read listJiraIssueChangelogs for each issue. Committed = issues in the sprint at its start date, at their estimate then. Completed = issues in a done status at the sprint's complete date, at their estimate then. Also count points added after start, removed before close, and estimate changes during the sprint. Write velocity.md: a table of the 6 sprints (committed, completed, added, removed, re-estimated), the 6-sprint average and the latest sprint against it, then for the latest sprint every issue behind the gap with key, summary, what changed and when. End with a 5-sentence draft update for the client, marked DRAFT. Write sprints.csv with one row per issue per sprint."
}
```

1. **Get an API key.** In the console, open Settings, then API keys, and create a key for your org. Send it in the Authorization header as a Bearer token.
2. **Send the request.** POST the body in request.json to https://api.phoenix.so/o/{org}/sessions. The run starts in its own cloud sandbox.
3. **Read what came back.** Follow the run on its live stream or wait for the run.completed webhook, then read the result and its trajectory.

## What comes back

The run returns `velocity.md` with six sprints side by side and the issue-level reasons for the latest one, plus `sprints.csv` for the agency's own charts. The delivery lead edits the five-sentence draft at the end before it goes to the client, usually to add context the tickets do not hold, such as a public holiday or a developer out sick.

The numbers can differ slightly from the bars in Jira's own velocity chart, and the report says how it counted so the lead can explain why: the agent reads estimates from each issue's changelog at the sprint's start and close, so an issue moved between boards or an estimate edited after the sprint closed shows up as a line in the file instead of a silent change.

A sprint where most of the gap is points added after start reads very differently from one where the team finished less than it planned, and the draft says which it was. The agent makes no judgment about the team's performance; it shows what changed during the sprint.

## Run it on every sprint that closes, per client

The agency's portal already holds each client's board and sprint calendar. The morning after a sprint's end date, it sends `POST /o/{org}/sessions` with that client's agent id, the board and sprint name in `input`, and a `request_id` that is a UUID v5 of the client id and sprint name, so a retry starts no second report. A delivery lead can also press a button in the portal to run it again after a late close.

Clients on two-week and one-week sprints run on their own schedules, each run in its own computer. Before starting, the portal checks `GET /o/{org}/agents/{agent}/connections`; when the Atlassian connection reads `needs_reauth`, it asks the client's lead to sign in again rather than sending an empty report.

## Why run it on Rush?

Each client's Atlassian sign-in is held in Rush's connection under that client's agent, so the agency stores no Jira tokens and one client's run cannot read another client's board, which matters to clients who are competitors. The session's `accounts` names the connection each run used, and the agency can show a client every run that read their Jira with `GET /o/{org}/sessions?account=<connection id>`.

A sprint report reads hundreds of changelog pages, which is slow by hand and quick for an agent on its own computer. Each run's record shows every Jira call it made, so when a client questions a number, the lead opens the session and points to the changelog entry behind it, and `total_cost_usd` per agent tells the agency what each client's reports cost to produce.

## Frequently asked questions

### What is sprint velocity, and how does this report count it?

Velocity is the amount of estimated work a team completes per sprint, usually in story points, averaged over recent sprints to plan the next ones. This report counts completed points at the estimate each issue had when the sprint closed, and committed points at the estimate each had when it started, both read from the issue changelogs.

### Why not just screenshot Jira's velocity chart?

The chart shows committed and completed bars but not which issues made the gap. The agent lists each issue added, removed or re-estimated during the sprint, which is what a client asks about when the bars move.

### What if the client estimates in hours or does not estimate at all?

The agent uses whatever estimate field the board's issue types have and names it in the report. If there is none, it stops and says so instead of counting issues, because issue counts and points are not comparable.

### Can the agent move unfinished issues into the next sprint?

No. Atlassian's server has a write tool for sprints, but the template's instructions and every prompt keep the run to read and search tools. Planning the next sprint stays with the team.

## More Atlassian jobs

- [Triage a Stale Jira Backlog](https://getrush.ai/run/backlog-triage/atlassian/)
- [How Can an IT Support Company Write Each Client's Monthly Service Report From Jira Service Management? An Agent on the First Working Day](https://getrush.ai/run/draft-each-clients-monthly-service-report/atlassian/)
- [How Do I Find Outdated Procedures in Confluence? A Hotel Management Company's Monthly List of Standard Operating Procedures Due for Review](https://getrush.ai/run/find-outdated-procedures-in-confluence/atlassian/)

## More jobs like this: Run an agent per customer task

- [AI Email Summary of Each Morning's Gmail, by Deal](https://getrush.ai/run/summarize-each-mornings-email/gmail/)
- [How Does Bookkeeping Software Turn Each Seller's PayPal Month Into Lines for the Books?](https://getrush.ai/run/summarize-paypal-month-for-the-books/paypal/)
- [How Can a Helpdesk Summarize the Jam Recording in Each Support Ticket? One Agent per Support Team, Signed Into Its Own Jam](https://getrush.ai/run/summarize-the-bug-recording-in-each-ticket/jam/)

## Keep reading

- [Connect Atlassian to Rush once, then name it on any run](https://getrush.ai/integrations/atlassian/)
- [Start your first run from the developer API quickstart](https://getrush.ai/docs/quickstart/)
- [Rush pricing: Free, Pro and Max](https://getrush.ai/pricing/)
