Table of contents

Add secure integrations to your products and AI agents with ease via Merge.
Get a demo

How to connect a FactSet MCP with Claude Code (4 steps)

Jon Gitlin
Senior Content Marketing Manager
at Merge

Developers building investment research agents, portfolio analysis tools, or financial modeling workflows need programmatic access to FactSet data.

That's easier said than done; FactSet's API requires developer portal registration, API key provisioning per data domain, and entitlement-based access controls that determine which endpoints a given credential can reach. And that's all before a single financial query can run.

To help your developers pull company financials, earnings estimates, and market data from the terminal with ease, we'll show you how to connect FactSet with Merge Agent Handler's FactSet MCP server.

How it works

Merge Agent Handler connects Claude Code to the FactSet API through a single CLI setup.

You install the Merge CLI, authenticate once with your Merge Agent Handler account, and register the connection with one command.

Merge handles FactSet's API key management and entitlement-scoped credential storage on your behalf, so you never provision keys per data domain or manage access controls across environments.

Here's the command that registers the connection:

merge setup claude-code

Prerequisites

Before getting started, you'll need the following:

  • A Merge Agent Handler account
  • Claude Code installed (run claude --version to confirm)
  • pipx installed (run pipx --version to confirm, or install via pip install pipx)
  • A FactSet account with API access enabled (requires a FactSet subscription and API credentials provisioned through the FactSet Developer Portal)

If you want to connect Merge Agent Handler's FactSet MCP with internal or customer-facing agentic products, you can follow the steps in our docs.

1. Install the Merge CLI

Run the following to install the Merge CLI: pipx install merge-api

How to add pipx install merge-api in Claude Code

Verify the installation: merge --version

Related: How to use the Stripe MCP in Claude Code

2. Log in to Merge

Authenticate the CLI with your Merge Agent Handler account: merge login

This links your session to Merge so the CLI can make authorized requests against FactSet on your behalf.

3. Add Agent Handler to Claude Code

Register Agent Handler with Claude Code using the Merge CLI:

merge setup claude-code

Or manually:

claude mcp add 
--transport http agent-handler https://ah-api.merge.dev/mcp

Open Claude Code and run: /mcp

agent-handler should appear under Local MCPs with a connected status.

Verifying the connection registered

4. Authenticate FactSet

Open a Claude Code session and try: "Pull the last four quarters of revenue, operating income, and net income for Apple and show the year-over-year growth rate for each metric." The first time you invoke a FactSet tool, a Magic Link will appear to complete connector authentication.

You should then see an output like the following:

Screenshot of using FactSet MCP in Claude Code

{{this-blog-only-cta}}

FactSet MCP FAQ

In case you have more questions on setting up and using the FactSet MCP in Claude Code, we've addressed several more commonly-asked questions below.

What can you do once the FactSet MCP is connected to Claude Code?

With FactSet connected, Claude Code can:

  • Pull company fundamentals: retrieve income statement, balance sheet, and cash flow data for public companies across any time period, enabling agents to build financial models or run comparables analyses without manual data exports
  • Access earnings estimates: query consensus estimates, analyst revision history, and estimate dispersion for a given company and period, giving agents the forward-looking context needed for earnings preview workflows or valuation screens
  • Retrieve price and returns data: pull historical price series, total return data, and volume history for individual securities or baskets, useful for performance attribution agents or quantitative screening tools
  • Query company reference data: access FactSet identifiers, SEDOL and CUSIP mappings, exchange listings, and corporate action history, enabling agents to resolve securities across identifier types without a separate lookup layer
  • Surface news and events: retrieve company news, earnings call transcripts, and corporate event data, giving agents the qualitative context needed alongside quantitative financials
  • Access ownership and institutional data: pull institutional ownership records and 13F filing data for a given security, useful for agents that need to surface shareholder composition before an investor relations workflow

Why use Merge Agent Handler vs. building directly on the FactSet API?

You can build directly on FactSet's REST API. FactSet's developer portal is thorough, the API surface covers the main data domains, and for a single developer working against one data set the initial setup is manageable: register an application, obtain credentials, and start making requests.

The friction shows up quickly in practice.

FactSet's API is organized by data domain. Fundamentals, estimates, prices, ownership, and news each have separate endpoint families with separate entitlement checks. A credential provisioned for fundamentals doesn't automatically grant access to estimates or price data, so a research agent spanning multiple domains requires separate provisioning for each, plus logic to handle entitlement errors when a query exceeds what the credential can see.

Merge Agent Handler handles credential storage and entitlement-aware access for every connected FactSet account.

You can also scope which FactSet tools a given agent can reach: a portfolio monitoring agent, for example, can access price and returns tools but not ownership or M&A data.

Lastly, Agent Handler logs every tool call with the timestamp, tool name, and inputs.

Why connect FactSet to Claude Code?

Quantitative analysts, portfolio managers, and the developers who build on top of FactSet's financial data currently have to export from its workstation, write scheduled API jobs, or build dedicated integrations each time a new workflow needs access to a different slice of that data.

With the FactSet MCP connected, Claude Code can query financials, pull estimates, and retrieve price history without leaving the terminal.

This matters most when financial data needs to feed a downstream step quickly: running a peer group comp before a deal meeting, pulling the estimate revision history for a coverage name ahead of earnings, or screening a universe for a specific financial profile before a portfolio review.

Jon Gitlin
Senior Content Marketing Manager
@Merge

Jon Gitlin is the Managing Editor of Merge's blog. He has several years of experience in the integration and automation space; before Merge, he worked at Workato, an integration platform as a service (iPaaS) solution, where he also managed the company's blog. In his free time he loves to watch soccer matches, go on long runs in parks, and explore local restaurants.

Read more

MCP gateway: how it works, benefits, and solutions

AI

How to connect a BambooHR MCP with Claude Code (4 steps)

How to connect a DocuSign MCP with Claude Code (4 steps)

AI

Subscribe to the Merge Blog

Get stories from Merge straight to your inbox

Subscribe

Connect Claude Code to thousands of tools with Merge Agent Handler

Use Merge Agent Handler’s 150+ connectors (including FactSet) to power reliable, secure, and powerful agents.

Get started for free
But Merge isn’t just a Unified 
API product. Merge is an integration platform to also manage customer integrations.  gradient text
But Merge isn’t just a Unified 
API product. Merge is an integration platform to also manage customer integrations.  gradient text
But Merge isn’t just a Unified 
API product. Merge is an integration platform to also manage customer integrations.  gradient text
But Merge isn’t just a Unified 
API product. Merge is an integration platform to also manage customer integrations.  gradient text