ML.ai

Bring your own tools, local or remote

Connect local or remote MCP servers and their tools show up for the agent on the next turn, scoped to one project or every project.

ML.ai Settings
GeneralModelsAgentsSkillsMCP serversPermissionsUsage

Auto routing

Each step goes to the model that fits it

MCP servers

Connect local or remote tools that ML.ai can use while working.

GitHubRemote · Globalcreate_pull_request · search_code · list_issues +11Connected
LinearRemote · Projectcreate_issue · update_issue · list_projects +6Connected

Add server

Type
Scope
Commandnpx -y @some-org/mcp-server-example

Who MCP servers are for

Developers integrating external tools, databases, or custom APIs into their coding workflow through the Model Context Protocol.

  • Developers working with databases

    Scope a server to one project so the agent can reach that repo’s database.

  • Teams with internal APIs

    Add a remote server by URL and share the same tools across the team.

  • Anyone wiring in hosted services

    Sign in with OAuth from ML.ai when the remote server supports it.

How it works

Point ML.ai at an MCP server by command or URL, add any env vars or headers, and its tools are there for the agent on the next turn.

Run a local server from a command

Give the command that starts the server and the env vars it needs, such as a database URL. Secrets stay in the server config instead of the chat.

Tools show up on the agent’s next turn

Once a server connects, its tools are available to the agent from the next turn, so you can ask for them in the same conversation.

Connect a remote server by URL

Remote servers take a URL plus any headers and a timeout, and the ones that use OAuth let you sign in from ML.ai so there is no token to paste.

Choose whether a server belongs to one project or all

Keep a database server tied to the repo that uses it, and put tools you reach for everywhere, like an issue tracker, in global scope.

Adding a local or a remote server

Command (local)

Give the command that starts the server, plus env vars such as a database URL. It runs on your machine, which suits databases, local files and internal CLIs.

URL (remote)

Give the server URL, any headers and a timeout. If the server uses OAuth, sign in from ML.ai and its tools appear on the next turn.

How a server goes from config to first tool call

From config to the first tool call, a server goes through four steps.

1Add the server by command or URLLocal servers need the command that starts them and remote ones need a URL. Add env vars or headers where the server expects them.
2Pick project or global scopeProject scope keeps the server with one repo. Global scope makes it available in every project you open.
3Sign in if the server asksRemote servers that use OAuth ask you to sign in, so you do not need to paste a token into the config.
4Use the tools from the next turnOnce connected, the server’s tools are available to the agent on its next turn, and you can ask for them by name.

Common MCP setup problems and fixes

What tends to go wrong when you first connect a server.

Tools that are not there yet

You add a server mid-conversation and ask for its tools straight away, before the agent has picked them up.

How ML.ai handles it

Tools appear on the next turn after the server connects, so send one more message and they are ready to use.

Secrets pasted into prompts

Database URLs and API keys end up typed into the chat because there is nowhere else obvious to put them.

How ML.ai handles it

Local servers take env vars and remote servers take headers, so credentials go in the server config instead of the conversation.

Slow servers holding up a turn

A remote server that is slow to respond can leave the agent waiting on a tool call far longer than you expect.

How ML.ai handles it

Set a timeout on each server so a slow call gives up after a limit you choose.

ML.ai
New sessionAutomationsReview

Sessions

Fix registration validation2hWrite the commit for auth fixesnowRotate refresh tokens on use4mAdd rate limiting to /api/search1dUpgrade to React 192d

Staged changes3 files

src/auth/session.ts+18−4

src/auth/rotate.ts+31

tests/session.test.ts+22

Skills

Prepare a skill instruction in the ML.ai composer.

/↑

Skills

Package the steps for a recurring task into a skill that calls your MCP tools the same way each time.

ML.ai
New sessionAutomationsReview

Sessions

Clean the workspace and rebuildRotate refresh tokens on use1hAdd rate limiting to /api/search6mUpgrade to React 192dFlaky checkout test3d

The agent proposes

$git statusRead&&rm -rf ~Irreversible deletion

ReadPromptRefuse

Earlier in this session

Command safety

How shell commands are classified by effect before they run, alongside the tools your servers add.

FAQs

Can I scope a server to a single project?

Yes. When you add a server, choose project scope to keep it with one repo, or global scope to make it available in every project you open.

Should I add a local or a remote server?

Add a local server when the tool needs your machine, such as a dev database, local files or an internal CLI: you give the command that starts it. Add a remote server when the tool is hosted: you give its URL, any headers and a timeout.

Does a remote server need a token in headers?

Not if it supports OAuth: sign in from ML.ai and there is nothing to paste. If it needs a header, reference an environment variable rather than writing the token into a project-scoped config, which lands in the repo.

Connect the tools your team already uses

Add a local or remote MCP server, pick its scope, and the agent can use its tools from the next turn.