1. Conduid
  2. Developer Tools
  3. Foobara MCP Connector
MCP server · Developer Tools

Foobara MCP Connector

Provides an abstract interface that allows LLMs to connect to fact sources such as LSPs, code diagnostics, symbol definitions/references, links, and frontmatter

Unclaimed NOASSERTION last commit a year ago lspmcpmcp-servermodelcontextprotocolnpmtypescript
49Fair

Scored 18 days ago · breakdown

About Foobara MCP Connector

Foobara MCP Connector is an MCP server published by foobara in the Developer Tools category: provides an abstract interface that allows LLMs to connect to fact sources such as LSPs, code diagnostics, symbol definitions/references, links, and frontmatter. It has been installed 0 times through Conduid.

The repository has 2 stars and 0 forks, with the last commit a year ago. Six months or more without a commit doesn't mean the server is broken, but check the open issues (0) before depending on it in production.

Install

Install
npx mcp-connector
Claude Code
claude mcp add connector -- npx -y @opticlm/connector
npx
npx -y @opticlm/connector

This server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.

Ask AI

Ask AI about Foobara MCP Connector

Powered by Claude · Grounded in docs

I know everything about Foobara MCP Connector. Ask me about installation, configuration, usage, or troubleshooting.

Security checks

  • ·README presentNot checked yet.
  • ·License declaredNot checked yet.
  • ·Tests presentNot checked yet.
  • ·Dependencies pinnedNot checked yet.
  • ·No dynamic code executionNot checked yet.
  • !Scoped permissionsDoesn't declare a permission scope. Assume it can do anything its process can.

README

Foobara::McpConnector

Exposes Foobara commands according to the Model Context Protocol (MCP) specification

Installation

Typical stuff: add gem "foobara-mcp-connector to your Gemfile or .gemspec file. Or even just gem install foobara-mcp-connector if just playing with it directly in scripts.

Usage

Code demo video!

You can watch a code demo here: https://youtu.be/_w3ZHdiJEGU

Code examples

You can find examples in examples/

Super basic example

Let's create a simple Foobara command:

class BuildSuperDuperSecret < Foobara::Command
  inputs do
    seed :integer, :required
  end
  result :integer

  def execute
    seed * seed * seed
  end
end

This just cubes the integer we pass to it. You can run it with BuildSuperDuperSecret.run!(seed: 3) which would give 27. See the foobara gem for more info about Foobara commands.

Now, let's connect it to an McpConnector:

require "foobara/mcp_connector"

mcp_connector = Foobara::McpConnector.new
mcp_connector.connect(BuildSuperDuperSecret)

And we can start a stdio server like so:

mcp_connector.run_stdio_server

Putting it all together in a single script called simple-mcp-server-example we get:

#!/usr/bin/env ruby

require "foobara/mcp_connector"

class BuildSuperDuperSecret < Foobara::Command
  inputs do
    seed :integer, :required
  end
  result :integer

  def execute
    seed * seed * seed
  end
end

mcp_connector = Foobara::McpConnector.new
mcp_connector.connect(BuildSuperDuperSecret)
mcp_connector.run_stdio_server

We can now add it to programs that can consume MCP servers. For example, with claude code, we can tell claude code about it by running claude mcp add and following the instructions or we can create a .mcp.json file like this:

{
  "mcpServers": {
    "mcp-test": {
      "type": "stdio",
      "command": "simple-mcp-server-example",
      "args": [],
      "env": {}
    }
  }
}

You need to set "command" to the path of your script.

Now when we run claude, we can ask it a question that would result in it running our command:

$ claude
> Hi! Could you please build me a super duper secret using a seed of 5?
● mcp-test:BuildSuperDuperSecret (MCP)(seed: 5)…
  ⎿  125
● 125
> Thanks!
● You're welcome!

An example with entities

Let's say we have a model (see examples/capybaras.rb):

class Capybara < Foobara::Entity
  attributes do
    id :integer
    name :string, :required
    year_of_birth :integer, :required
  end

  primary_key :id
end

As well as some commands like FindAllCapybaras, CreateCapybara, and UpdateCapybara (see examples/capybara_commands.rb)

We can write an MCP connector to expose those commands so we can ask questions that require running those commands to answer:

require "foobara/mcp_connector"
require_relative "capybara_commands"

CreateCapybara.run!(name: "Fumiko", year_of_birth: 2020)
CreateCapybara.run!(name: "Barbara", year_of_birth: 2019)
CreateCapybara.run!(name: "Basil", year_of_birth: 2021)

mcp_connector = Foobara::McpConnector.new
mcp_connector.connect(FindAllCapybaras)

mcp_connector.run_stdio_server

We can now ask a tool like claude a relevant question:

$ claude
> Which Capybara is the oldest?
● mcp-test:FindAllCapybaras (MCP)()…
  ⎿  [
       {
         "name": "Fumiko",
         "year_of_birth": 2020,
         "id": 1

     … +7 lines (ctrl+r to expand)

         "name": "Basil",
         "year_of_birth": 2021,
         "id": 3
       }
     ]

● Barbara (born in 2019)
> Thanks!
● You're welcome!

A destructive example

Let's say we would like to mutate data. Let's pretend we've accidentally entered a year-of-birth in a 2-digit format where a 4-digit format was expected. Let's do that and also expose our UpdateCapybara command:

# We will simulate a year accidentally being entered with a 2-digit format where a 4-digit format was expected
UpdateCapybara.run!(id: barbara.id, year_of_birth: 19)

mcp_connector = Foobara::McpConnector.new

mcp_connector.connect(FindAllCapybaras)
mcp_connector.connect(UpdateCapybara)

mcp_connector.run_stdio_server

Now we can ask a tool like claude to find and fix our data:

$ claude
> Hi! There's a Capybara whose birth year was entered incorrectly. Can you find which one
  and fix it? Thanks!
● I'll help find and fix the capybara with the incorrect birth year. Let me search for the
  capybaras first.
● mcp-test:FindAllCapybaras (MCP)()…
  ⎿  [
       {
         "name": "Fumiko",
         "year_of_birth": 2020,
         "id": 1

     … +7 lines (ctrl+r to expand)

         "name": "Basil",
         "year_of_birth": 2021,
         "id": 3
       }
     ]
● It looks like Barbara (id 2) has an incorrect birth year of 19, which is too low. Let me
  fix that to 2019.
● mcp-test:UpdateCapybara (MCP)(id: 2, year_of_birth: 2019)…
  ⎿  {
       "name": "Barbara",
       "year_of_birth": 2019,
       "id": 2
     }
● Fixed! Barbara's birth year has been updated from 19 to 2019.
> Great! Thanks!
● You're welcome!

Moar examples

Please see the examples/ directory for executable scripts of these examples.

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/foobara/mcp-connector

Feel free to reach out if you'd like help with this gem or if you'd like to help with this gem!

License

This project is licensed under the MPL-2.0 license. Please see LICENSE.txt for more info.

README mirrored from the source repository 18 days ago. The original is authoritative.

Questions

About Foobara MCP Connector

How do I install Foobara MCP Connector?

Run npx mcp-connector, then add the server to your MCP client's configuration. Conduid has recorded 0 installs, so the command is known to work with current clients.

Is Foobara MCP Connector safe to use with an AI agent?

Its trust score is 49 out of 100 (fair). It passes 0 of 1 static security checks; the failures are listed above. It has no ConduID identity yet, so agent calls to it are not receipted.

Is Foobara MCP Connector still maintained?

The last commit was a year ago, with 0 open issues. That's long enough that you should check whether the maintainer is responding to issues before depending on it.