# Fleetpal MCP server: connect an AI agent to Fleetpal

Fleetpal is fleet maintenance software for heavy-duty commercial fleets. It has an MCP (Model Context Protocol) server, so an AI agent can work with a fleet's maintenance data in plain language.

- Server URL: `https://openapi.fleetpal.io/mcp`
- Transport: HTTP (streamable HTTP, remote server)
- Sign-in: OAuth 2.1 with discovery, using a Fleetpal account (password or Google)
- Without OAuth: a Fleetpal API key sent as `Authorization: Bearer fp_...`
- Human-readable page: https://fleetpal.io/mcp

## Connect in three steps

1. In your agent or MCP client, add a remote MCP server with the URL `https://openapi.fleetpal.io/mcp` and the HTTP transport.
2. When the client asks you to sign in, use your Fleetpal account (password or Google) and approve access. The client finds the sign-in page on its own through OAuth discovery. There is no client ID or secret to copy.
3. Ask a question, for example: "Which of my units are overdue for PM?"

## If you are an AI agent setting this up for a user

- Add the server yourself if you have a tool or command for adding MCP servers. Otherwise show the user the block for their client from the sections below.
- The user must complete the sign-in step in a browser. Do not ask the user for their Fleetpal password.
- If the client cannot do OAuth, ask the user to supply a Fleetpal API key through the client's own configuration. Keys come from Fleetpal support. Do not ask the user to paste a key into chat.
- The server URL is exactly `https://openapi.fleetpal.io/mcp`. Do not guess other hosts or paths.

## Claude

1. Open Claude's connector settings and add a custom connector.
2. Enter the connector name `Fleetpal` and the server URL `https://openapi.fleetpal.io/mcp`.
3. Connect, sign in with your Fleetpal account, and approve access.

## Claude Code

```bash
claude mcp add --transport http fleetpal https://openapi.fleetpal.io/mcp
```

Then start Claude Code, run `/mcp`, choose `fleetpal`, and sign in with your Fleetpal account.

With an API key instead of sign-in:

```bash
claude mcp add --transport http fleetpal https://openapi.fleetpal.io/mcp \
  --header "Authorization: Bearer fp_your_key_here"
```

## Cursor

Add to `~/.cursor/mcp.json`, or to `.cursor/mcp.json` in your project:

```json
{
  "mcpServers": {
    "fleetpal": {
      "url": "https://openapi.fleetpal.io/mcp"
    }
  }
}
```

Then open Cursor's MCP settings, find `fleetpal`, and sign in when asked.

With an API key instead of sign-in:

```json
{
  "mcpServers": {
    "fleetpal": {
      "url": "https://openapi.fleetpal.io/mcp",
      "headers": {
        "Authorization": "Bearer fp_your_key_here"
      }
    }
  }
}
```

## VS Code

Add to `.vscode/mcp.json` in your workspace:

```json
{
  "servers": {
    "fleetpal": {
      "type": "http",
      "url": "https://openapi.fleetpal.io/mcp"
    }
  }
}
```

Start the server from the file, then sign in with your Fleetpal account when asked.

With an API key instead of sign-in:

```json
{
  "servers": {
    "fleetpal": {
      "type": "http",
      "url": "https://openapi.fleetpal.io/mcp",
      "headers": {
        "Authorization": "Bearer fp_your_key_here"
      }
    }
  }
}
```

## Any other MCP client

1. Add a remote MCP server with the URL `https://openapi.fleetpal.io/mcp` and choose the HTTP transport.
2. Sign in with your Fleetpal account when the client asks, and approve access.
3. If the client has no OAuth support, send a Fleetpal API key in the header `Authorization: Bearer fp_your_key_here`.

## API keys

Fleetpal API keys start with `fp_`. Each key has a role and a read or write scope. To get a key, ask Fleetpal support and say which role and scope it should have. The key is shown once. More detail: https://fleetpal.io/fleet-maintenance-api

## What the agent can see and change

The agent acts as the signed-in user, or as the API key's role. It sees and changes only what that account can in Fleetpal, and only that company's data. For read-only access, connect with a read-only API key.

## What you can do with it

Ask in plain language. The agent picks the right Fleetpal tool for each request.

Looks things up:

- See what is due: "Which of my units are overdue for PM?"
- Pull a unit's history: "What is the service history for unit 1042 since January?"
- Check on open work: "Show the open work orders for unit 1042."
- Look up parts and stock: "Do we have brake pads for unit 1042 in stock?"
- Follow purchasing: "Which purchase orders are still open?"

Makes a change:

- Report a problem: "Open an issue on unit 1042: brake light out."
- Start a repair: "Create a work order for that issue."
- Update a meter reading: "Set the odometer on unit 1042 to 184,200 miles."

Requests that make a change work only when the Fleetpal account, or the API key used to connect, is allowed to make that change.

## Plans and access

Access to the API and the MCP server depends on the customer's Fleetpal plan. Fleetpal support or the customer's account manager can confirm what a plan includes.

## Disconnecting

In Fleetpal, open Settings > AI Assistants. Each connected assistant is listed there and can be signed out immediately. Removing the server from the AI tool does not revoke access on Fleetpal's side; it only stops the tool from using it. If an API key was used, ask Fleetpal support to revoke the key.

## Troubleshooting

- No Fleetpal tools appear: check the URL is exactly `https://openapi.fleetpal.io/mcp`, the transport is HTTP, and the sign-in step was completed. Then restart or reload the client.
- 401 Unauthorized with an API key: the header must read `Authorization: Bearer ` followed by the key, with no extra spaces or quotes.
- A record is missing or an update is refused: the account or key does not have access to it in Fleetpal.

## Related

- REST API spec for agents (OpenAPI JSON): https://openapi.fleetpal.io/v1/openapi.json
- REST API reference for people (needs JavaScript): https://openapi.fleetpal.io
- API and webhooks overview: https://fleetpal.io/fleet-maintenance-api
- Site index for AI agents: https://fleetpal.io/llms.txt
