Egor Urvanov

MCP for an AI agentWhat problem it solves and how to delegate setup to the agent

MCP plugs an agent into GitLab, Jira, Confluence and meeting recordings. What problem it solves, how to set it up in minutes and delegate that to the agent itself, how it saves time and tokens and why the agent invents less.

· 10 min · · Harness

MCP plugs an agent into working systems, so it reads facts from the source instead of a retelling. It is easy and quick: understand the problem it solves and delegate the setup to the agent itself. Below: the idea, connecting, what it gives and which rights to grant. The QA example with MCP is covered in the article QA with an agent via MCP, and access to a 1C database in MCP for 1C.

What MCP is

MCP is one common plug, like USB. Connect the agent to Jira or GitLab and it takes the data from there itself. More

A retelling or the system itself
BY HANDWITH AGENTJiraJira?YouRetellingAgentCtrl+CCtrl+VAgentYouAgent sees a retellingAgent works inside Jira● model, people, systems, data  ● agent and harness  ● risk, stop, boundary
Takeaway
In this exampleIn Jira the agent sees what a person sees: the task PAY-142 itself, comments and change history. No need to find the task and copy it into the conversation. It pulls related tasks on request. It can comment on your behalf, create a task or change a status (after your confirmation). On first use you should feel a “wow”: that means it is set up right. And it is very simple.
In generalThe agent looks wider than a person: it weighs neighbouring tasks, knowledge-base articles and past decisions, and finds non-obvious moves that one task alone does not show. Without MCP it knows only what was pasted in. The person stops being a courier between windows and stays the reviewer.
What to doStart with the task tracker: the easiest and quickest start. How to connect Jira: see below. Also count how many times a day you copy text into the conversation: that is your list of connection candidates.

Our context and others

Our context is everything the agent sees at once (the conversation with the agent, project files). Other contexts are everything else (GitLab, Jira, meeting recordings, a knowledge base). The bridge between them is MCP: the agent has an MCP client and the system has an MCP server. 1C connects the same way: it is one more other context, covered in the MCP for 1C article.

OUR CONTEXTOTHER CONTEXTSDialogueFilesHarnessthe agent and everything around itLocal machineMCP clientMCP serverGitLabCode and MRsJiraTasks and requirementstldvMeeting recordingsConfluenceKnowledge base1CCode and accounting dataAnd more● model, people, systems, data  ● agent and harness

What context is

Context is everything the model sees at the moment. What is not in the context, the agent does not know.

Context
LLMseescontext windowpromptchatfilessystem datawindow size is counted in tokensoutsidethe agent does not know this● model, people, systems, data  ● agent and harness  ● risk, stop, boundaryThe model knows only what is in the context window right now
Where the fact livesThe agent sees itWhat happens
Our context: the conversation, project filesat oncean answer from data
Other context: GitLab, Jira, 1C, meeting recordingsthrough MCPthe agent fetches what it needs
Nowhere: in heads, in a closed systemnoa guess instead of a fact

How the agent fetches other context: ReAct

The agent works in a ReAct loop: it reasons, acts, reads the result and reasons again. MCP is the “act” step: the call result lands in our context.

Reasoning onlyLLMThoughtThoughtMade-up answerActing onlyActionActionActionWandersReActLLMThoughtActionObservationRight answer↻ think again, using the observation● model, people, systems, data  ● agent and harness  ● risk, stop, boundaryReasoning alone makes things up, acting alone wanders, ReAct alternates them and gets the answer
Reasons“I need the steps of bug PAY-142”
ActsCalls the Jira MCP server
ReadsThe Jira reply lands in context
Only reasonsOther contexts are closed: the model makes up the answer.
Only actsCalls everything without a plan and burns tokens.
AlternatesFetches exactly what is missing and answers from data.

Grounding: every part of the answer has support

An answer is grounded when every part of it comes from the context. Such a matching with no empty spots is called an epimorphism.

dataanswerepimorphism: every part has supportnothing in the data?no supportthe model guesses — a hallucination● model, people, systems, data  ● agent and harness  ● risk, stop, boundaryEvery part of the answer comes from something in the data; a part without support is room for a hallucination
Part of the answerSupport
Reproduction stepsJira, ticket PAY-142
Where the code failsGitLab, file and line
Why it was decidedtldv, meeting recording
Which data is affected1C, a database query

Hallucination: a part with no support

A hallucination is a confident guess where there is no support. It looks as smooth as an answer from data. Details and Anthropic advice are in the hallucinations section below.

no sourceno dataagent?a confident inventionfunctions, links, facts that do not existwith a source and a checksourcechecka supported answer● model, people, systems, data  ● agent and harness  ● risk, stop, boundaryWithout support in a source the model confidently invents; a source and a check restore the support

Why these

GitLabCode and merge requests: the agent reads real code
Without it: The agent guesses the code from other contexts and is often wrong, which is how hallucinations appear; a person copies files and diffs into the conversation by hand
Official MCPMore
1CConfiguration code and accounting data: the agent reads real objects and numbers
Without it: The agent invents methods and attributes that are not in the configuration and answers with numbers that are not in the database
Open MCP serversDetails
JiraTasks and requirements: what was really asked
Without it: There is a lot to copy by hand and the change history gets lost
Official Atlassian MCPMore
ConfluenceKnowledge base: rules, specs, decisions
Without it: The visualisation and display of requirements every developer is used to disappear. It is important to limit the agent and not let it wander far: old requirements may be outdated. Make it check the factual picture in GitLab
Same Atlassian MCPMore
tldvMeeting recordings: decisions that exist nowhere in text. In our experience access appears 5–10 minutes after the meeting, so meeting notes and requirements can be written right away. The enterprise version, access control and MCP are weaker, but translations and transcripts are better quality
Without it: Decisions stay in heads, and meeting notes and requirements get written from memory hours later, with errors
Recording and open APIMore
GranolaAlso meeting recordings. It has an MCP, but in our experience lags tldv slightly: Spanish words slip into Russian text, which hurts the user experience and causes resistance to adoption. From the docs: active workspace only, free plan covers 30 days of notes
Without it: Same as without tldv: decisions from meetings get lost
MCPMore
Takeaway
In this exampleYou ask about a bug and the conversation has no steps. The agent searches project files, Jira is closed to it, so it writes the steps itself: confident, smooth, made up. You follow a path that does not exist.
In generalAn agent rarely answers “I don’t know”. If the answer is not in our context and the others are closed, it fills the gap from general patterns and presents it as fact. Every connected source removes room for invention.
What to doEvery time the agent hallucinates, find the context that holds the answer and give the agent access to it. Start with the last question it answered with an invention.

How to connect Jira

The agent and its harness can connect on their own. Guides: Atlassian and Claude Code.

By hand or delegate
BY HANDWITH AGENT123JiraYouAddSign inCheck“connect Jira”sign-inYouAgentBy hand: three actionsThe agent does it, you log in via browser● model, people, systems, data  ● agent and harness  ● risk, stop, boundary

Tell the agent

Connect the Jira MCP server following the Atlassian guide and test it on task PAY-142: read it and summarise the comments.

The agent runs the commands itself. All you do is log in via the browser (OAuth): the agent never gets your password. If the agent asks you to do it.

What will happen

  1. 1
    The agent connects Jira
    with one command, you type nothing
  2. 2
    A Jira page opens — the key step
    it offers to give the agent access to Jira; you sign in and approve, and the agent never sees the password
  3. 3
    The agent reads PAY-142
    opens the task with its comments and retells them

Read-only. You may not always be able to choose read-only access on that page. That is safe: the agent tends to read and hardly writes anything until you ask it to.

How it is done by handmcp addAtlassianJira1Add the server2Log in via browser3Test on a sample task● model, people, systems, data  ● agent and harness  ● risk, stop, boundary
claude mcp add --transport http atlassian https://mcp.atlassian.com/v2/mcp
/mcp               # log in via browser (OAuth)
claude mcp list     # status: connected / needs login / failed
Localyou · this projectProjectthe whole teamUseryou · all projects● model, people, systems, data  ● agent and harness

Where the setup lives and who sees the server: MCP scopes in Claude Code.

Takeaway
In this exampleThe agent runs the commands and checks the connection itself, and task PAY-142 is read in full with its comments. That is the “wow” moment.
In generalConnecting takes minutes. The "Project" scope puts the setup in the repo so the whole team gets the same servers. All three scopes are covered in MCP scopes in Claude Code.
What to doDelegate the setup to the agent and compare its answer with what you see in Jira yourself.

Savings

The saving comes from accuracy. A vague request gets a vague answer, a fix spawns a new request, and errors pile up from step to step; when copying and retelling by hand a person adds such slips unnoticed. The agent takes data straight from the source, so the chain is shorter and has fewer errors. The price is growing token use over a long run, and there are limiters for it.

Piling up errors: by hand or from the source
BY HANDWITH AGENT!!!!!!RequestAnswerFixAnswerRequestAgentAnswer1 pass instead of 33 passes, ever more errorsA vague request: errors pile upAn exact request: answer from the sourceACCUMULATED ERRORS (ILLUSTRATIVE)1step 13step 26step 31step 1step 2step 3saved● model, people, systems, data  ● agent and harness  ● risk, stop, boundary
Vague requests and answersRetelling and copying by hand lose detail, so the request comes out vague and so does the answer.
Errors pile upEvery fix spawns a new request with a new inaccuracy: errors add up from step to step.
Cost: tokensThere are fewer steps, but token use grows over a long run; there are limits for it.

Spending limits

A connected system’s reply lands in the conversation and takes up room there, and room is measured in tokens. So Claude Code watches reply size and sets two thresholds.

Up to 10,000the reply goes into the conversation as is10,000 – 25,000Claude Code warns thatthe reply is largeOver 25,000the reply is saved to a file,the conversation gets only its path10 00025 0000tokens in the reply

The 25,000 cap can be raised with the MAX_MCP_OUTPUT_TOKENS environment variable, while the warning threshold is fixed.

More.

Takeaway
In this exampleThree passes with growing errors turn into one pass on an exact request.
In generalThe saving is the absence of extra rounds: an exact request and an answer from the source do not pile up errors. Exact figures come only from measuring your own work.
About limitsThe longer the work, the more tokens it uses, so Claude Code limits long replies: it warns after 10,000 tokens and saves to a file after 25,000.
What to doMeasure two things on one task: how many minutes and fixes manual transfer takes, and how many tokens the agent spends.

Fewer hallucinations

Hallucination: the model produces text that looks right but is wrong or does not follow from the data. The model sounds equally confident in two situations. More

Little contextThe model fills in the gaps itself and does not say it is a guess.
Context presentThe model cites it briskly and confidently, so open the link and check it.
Where data is missing
“What are the steps of bug PAY-142?”questionlooks up??DataJira is closedAnswerAgentYouIn the dataanswer from the sourceMissingthe agent fills in● model, people, systems, data  ● agent and harness  ● risk, stop, boundary

The agent’s answer is matched against the data: every part of it should have support. In mathematics such a matching is called an epimorphism. Parts without support are filled in by the model as a guess, and they look just as confident.

What Anthropic recommends

"I don't know"Allow admitting missing data
QuoteRely on the source text verbatim
CitationEach claim gets its source
Takeaway
In this exampleJira is closed, so the agent made up two parts of the answer. When Jira is connected, those spots hold data from ticket PAY-142 with a link, and you open it in one click.
In generalThe agent fills holes in the data with a guess and does not say so. Anthropic’s three tips close them: allow “I don’t know”, rely on a quote, give a link to the source. This does not remove hallucinations entirely, a human check stays.
What to doRequire a source for every fact: system, number, field. How to do it in requirements and meeting notes is in a separate article.

Risks and rules

In most cases the protection is already built into how MCP works in Claude Code. What remains is to pick trusted servers and not grant extra rights. More

PermissionClaude Code asks permission before using a server’s tool.
Project serversServers from a project’s .mcp.json file must be approved before first use.
RightsFor servers with sign-in you can limit which rights they request.
Permission ladder
JiraReadWrite + confirmWrite without confirm● model, people, systems, data  ● agent and harness  ● risk, stop, boundary
Takeaway
In this exampleThe agent reads prod, writes only to a test sheet and shows every write to a person.
In generalRights grow up the ladder: read first, then confirmed write. Unconfirmed write waits until trust is earned.
What to doGive a new server read-only and raise rights after a week of checked work.

Where to start

JiraJira1One read-only server25 queries checked by hand3Write with confirmation● model, people, systems, data  ● agent and harness
Takeaway
In this exampleStart with Jira read-only and compare five agent answers with what you see yourself.
In generalOne source, one reviewer, one rights step at a time.
What to doConnect the first server today and note what the agent read correctly and what not.

Other cases

One approach works across tasks: the agent reads the sources and a person checks the result.

standSentryGrafanaQA: reproduce a bug →Reports: data from a database →Incidents: Sentry and Grafana →● model, people, systems, data  ● agent and harness  ● risk, stop, boundary
CaseSourcesWhat the agent doesWhat a human checks
QAJira, stand, browserreproduces a bug, narrows the path, writes a reportthe steps by hand on the stand
Reports and analyticsdatabase, sheets, documentscalculates with queries, assembles a summaryone number another way
IncidentsSentry, Grafanamatches errors, metrics and release timethe hypothesis against charts and events
Task PAY-142 is made up for the example.
© 2026 Egor Urvanov